Running Squore as a Windows Service

During the installation of Squore Server on Windows, the installer provides the option to register a service to control Squore's startup and shutdown. When you install the Windows service, you should no longer use the start and stop scripts described in the section called “Starting Squore on Windows”

Manual installation

If you did not select to register the services automatically at installation time, you can still register the Squore service manually with the help of the instructions below.

Tip

Before modifying your installation to use services, make sure that Squore Server starts up properly by following the steps described in the section called “Starting Squore on Windows”.

Follow the steps below to install the Squore services:

Tip

The Windows service uses Apache Commons Daemon. Consult https://commons.apache.org/proper/commons-daemon/index.html for more information about the framework and the available installation options.

  1. Shutdown Squore Server

  2. Choose a name and a display name for the service. The instructions below use the defaults: squore and Squore.

  3. Install the services by running this command in a command window as administrator:

    <SQUORE_HOME>\bin\prunsrv.exe install squore --DisplayName="Squore" --Description="The Squore service" ^
    --Classpath=<SQUORE_HOME>\lib\squore-control.jar --Startup=auto --Jvm=auto ^
    ++JvmOptions="-Xrs#-Dsquore.home.dir=<SQUORE_HOME>" --StartMode=jvm --StartClass=$1 ^
    ++StartParams="-W#start" --StopMode=jvm --StopClass=$1 ++StopParams=stop

Windows Service Configuration

After installing Squore Server as a Windows service, you can use the service manager to change some of the settings.

Start the utility by typing the following in a command window as administrator:

<SQUORE_HOME>\bin\prunmgr.exe //ES/squore

The service manager opens in a new window and allows you to change the following settings:

  1. General Settings

    The General Tab

    From the General tab, you can adjust the Service display name, description and startup type (Automatic to start at boot, Manual to start interactively, Disabled to stop using the service). You can also see and change the current state of the service.

  2. Log On

    The Log On Tab

    From the Log On tab, you can control which Windows account runs the service. Note that any change takes affect after the service is restarted.

    The service is set to run under the local system account by default. Depending on your security requirements you may need to manually set the account to a real Windows user to run the services. For more information, consult the Microsoft Windows documentation at https://technet.microsoft.com/en-us/library/cc755249.aspx.

  3. Logging

    The Logging Tab

    On the Logging tab, you can define paths to log files where the startup and shutdown activities of the service will be saved. The default location for the log file is %SystemRoot%\System32\LogFiles\Apache and generally does not need to be changed, unless you are noticing issues starting and stopping the service.

  4. Java

    The Java Tab

    The Java tab is useful if you need to change the path to your JRE. You can use jvm.dll from the system's %PATH%, or you can point to a specific %JAVA_HOME%\bin\server\jvm.dll if needed.

    Note

    The settings on this tab have no effect over the Java settings for Squore Server. If you want to change the path to the Java installation or the amount of memory used by Squore, refer to the section called “Changing the path to the Java Installation” and the section called “Changing the Java Heap Size” instead.

  5. Startup and Shutdown

    There are no useful settings to be modified on these tabs.

Uninstalling the Service

Tip

These instructions only apply to users who installed the windows service manually. If you used the Windows installer to install the service, it will be automatically removed when you uninstall Squore Server.

Uninstalling the service can be done as a Windows administrator with this command:

sc delete squore