Environment
Novell Identity Manager User Application 3.5.1
Novell Identity Manager User Application 3.6.0
Novell Identity Manager User Application 3.6.1
Situation
How to run the User Application as a windows service.
Resolution
1.Download the wrapper tool from the linkhttp://wrapper.tanukisoftware.org/doc/english/jmx.html
2.Extract the file to a folder named wrapper
3.Set the JAVA_HOME and JBOSS_HOME System Environment variables on your Windows Machine
**Note, the java wants to point to the JAVA you are using to run JBoss with if you were starting it manually**
i.e.:
JAVA_HOME C:\IDM351\idm\jre\bin
JBOSS_HOME C:\IDM351\idm\jboss
4.Set your JAVA path in system path
5.Copy the file App.bat.in, InstallApp-NT.bat.in and UninstallApp-NT.bat.in \jBoss\bin (i.e.: C:\IDM351\idm\jboss\bin)
6.Rename those 3 copied files to remove the .in extension so that it can run as a batch file.
i.e.: :- rename App.bat.in App.bat
(They are already re-named in the attached zip)
7. Copy the wrapper.exe into the \jboss\bin directory (i.e.: C:\IDM351\idm\jboss\bin)
8.Copy the wrapper.dll and wrapper.jar file to JBOSS_HOME\lib (i.e.: C:\IDM351\idm\jboss\lib)
9.Create a folder named 'conf' under JBOSS_HOME (i.e.: C:\IDM351\idm\jboss\conf)
10.Create a configuration file called wrapper.conf inside newly created conf directory (below is an example from my environment)
11.For a our IDM UserApp the wrapper.conf file looks like this
**Note, the java wants to point to the JAVA you are using to run JBoss with if you were starting it manually**
wrapper.java.command=C:\IDM351\idm\jre\bin\java
wrapper.java.mainclass=org.tanukisoftware.wrapper.WrapperSimpleApp
wrapper.java.classpath.1=C:\IDM351\idm\jboss\lib\wrapper.jar
wrapper.java.classpath.2=C:\IDM351\idm\jre\lib\tools.jar
wrapper.java.classpath.3=C:\IDM351\idm\jboss\bin\run.jar
wrapper.java.classpath.4=C:\IDM351\idm\jboss\lib\endorsed\xalan.jar
wrapper.java.library.path.1=C:\IDM351\idm\jboss\lib
wrapper.java.additional.1=-server
wrapper.java.additional.2=-XX:MaxPermSize=128m
wrapper.java.initmemory=128
wrapper.java.maxmemory=512
wrapper.app.parameter.1=org.jboss.Main
wrapper.app.parameter.2=-c IDM -b 0.0.0.0
wrapper.logfile=C:\IDM351\idm\jboss\server\IDM\log\wrapper.log
wrapper.ntservice.name=JBoss
wrapper.ntservice.displayname=JBoss Server
You can change the values according to your system settings.
After setting the above, run the file Jboss/bin/InstallApp-NT.bat to load the jboss service.
Now you can get jboss service on service panel (services.msc)
To run the service you can give the following command
c:\net start jboss service
To stop it from a command line:
c:\net stop jboss
2.Extract the file to a folder named wrapper
3.Set the JAVA_HOME and JBOSS_HOME System Environment variables on your Windows Machine
**Note, the java wants to point to the JAVA you are using to run JBoss with if you were starting it manually**
i.e.:
JAVA_HOME C:\IDM351\idm\jre\bin
JBOSS_HOME C:\IDM351\idm\jboss
4.Set your JAVA path in system path
5.Copy the file App.bat.in, InstallApp-NT.bat.in and UninstallApp-NT.bat.in \jBoss\bin (i.e.: C:\IDM351\idm\jboss\bin)
6.Rename those 3 copied files to remove the .in extension so that it can run as a batch file.
i.e.: :- rename App.bat.in App.bat
(They are already re-named in the attached zip)
7. Copy the wrapper.exe into the \jboss\bin directory (i.e.: C:\IDM351\idm\jboss\bin)
8.Copy the wrapper.dll and wrapper.jar file to JBOSS_HOME\lib (i.e.: C:\IDM351\idm\jboss\lib)
9.Create a folder named 'conf' under JBOSS_HOME (i.e.: C:\IDM351\idm\jboss\conf)
10.Create a configuration file called wrapper.conf inside newly created conf directory (below is an example from my environment)
11.For a our IDM UserApp the wrapper.conf file looks like this
**Note, the java wants to point to the JAVA you are using to run JBoss with if you were starting it manually**
wrapper.java.command=C:\IDM351\idm\jre\bin\java
wrapper.java.mainclass=org.tanukisoftware.wrapper.WrapperSimpleApp
wrapper.java.classpath.1=C:\IDM351\idm\jboss\lib\wrapper.jar
wrapper.java.classpath.2=C:\IDM351\idm\jre\lib\tools.jar
wrapper.java.classpath.3=C:\IDM351\idm\jboss\bin\run.jar
wrapper.java.classpath.4=C:\IDM351\idm\jboss\lib\endorsed\xalan.jar
wrapper.java.library.path.1=C:\IDM351\idm\jboss\lib
wrapper.java.additional.1=-server
wrapper.java.additional.2=-XX:MaxPermSize=128m
wrapper.java.initmemory=128
wrapper.java.maxmemory=512
wrapper.app.parameter.1=org.jboss.Main
wrapper.app.parameter.2=-c IDM -b 0.0.0.0
wrapper.logfile=C:\IDM351\idm\jboss\server\IDM\log\wrapper.log
wrapper.ntservice.name=JBoss
wrapper.ntservice.displayname=JBoss Server
You can change the values according to your system settings.
After setting the above, run the file Jboss/bin/InstallApp-NT.bat to load the jboss service.
Now you can get jboss service on service panel (services.msc)
To run the service you can give the following command
c:\net start jboss service
To stop it from a command line:
c:\net stop jboss
To get the dependency on the MySQL service:
Please look at the following URL:
http://wrapper.tanukisoftware.org/doc/english/prop-ntservice-dependency-n.html
wrapper.ntservice.dependency.1=MySQL
To install MySQL as a service run:
C:\>"C:\Novell\idm\mysql\bin\mysqld-nt"
--install MySQL --defaults-file=C:\Novell\idm\mysql\my.ini
Now you can get MySQL service on service panel (services.msc)
Please pay attention to the comments at the bottom of the page.