MainframeKit

2009

MQRC_CONNECTION_BROKEN (X'07D9')MQ REASON CODE

The link between the application and the queue manager was lost, so every handle the program held is now useless.

MOST LIKELY

The queue manager was stopped or ended abnormally.

FIRST CHECK

Check whether the queue manager is running and look at its error log or job log for the time of the failure.

TRY IT ▸

MainframeKit assistant

What it means

The program was connected, but the connection has gone. Often the queue manager stopped, or a client network link dropped. Any MQGET that was waiting is cancelled, and all connection and object handles are now invalid.

For client applications there is a catch: the call that got 2009 may in fact have completed on the queue manager, even though the completion code says it failed. Design restart logic with that in mind.

Typical causes

  • The queue manager was stopped or ended abnormally.
  • A client connection was cut by the network, a firewall that drops idle sessions, or a failover.
  • The server-connection channel instance was stopped by an administrator.
  • On z/OS IMS, the MQ subsystem connection is not started.

How to fix it

  1. Check whether the queue manager is running and look at its error log or job log for the time of the failure.
  2. In the program, treat 2009 as fatal for the current handles: back out uncommitted work, then reconnect with MQCONN or MQCONNX and reopen queues.
  3. For clients, check the network path and the channel status (DISPLAY CHSTATUS) and consider automatic client reconnection.
  4. On z/OS IMS, use DIS SUBSYS to check the MQ subsystem and STA SUBSYS to start it. CICS reconnects by itself.

Example

Illustrative only; names and values are invented.

MQGET failed  CompCode=2  Reason=2009  QMgr=QM01
Reconnect attempt 1 of 10 in 5 seconds