Warning: This page has not been updated in over over a year and may be outdated or deprecated.
administration:starting_and_stopping_solr
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionNext revisionBoth sides next revision | ||
administration:starting_and_stopping_solr [2022/12/22 13:09] – [Linux (systemd) Method] demiankatz | administration:starting_and_stopping_solr [2023/03/10 11:45] – Remove VuFind 2.x script example (now obsolete). demiankatz | ||
---|---|---|---|
Line 168: | Line 168: | ||
:!: If you need to run VuFind with non-default settings, you may wish to add some lines to export environment variables in this script, or else source a script containing all of your environment settings prior to running " | :!: If you need to run VuFind with non-default settings, you may wish to add some lines to export environment variables in this script, or else source a script containing all of your environment settings prior to running " | ||
- | :!: Newer versions of Solr do not like to be run by the root user; you may need to either add " | + | :!: Newer versions of Solr do not like to be run by the root user; you may need to either add " |
< | < | ||
Line 223: | Line 223: | ||
To automate Solr with systemd: | To automate Solr with systemd: | ||
- | * create the user " | + | * [[administration: |
* add permission for the solr directory to this user: | * add permission for the solr directory to this user: | ||
Line 229: | Line 229: | ||
* create new file called / | * create new file called / | ||
- | |||
- | In VuFind 2.x, the contents of the file should be as follows: | ||
- | |||
- | < | ||
- | [Unit] | ||
- | Description=VuFind Starter | ||
- | After=network.target | ||
- | |||
- | [Service] | ||
- | Type=forking | ||
- | ExecStart=/ | ||
- | PIDFile=/ | ||
- | User=solr | ||
- | ExecStop=/ | ||
- | |||
- | # Java responds to a SIGTERM by returning with exit code 143 which leads to " | ||
- | SuccessExitStatus=143 | ||
- | |||
- | [Install] | ||
- | WantedBy=multi-user.target | ||
- | </ | ||
- | |||
- | In VuFind 7.0 and later, the contents of the file should be as follows. It will work with the official VuFind 3 deb package (tested on Ubuntu 16.04). For compatibility with VuFind 3.0 through 6.0, simply change " | ||
< | < | ||
Line 268: | Line 245: | ||
WantedBy=multi-user.target | WantedBy=multi-user.target | ||
</ | </ | ||
+ | |||
+ | The above example should work for VuFind 7.0 and later using the official VuFind deb package (this has been tested on Ubuntu). For compatibility with VuFind 3.0 through 6.0, simply change " | ||
Be sure to adjust paths in the code above to match your local system. | Be sure to adjust paths in the code above to match your local system. |
administration/starting_and_stopping_solr.txt · Last modified: 2023/10/24 13:47 by demiankatz