Quiescing MQ

 

The orderly shutdown of MQ is called quiescing. You need to quiesce MQ to upgrade to a newer version.

To quiesce one or more queue managers:

  1. Sign on to a new interactive iSeries™ session, ensuring that you are not accessing any MQ objects.

  2. Ensure that you have:

    1. *ALLOBJ authority, or object management authority for the QMQM library.

    2. Sufficient authority to use the ENDSBS command.

    3. For V5.1 only, you should also have *USE authority for the following programs:

      • QMQM/AMQIQEM4

      • QMQM/AMQSTOP4

      • QMQM/AMQSPECA

  3. Warn all users that you are going to stop MQ.

  4. Quiesce all queue managers:-

    1. On V5.1, run program AMQSTOP4:

      CALL QMQM/AMQSTOP4 PARM(*ALL *CNTRLD 15)
      Where 15 is a timeout value in seconds.

      If this fails, we can force queue managers to stop by issuing:

      CALL QMQM/AMQSTOP4 PARM(*ALL *FORCE 15)

    2. On Versions 5.2 or 5.3, use the ENDMQM command:

      ENDMQM MQMNAME(*ALL) OPTION(*CNTRLD) ENDCCTJOB(*YES) TIMEOUT(15)
      Where 15 is a timeout value in seconds.

      If the ENDMQM command has not completed within a reasonable period (at least 10 minutes), use the WRKMQM command to identify the queue managers that are still ending, and force each one in turn to stop by issuing:

      ENDMQM MQMNAME(QMGRNAME) OPTION(*IMMED)
      Where QMGRNAME is the name of the queue manager.

      Complete the tidying up of shared memory by issuing the command:

      ENDMQM MQMNAME(*ALL) OPTION(*IMMED) ENDCCTJOB(*YES) TIMEOUT(15)

    3. On V6.0 or later, use the ENDMQM command:

      ENDMQM MQMNAME(*ALL) OPTION(*CNTRLD) ENDCCTJOB(*YES) RCDMQMIMG(*YES) TIMEOUT(15)
      Where 15 is a timeout value in seconds.

      If the ENDMQM command has not completed within a reasonable period (at least 10 minutes), use the WRKMQM command to identify the queue managers that are still ending, and force each one in turn to stop by issuing:

      ENDMQM MQMNAME(QMGRNAME) OPTION(*IMMED)
      Where QMGRNAME is the name of the queue manager.

      Complete the tidying up of shared memory by issuing the command:

      ENDMQM MQMNAME(*ALL) OPTION(*IMMED) ENDCCTJOB(*YES) RCDMQMIMG(*NO) TIMEOUT(15)

  5. If the command in the previous step does not complete, end the subsystem immediately by issuing:

    ENDSBS SBS(QMQM) OPTION(*IMMED)

  6. If this also fails, use the operating system command ENDJOB to end all jobs in the subsystem QMQM, as described below.

    Do not use ENDJOBABN unless you intend to IPL the machine before starting MQ. Ending MQ jobs using ENDJOBABN can lead to damaged semaphores, which in turn can prevent your queue manager from starting.

    1. If a QMGR(s) must be shut down manually, the recommended order of ending jobs (ENDJOB) is shown below (if the job exists) - please wait a couple of minutes for AMQA* or AMQZ* jobs to tidy-up.

      1. RUNMQLSR - MQ TCP listener (multi-threaded)

      2. AMQCLMAA - MQ TCP listener (single-threaded)

      3. AMQRMPPA - Channel process pooling job

      4. RUNMQCHI - MQ channel initiator

      5. AMQCRSTA - MQ receiving MCA jobs

      6. RUNMQCHL - MQ sending MCA jobs

      7. AMQCRS6B - LU62 receiver channel

      8. AMQPCSEA - MQ command server

      9. RUNMQTRM - Application trigger monitor

      10. RUNMQDLQ - Dead letter queue handler

      11. AMQFCXBA - MQ Broker Worker Job

      12. RUNMQBRK - MQ Broker Control Job

      13. AMQZMUC0 ('0' is a zero) - MQ Utility Manager

      14. AMQZMUR0 ('0' is a zero) - MQ Utility Manager

      15. AMQZMGR0 ('0' is a zero) - MQ Process Controller

      16. AMQRRMFA - MQ cluster repository manager

      17. AMQZDMAA - MQ deferred message manager

      18. AMQALMPX - MQ Log Manager

      19. AMQZFUMA - MQ Object Authority Manager

      20. AMQZLAS0 ('0' is a zero) - MQ LQM agents

      21. AMQZLAA0 ('0' is a zero) - MQ LQM agents

      22. AMQZXMA0 ('0' is a zero) - MQ Execution Controller

    2. Issue the following command:

      ENDMQM MQMNAME(QMGRNAME) OPTION(*IMMED)

    3. Issue the following command:

      ENDMQM MQMNAME(*ALL) OPTION(*CNTRLD) ENDCCTJOB(*YES) RCDMQMIMG(*NO) TIMEOUT(05)
      Where 05 is a timeout value in seconds.

    4. Manually clean up shared memory. Issue the following command:

      EDTF '/QIBM/UserData/mqm/qmgrs'
      then:

      (For V5.2 Do Not remove PerQueue from the shmem directories. For V5.2 there is no &qmpersist directory)

      1. Take option 5 for &SYSTEM and check that the following sub-dirs are empty: isem esem, msem, ssem, and shmem.

      2. Take option 5 for QMGRNAME and check that the following sub-dirs are empty :- isem esem, msem, ssem, and shmem.

      3. Take option 5 for &ipcc in the QMGRNAME directory and check that the following sub-dirs are empty :- isem esem, msem, ssem, and shmem.

      4. Take option 5 for &qmpersist in the QMGRNAME directory and check that the following sub-dirs are empty :- isem esem, msem, ssem, and shmem.

 

Parent topic:

Migrating from MQ V5.1 or later