[jboss-user] [Installation, Configuration & DEPLOYMENT] - Re: Running JBoss as windows service with procrun

tw do-not-reply at jboss.com
Mon Jul 20 19:02:22 EDT 2009


Yes, copying java.exe would be the method of last resort, if nothing else helps.

So far I know that the JBoss startup via org.jboss.Main shows a different class loading behavior, depending on whether it is runs through java.exe or procrun.

Using my own main class and jconsole I have verified that the JVM arguments are identical in both cases and so are the system properties.

I get the _JAVA_LAUNCHER_DEBUG output only through java.exe, so I would assume it is produced by the launcher and not by jvm.dll?

Here are the procrun commands to register the service for either case:


  | set JBOSS_DIR=c:\JBoss5
  | set JAVA_HOME="C:\Program Files (x86)\Java\jdk1.6.0_12"
  | 
  | rem delete existing service
  | "%JBOSS_DIR%\bin\jboss5.exe" //DS//jboss5
  | 
  | rem register service
  | "%JBOSS_DIR%\bin\jboss5.exe" //IS//jboss5 --DisplayName "jboss5" --Description "jboss5 service test" --LogPath "%JBOSS_DIR%\server\default\log" --Install "%JBOSS_DIR%\bin\jboss5.exe" --Jvm %JAVA_HOME%\jre\bin\server\jvm.dll --StartPath "%JBOSS_DIR%" --StopPath "%JBOSS_DIR%" --StdOutput auto --StdError auto
  | rem jvm.dll mode
  | "%JBOSS_DIR%\bin\jboss5.exe" //US//jboss5 --Classpath "%JBOSS_DIR%\bin\run.jar" --StartClass org.jboss.Main --StopClass org.jboss.Shutdown --StartParams "-c#default#-b#0.0.0.0" --StopParams TBD  --StartMode jvm --StopMode jvm 
  | "%JBOSS_DIR%\bin\jboss5.exe" //US//jboss5 --JvmOptions "-Dprogram.name=run.bat#-Xms128m#-Xmx512m#-XX:MaxPermSize=256m#-Dorg.jboss.resolver.warning=true#-Dsun.rmi.dgc.client.gcInterval=3600000#-Dsun.rmi.dgc.server.gcInterval=3600000#-Djboss.platform.mbeanserver#-Djava.endorsed.dirs=%JBOSS_DIR%\lib\endorsed#-Djava.class.path=%JBOSS_DIR%\bin\run.jar#-Dsun.java.command=org.jboss.Main#-Dsun.java.launcher=SUN_STANDARD"
  | rem java.exe mode
  | rem "%JBOSS_DIR%\bin\jboss5.exe" //US//jboss5 --StartParams "-Dprogram.name=run.bat#-Xms128m#-Xmx512m#-XX:MaxPermSize=256m#-Dorg.jboss.resolver.warning=true#-Dsun.rmi.dgc.client.gcInterval=3600000#-Dsun.rmi.dgc.server.gcInterval=3600000#-Djboss.platform.mbeanserver#-Djava.endorsed.dirs=%JBOSS_DIR%\lib\endorsed#-Djava.class.path=%JBOSS_DIR%\bin\run.jar#-Dsun.java.command=org.jboss.Main#-Dsun.java.launcher=SUN_STANDARD#org.jboss.Main#-c#default#-b#0.0.0.0" --StopParams TBD  --StartImage=%JAVA_HOME%\bin\java.exe --StopImage=%JAVA_HOME%\bin\java.exe --StartMode exe --StopMode exe 
  | 


View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4244769#4244769

Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4244769



More information about the jboss-user mailing list