Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

WSO2 Carbon and any WSO2 product can be run as a Windows service. It is also possible to install and run multiple WSO2 products as Windows services simultaneously. See the following topics for instructions:

Table of Contents
maxLevel3
minLevel3

Prerequisites

  • Install JDK 1.6.24 or later or 1.7.* and set up the JAVA_HOME environment variableBe sure your system meets the Installation Prerequisites. Java Development Kit (JDK) is essential to run the product.
  • Download and install a service wrapper library to use for running your WSO2 product as a Windows service. WSO2 recommends Yet Another Java Service Wrapper (YAJSW), and several WSO2 products provide a default wrapper.conf file in their <PRODUCT_HOME>/bin/yajsw/ directory.

...

  1. Download and unzip WSO2 ESB and WSO2 DSS.
  2. Download and unzip yajsw.
  3. Create two directories 'esb_service' and 'dss_service'.
  4. Copy the <YAJSW_HOME> directory to 'esb_service' and 'dss_service' separately. Now you will have two separate yajsw directories for the two products.
  5. Now, update the wrapper.conf file for each of the products, which is stored in the esb_service/<ESB_YAJSW_HOME>/conf/ and dss_service/<DSS_YAJSW_HOME>/conf/ directories. You simply have to replace carbon_home with esb_home and dss_home respectively.

  6. Copy the <ESB_HOME> directory to 'esb_service' and the <DSS_HOME> directory to 'dss_service'.
  7. Set port offset for DSS to '1' in the <DSS_HOME>/repository/conf/carbon.xml file. This will ensure that the DSS service will run on https port 9444 (default 9443 + 1). WSO2 ESB will be running on the default port 9443.
  8. Set the ESB_HOME, DSS_HOME and JAVA_HOME environment variables, which points to the extracted folders of each service.
  9. Now, update the wrapper.conf file for each of the products, which is stored in the esb_service/<ESB_YAJSW_HOME>/conf/ and dss_service/<DSS_YAJSW_HOME>/conf/ directories. You simply have to replace carbon_home with esb_home and dss_home respectively.

  10. Navigate to the esb_service/<ESB_YAJSW_HOME>/bin directory and execute the scripts as shown below.
    1. Run installService.bat to install the Windows service.
    2. Run startService.bat to start the service.
  11. Do the same above for the 'dss_service' as well.
  12. Right click on My Computer -> Manage. Then click Services and Applications -> Services. You can see both ESB and DSS services running. 
    Image RemovedImage Added

    Info

    You can stop or restart the services from the UI as shown in the diagram above. 
    Alternatively, you can go to the /<YAJSW_HOME>/bin directory for each product and execute the stopService.bat and uninstallService.bat  scripts to stop and uninstall Windows services.

  13. You can now open the management consoles of the two products with the following urls:

    • For ESB: https://localhost:9443/carbon.
    • For DSS: https://localhost:9444/carbon.