How to run the CA XCOM GATEWAY and/or the XCOM MANAGEMENT CENTER as a Windows service.
search cancel

How to run the CA XCOM GATEWAY and/or the XCOM MANAGEMENT CENTER as a Windows service.


Article ID: 22060


Updated On:


XCOM Data Transport XCOM Data Transport - Windows XCOM Data Transport - Linux PC XCOM Data Transport - z/OS


This document explains how to setup a Windows service to run the XCOM GATEWAY and/or the XCOM MANAGEMENT CENTER.

It is certainly not the only way to have an application started when the system boots up, but sites might want to do that, for example, to allow handling it together with other system components.



Component: XCGWIN


Step 1: If not already done, download and install the JavaService package (see additional information for details)

Step 2: Create and run a script similar to the following to define the service to Windows

cd %JBOSS_HOME%\bin                                                          
rem make a copy of the executable so that it can be easily identified in task manager displays
copy C:\JavaService-2.0.10\JavaService.exe %JBOSS_HOME%\bin\JBossService.exe 
rem install the service. Everything goes to a single line and has been aligned for readability
 -install JBoss     <- install command. Names the service
 %JAVA_HOME%\jre\bin\server\jvm.dll               <- Java library
 ... Java options start here .....
 -Xms128m -Xmx1024m
 ....   end of Java options   ......
 -start org.jboss.Main                 <- class used at startup
 -stop org.jboss.Main                  <- class used at shutdown
 -method systemExit                    <- class' method used at startup
 -out %JBOSS_HOME%\stdout.log          <- stdout redirection
 -err %JBOSS_HOME%\stderr.log          <- stderr redirection
 -current %JBOSS_HOME%\bin             <- current directory
 -depends mysql                                <- service dependencies
 -manual                               <- service startup method
 -overwrite                            <-overwrite stdout and stderr

Step 3: Create also a script similar to the following to uninstall the service when needed

cd %JBOSS_HOME%\bin
JBossService.exe -uninstall JBoss

Step 4: Changing the service parameters

If some of the above parameters need to be changed after the service is installed, it may be done either by uninstalling/installing the service again or by editing the service parameters in the Windows registry, under key HKEY_LOCAL_MACHINE\ SYSTEM\ CurrentControlSet\ Services\ {SERVICE_NAME}\ Parameters.

The exact variable names can be found in the JavaService documentation.


Additional Information

IMPORTANT: This article contains information about modifying the registry.
Before you modify the registry, make sure to create back up of the registry and ensure that you understand how to restore the registry if a problem may occur.
For more information about how to back up, restore, and edit the registry, please review the relevant Microsoft Knowledge Base articles on


JavaService is a software package distributed under the GNU LesserGeneral Public License (LGPL). Its purpose is to define Windows services that will run Java applications like jBoss, and therefore can be used to define the XCOM Management Center and/or Gateway as Windows services.

The full documentation for JavaService can be found in the /docs folder after downloading the product. It executes from the command prompt and has commands to install and uninstall the Windows services.