Run Apache Derby Network Server as a Windows Service

How to Run Apache Derby Network Server as a Windows Service with AlwaysUp

Start your Java Database Server when your PC boots and keep it running 24x7. Survive crashes, hangs, accidental shutdowns and more!

Apache Derby is a small-footprint, open source relational database implemented entirely in Java.

To configure the Derby Network Server with AlwaysUp 8.0 and later:

  1. Download, install and configure Derby, if necessary. Please make a note of where you installed it as this will be used in later steps. We put Derby in C:\Derby for this tutorial.

  2. Download and install AlwaysUp, if necessary.

  3. Start AlwaysUp.

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

    Add Application

  5. On the General tab:

    • In the Application field, enter the full path to the batch file that starts Derby Network Server, startNetworkServer.bat. Since we have placed Derby in C:\Derby, this is

      C:\Derby\bin\startNetworkServer.bat

    • In the Name field, enter the name that you will call the application in AlwaysUp. We have specified Derby Network Server but you can specify another name if you like.

    Derby Windows Service: General Tab

  6. Click over to the Logon tab and enter the user name and password of the account in which you installed Derby. Derby should run in this account so that it can find its settings, java, etc.

    Derby Windows Service: Logon Tab

  7. Click over to the Startup tab and check the Ensure that the Windows Networking components have started box. This informs AlwaysUp that Derby needs the network to do its work.

    Derby Windows Service: Startup Tab

  8. It is best to use stop Derby by running the stopNetworkServer.bat script. To set that up, move to the Extras tab, check the Use this special command to stop the application box and fill in the path to the batch file in Derby's bin folder.

    Derby Windows Service: Extras Tab

  9. Click the Save >> button. In a couple of seconds, an application called Derby Network Server will show up in the AlwaysUp window. It is not yet running though.

    Derby Windows Service: Created

  10. To start Derby from AlwaysUp, choose Application > Start "Derby Network Server".

    Derby Windows Service: Running

    On Windows 8, 7, Vista, Server 2012 or 2008, Derby will be running in Session 0. Select Tools > Switch to Session 0 to transport yourself to the austere Session 0 desktop where the Derby Network Server console will be visible:

    Derby Windows Service: Running in Session 0

  11. That's it! Next time your computer boots, Apache Derby Network Server will start up immediately, without anyone needing to log on. Please restart your PC now and test that Derby works as expected after Windows comes back to life.

    And please feel free to edit Derby in AlwaysUp to check out the many other settings that may be appropriate for your environment. For example, send email alerts if it stops, hide the console, boost Derby's priority, etc.



Derby not working properly as a Windows Service?

  • From AlwaysUp, select Application > Report Activity > Today... to bring up a HTML report detailing the interaction between AlwaysUp and Derby. The AlwaysUp Event Log Messages page explains the more obscure messages.
  • Consult the AlwaysUp FAQ for answers to commonly asked questions and troubleshooting tips.
  • Contact us and we will be happy to help!

Download & Try it Free!

Download AlwaysUp and Run as a Service Today! Version 15.5 New!

8.0 MB Installer
Our 12,000+ customers include...
Compatible with Windows 11 Compatible with Windows Server 2022 Compatible with Windows 10
Over 94,000 installations, and counting!
 
AlwaysUp is number 1! Run as a Service with AlwaysUp

Rock-solid for the past 19+ years!