Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

problem in creating window service of multiple instances of jboss6

 
bablu singh
Greenhorn
Posts: 24
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all,

I have created 3 instances of jboos6 on same. If i start using
run.bat (default)
run.bat -c ports-01 (ports-01)
run.bat -c ports-02 (ports-02)
on three different command prompt screens, its working fine.

On the other hand, if i want to make a window service using service.bat utility - i am able to run only one instance of jboss6.
For that i have copied the service.bat file and named it service2.bat and changed (r to r2, run to run2, shutdown to shutdown2)
call run.bat -c ports-01 < .r2.lock >> run2.log 2>&1
then i have installed service and service2.bat files, but only one is visible in services.msc screen that is installed first.

The problem is, even installing service2.bat i am not able to start using window service, where is the problem?
Please advice...
 
Peter Johnson
author
Bartender
Posts: 5856
7
Android Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You also need to change the SVCNAME (required) and the SVCDISP, SVCDESC (optional):



 
bablu singh
Greenhorn
Posts: 24
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks for the reply.
My two instances are running successfully, when i installed third service3.bat i got an error:

The JBoss Application Server 6.0.2 service on local computer started and then stopped. Some services stop automatically if they have no work to do, for example, the Performance Logs and Alerts service.

What can be the reason??? Thanks Again.
 
Peter Johnson
author
Bartender
Posts: 5856
7
Android Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You will need to check the logs to see if there was an error. Also check the redirected stdout/stderr (the runx.log).
 
bablu singh
Greenhorn
Posts: 24
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yes, i got it!!!
Actually i was writing wrong service.bat file in service3.bat.
Now three instances with window service is running properly.

Thanks for help.
 
Peter Johnson
author
Bartender
Posts: 5856
7
Android Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yes, this is what can happen if you manually change each serviceN.bat file and have the same value in multiple places. You might want to check out the modified service.bat that I provide with the source code for JBoss in Action. If you grab the source zip, it will be at ch15/src/service/windows/service.bat. Note that everything is set up front using property values, and that the ch15/build.xml sets the properties for each service, creating unique bat files for each one.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic