Run Solr as a Windows Service with AlwaysUp

How to Run Apache Solr as a Windows Service with AlwaysUp

Automatically start Solr when your server boots and keep it running 24/7 in the background. Survive crashes, accidental shutdowns, and other interruptions


Last Updated on June 5, 2026

Apache Solr is a Java based enterprise search platform built on Apache Lucene.

To install Solr as a Windows Service with AlwaysUp:

  1. Download and install Solr, if necessary.

    Since we expanded the zip file and moved its contents to "C:\Solr", we'll use that folder in the steps below.

  2. Download and install AlwaysUp, if necessary.

  3. Start AlwaysUp.

  4. Select Application > Add to open the Add Application window:

    Add Application

  5. As mentioned in the starting Solr documentation, Solr can be started using the solr.cmd file in the bin folder. To set that up on the General tab:

    • In the Application field, enter the full path to your solr.cmd file. Since we installed Solr in "C:\Solr", this is "C:\Solr\bin\solr.cmd" on our server.

      Be sure to use your own installation folder instead!

    • In the Arguments field, enter start.

    • In the Start the application dropdown, select Automatically but shortly after the computer boots. This setting will ensure that AlwaysUp launches Solr after all critical services are fully initialized.

    • And finally, in the Name field, enter the name that you will call the application in AlwaysUp. We specified Solr but you can go with another name if you like.

    Apache Solr Windows Service: General Tab

  6. Click over to the Logon tab and enter the user name and password of the Windows account in which you installed and run Solr. Solr must run in this account so that it can find its settings and environment variables (JAVA_HOME, etc.):

    Apache Solr Windows Service: Logon Tab

  7. The Solr Control Script Reference recommends running the solr.cmd script to safely stop the server. Let's set that up on the Extras tab:

    • In the Use this special command to stop the application field, enter the full command line to stop all instances of Solr. For our installation, this is:

      C:\Solr\bin\solr.cmd stop --all
    • And in the Wait for up to controls below, enter 60 seconds to give Solr enough time to stop gracefully.

    Apache Solr Windows Service: Extras Tab

  8. We're done configuring Solr so click the Save button to record your settings. In a couple of seconds, an application called Solr will show up in the AlwaysUp window. It's not yet running though, and the State column will say "Stopped":

    Apache Solr Windows Service: Installed

  9. To start Solr from AlwaysUp, choose Application > Start "Solr". In a couple of seconds, the State column will change to "Running":

    Apache Solr Windows Service: Running

    You should be able to access Solr from your web browser now (port 8983 by default):

    Apache Solr Windows Service: Working in the browser

  10. That's it! Next time your computer boots, Solr will start up immediately, in the background in Session 0, without anyone needing to log on.

    Please restart your server now and confirm that Solr works as expected after Windows boots up.

    And please feel free to edit Solr in AlwaysUp to check out the many other settings that may be appropriate for your unique environment. For example, schedule a weekly restart to keep things "fresh", install a watchdog sanity check that detects if networking components fail, send email alerts if Solr crashes, etc.


Solr not working properly as a Windows Service?

  • Consult the AlwaysUp Troubleshooter — our online tool that can help you resolve the most common problems encountered when running an application as a Windows Service.

  • From AlwaysUp, select Application > Report Activity > Today to bring up an HTML report detailing the interaction between AlwaysUp and Solr. The AlwaysUp Event Log Messages page explains the more obscure messages.

  • Browse the AlwaysUp FAQ for answers to commonly asked questions and troubleshooting tips.

  • Contact us and we will be happy to help!

Our 14,000+ customers include...
AlwaysUp is fully compatible with Windows 11 AlwaysUp is fully compatible with Windows Server 2025
Over 97,000 installations, and counting!
 
AlwaysUp is number 1! Run as a Service with AlwaysUp

Rock-solid for the past 20+ years!