|
Service Mode |
Top Previous Next |
|
AggreGate Server may be started in service mode (see Startup and Shutdown section for details). A service runs independently of logged-on users and can be run even if no user is logged on. A service cannot rely on the presence of a console, nor can it open windows. Service mode behaviour depends on the operating system. AggreGate Server service is registered by the installer. It is configured for auto-launch during operating system startup. Microsoft Windows When the service is installed, it can be controlled through Start > Control Panel > Administration > Services. Installing and Uninstalling the Service You can also install the service from the command line by passing /install to the service executable (ag_server_service.exe). To prevent the automatic startup of your service when the computer is booted, pass the argument /install-demand instead. As a second parameter after the /install parameter, you can optionally pass a service name. In that way you can install a service with a different service name than the default name. Service is uninstalled by passing /uninstall to the service executable.
Starting and Stopping the Service from Command Line To start or stop the service, the /start and /stop options are available. In addition, a /status argument shows if the service is already running. The exit code of the status command is 0 when the service is running, 3 when it is not running and 1 when the state cannot be determined (for example, when service is not installed on Windows). Linux/Unix For Unix service executables, the start, stop, restart and status arguments are available for the control script (ag_server_service). This script is located in AggreGate Server installation directory, but a symlink to it is also created in services initialization directory (/etc/init.d or /etc/rc.d/init.d). The stop command waits for the service to shut down. The exit code of the status command is 0 when the service is running and 3 when it is not running. status command shows whether AggreGate Server daemon is running or not. Starting/Stopping the Service To start AggreGate Server, run the following command: service ag_server_service start To stop the server: service ag_server_service stop |