Shutting down CQS
During normal shutdown in a shared-queues environment, IMS tells Common Queue Server (CQS) to shut down, but if it does not, you can use the z/OS® STOP command to shut down the CQS subsystem. To shut down CQS, IMS can issue the CQSSHUT request, the CQSDISC request with the CQSSHUT=YES parameter command.
The IMS subsystem does not have access to the shared queues as long as CQS is down, and messages that are locked by that IMS subsystem are unavailable to all other IMS subsystems in the sysplex.
Normally, when a client disconnects from CQS by using the CQSDISC request and specifying the CQSSHUT=YES parameter, CQS shuts down after no clients are connected to it. In some cases, however, the CQS address space remains active, even when no clients are connected to it. This can happen under any of the following conditions:
- No client is connected to CQS when CQS is started.
- A client that was connected to CQS terminates abnormally, without issuing a CQSDISC request to disconnect from CQS, or issues a CQSDISC request with the CQSSHUT=NO parameter specified.
Procedure
P cqsjobnamecqsjobname is the job name of the CQS address space that you want to stop. If no clients are connected to a CQS, that CQS shuts down. If clients are connected to the CQS, the STOP command is rejected, and message CQS0300I is issued.