Uploaded image for project: 'ActiveMQ Classic'
  1. ActiveMQ Classic
  2. AMQ-3795

ActiveMQ standalone script not fully LSB compliant

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 5.4.3, 5.5.1
    • 5.12.0
    • None

    Description

      Just like in AMQ-3050, I tried to integrate ActiveMQ into a pacemaker setup.

      As supposed to work, pacemaker should recognize a frozen or dead process an restart the service. For ActiveMQ 5.4.3 and 5.5.1 this does not work in the following two scenarios:

      (1) PID file present, JRE process crashed

      Pacemaker recognizes this correctly (status gives return code 1) and calls "stop" to give the script the chance to deal with the situation (remove stale PID file e.g.). Since this is done successfully it should give a return code of 0, actually it is 1. A return code of 1 tells pacemaker something went wrong when stopping the service, so it changes the state of the resource to "unmanaged (FAILED)" leaving the service in down state.

      (2) PID file present, JRE process present, but frozen for some reason

      First, pacemaker doesn't recognize this ("status" gives return code 0 = running, should be non-zero), so maybe "status" should connect to the JRE and try talk to ActiveMQ in some way instead of just looking for a process?

      Furthermore, if called with "stop" in this case (simulated by sending SIGSTOP to the process), the script tries to connect to the JRE to stop it, fails to do so and finally kills the process forcefully. Since it (in some way) successfully stopped the service, it should return 0, but actually it's 1 as well.

      Return values needed for LSB compliance are given here: http://refspecs.linuxbase.org/LSB_3.1.0/LSB-Core-generic/LSB-Core-generic/iniscrptact.html

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              andreas.krause Andreas Krause
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: