When Solr is displaying results on the site, first step is to log in the server and check its status
● solr.service - LSB: Controls Apache Solr as a Service
Loaded: loaded (/etc/init.d/solr; generated)
Active: failed (Result: exit-code) since Wed 2024-04-17 23:22:52 UTC; 6h ago
Docs: man:systemd-sysv-generator(8)
Apr 17 23:22:50 FRDC-Drupal-PROD systemd[1]: Starting LSB: Controls Apache Solr as a Service...
Apr 17 23:22:51 FRDC-Drupal-PROD su[750]: (to solr) root on none
Apr 17 23:22:51 FRDC-Drupal-PROD su[750]: pam_unix(su-l:session): session opened for user solr>
Apr 17 23:22:51 FRDC-Drupal-PROD su[750]: pam_unix(su-l:session): session closed for user solr
Apr 17 23:22:52 FRDC-Drupal-PROD systemd[1]: solr.service: Control process exited, code=exited>
Apr 17 23:22:52 FRDC-Drupal-PROD systemd[1]: solr.service: Failed with result 'exit-code'.
Apr 17 23:22:52 FRDC-Drupal-PROD systemd[1]: Failed to start LSB: Controls Apache Solr as a Se>
You might need to navigate to the directory where your Solr instance is installed, although this is not strictly necessary for restarting the service unless you have specific scripts in that directory. The default installation directory is usually /opt/solr or /var/solr, but this depends on how Solr was installed.
Stop Solr
You can stop Solr by running the following command
sudo service solr stop
Alternatively, if Solr was installed from a package, you might be able to use
sudo systemctl stop solr
Start Solr
After stopping, you can restart Solr by running:
sudo service solr start
Or, if you used systemctl to stop it:
sudo systemctl start solr
Check Status
To ensure Solr is running, you can check the status with:
sudo service solr status
Or:
sudo systemctl status solr
Restart Solr
sudo systemctl restart nginx
As the site has no results, there is no need to the Solr service. Instead go with start Solr.
Response post starting / restarting Solr
● solr.service - LSB: Controls Apache Solr as a Service
Loaded: loaded (/etc/init.d/solr; generated)
Active: active (exited) since Thu 2024-04-18 06:09:03 UTC; 5s ago
Docs: man:systemd-sysv-generator(8)
Process: 77653 ExecStart=/etc/init.d/solr start (code=exited, status=0/SUCCESS)
Apr 18 06:08:58 FRDC-Drupal-PROD systemd[1]: Starting LSB: Controls Apache Solr as a Service...
Apr 18 06:08:58 FRDC-Drupal-PROD su[77655]: (to solr) root on none
Apr 18 06:08:58 FRDC-Drupal-PROD su[77655]: pam_unix(su-l:session): session opened for user so>
Apr 18 06:09:03 FRDC-Drupal-PROD systemd[1]: Started LSB: Controls Apache Solr as a Service.