Forum LAMS for Tech-Heads - General Forum: Starting JBOSS as a Windows Service


 
You may request notification for Starting JBOSS as a Windows Service.
Search: 

1: Starting JBOSS as a Windows Service
04/04/07 03:45 AM
[ Reply | Forward ]
When I log into my Windows 2003 Server and start JBOSS using run.bat all works well. But I need to run JBOSS as a Windows Service otherwise when I log off (or the machine is rebooted) there is no JBOSS and no LAMS.

So I found

http://wiki.jboss.org/wiki/Wiki.jsp?page=RunJBossAsAServiceOnWindows

and followed the directions. I managed to get a service but when I started it, Windows responded with "the JBoss service started then stopped, Some services stop automatically if they have no work to do". No log files were produced (and the JBOSS logs weren't updated by the attempt to start the service).

Any help appreciated.

Best,

-ken

Posted by Ken Kahn

2: Re: Starting JBOSS as a Windows Service
In response to 1 04/04/07 05:59 PM
[ Reply | Forward ]
I haven't used the first option on that page (using JavaService), but we do use the second option (Java Service Wrapper) in the Windows installer. The Java Service Wrapper places it's own wrapper log under %JBOSS_HOME%/logs/wrapper.log by default, so that might be helpful when setting it up the first time. The instructions at http://wrapper.tanukisoftware.org/doc/english/integrate-simple-win.html pretty much cover it, but we also have a sample config file here - http://www.lamsinternational.com/documentation/LAMS%201.0.2%20Manual%20Installation.html. (it's a LAMS 1 page, but for the purposes of the wrapper the setup is the same).

If you run into problems with the Java Service Wrapper, post the wrapper.conf/wrapper.log, and we can go from there.

Posted by Jun-Dir Liew

3: Re: Re: Starting JBOSS as a Windows Service
In response to 2 04/05/07 04:55 AM
[ Reply | Forward ]
Thanks.

When I followed the directions JBOSS is started and LAMS runs fine but I don't see "LAMS (JBoss App Server)" as a Service. And when I log out it brings down JBOSS.

Attached are the conf and log files.

Thanks again for your help.

Best,

-ken

Posted by Ken Kahn

Attachments:
4: Re: Re: Re: Starting JBOSS as a Windows Service
In response to 3 04/09/07 06:55 PM
[ Reply | Forward ]
How are you starting the wrapper/lams? When it starts up in the log, it says 'Starting as Console', when it should say 'Starting as Service'. If it's not installed yet as a service, you can do that by double-clicking a premade batch file called (I think) Jboss-NT-Install.bat - or something similarly named. Or, on the command line, run

wrapper.exe -i /path/to/wrapper.conf

Posted by Jun-Dir Liew

5: Re: Re: Re: Re: Starting JBOSS as a Windows Service
In response to 4 04/10/07 02:03 AM
[ Reply | Forward ]
Hi. Thanks.

Running the NT-Install.bat fixed the problem. The documentation in http://wrapper.tanukisoftware.org/doc/english/integrate-simple-win.html
stated

JBoss can now be run by simply executing the bin\JBoss.bat script.

and failed to state the obvious that after testing it to run the install batch file. Sorry to have troubled you.

Thanks again.

Best,

-ken

Posted by Ken Kahn

Reply to first post on this page
Back to LAMS for Tech-Heads - General Forum