3 Replies Latest reply on Mar 7, 2013 12:06 PM by pathduck

    Using Init-script to start JBoss AS7 from RHQ

    pathduck

      Hi,

      in relation to my testing of using RHQ for JBoss operations, I want to try calling the init-script directly, since it gives us the most control of how the server starts and simplifies things a lot. So I have changed the Connection Settings for the appserver in RHQ:

       

      Start Script Path: /etc/init.d/jboss-server

      Start Script Env. Variables: PATH=/bin:/usr/bin

      Start Script Arguments: start

       

      This should be enough to call the init script and start the service I think.

       

      However, in RHQ this throws an exception and RHQ thinks the operation failed - even though the server is actually *started* - so the script works and returns a code of 0 but RHQ thinks it fail which is possibly a bug?

       

      Any ideas what might cause this?

       

      Below is the exception thrown in RHQ:

       

      java.lang.Exception: Start failed with error code 0:
      JBoss: Server jboss-server is STOPPED
      JBoss: Starting jboss-server

      at org.rhq.core.pc.operation.OperationInvocation.run(OperationInvocation.java:278)
      at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
      at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
      at java.lang.Thread.run(Thread.java:662)

       

      EDIT: Found this:

      https://bugzilla.redhat.com/show_bug.cgi?id=894493

      So, this is a known bug for JON - and chance this fix can also be made in RHQ possibly for the 4.6 release?