DISPLAY PUBSUB (display publish/subscribe status information)

Use the MQSC command DISPLAY PUBSUB to display publish/subscribe status information for a queue manager.

Using MQSC commands

For information on how you use MQSC commands, see Performing local administration tasks using MQSC commands.

[z/OS]You can issue this command from sources 2CR. For an explanation of the source symbols, see Sources from which you can issue MQSC commands on z/OS®.

Synonym: None

DISPLAY PUBSUB

Read syntax diagramSkip visual syntax diagram DISPLAY PUBSUB TYPE(ALL)TYPE(LOCAL)TYPE(CHILD)TYPE(PARENT)CMDSCOPE(' ')1CMDSCOPE(qmgr-name)2CMDSCOPE(*)2ALLattrs
Attrs
Read syntax diagramSkip visual syntax diagramTYPEQMNAMESTATUSSUBCOUNTTPCOUNT
Notes:
  • 1 Valid only on z/OS.
  • 2 Valid only on z/OS when the queue manager is a member of a queue sharing group.

Parameter descriptions for DISPLAY PUBSUB

TYPE
The type of publish/subscribe connections.
ALL
Display the publish/subscribe status for this queue manager and for parent and child hierarchical connections.
CHILD
Display the publish/subscribe status for child connections.
LOCAL
Display the publish/subscribe status for this queue manager.
PARENT
Display the publish/subscribe status for the parent connection.
[z/OS]CMDSCOPE
This parameter applies to z/OS only and specifies how the command runs when the queue manager is a member of a queue sharing group.
' '
The command runs on the queue manager on which it was entered. This is the default value.
qmgr-name
The command runs on the queue manager you specify, providing the queue manager is active within the queue sharing group.

You can specify a queue manager name, other than the queue manager on which the command was entered, only if you are using a queue sharing group environment and if the command server is enabled.

*
The command runs on the local queue manager and is also passed to every active queue manager in the queue sharing group. The effect of this is the same as entering the command on every queue manager in the queue sharing group.

You cannot use CMDSCOPE as a filter keyword.

Returned parameters

A group of parameters is returned, containing the attributes TYPE, QMNAME, STATUS, SUBCOUNT, and TPCOUNT. This group is returned for the current queue manager if you set TYPE to LOCAL or ALL, for the parent queue manager if you set TYPE to PARENT or ALL, and for each child queue manager if you set TYPE to CHILD or ALL.

TYPE
CHILD
A child connection.
LOCAL
Information for this queue manager.
PARENT
The parent connection.
QMNAME
The name of the current queue manager or the remote queue manager connected as a parent or a child.
STATUS
The status of the publish/subscribe engine or the hierarchical connection. The publish/subscribe engine is initializing and is not yet operational. If the queue manager is a member of a cluster (has at least one CLUSRCVR defined), it remains in this state until the cluster cache is available.
[z/OS] On IBM® MQ for z/OS, this requires that the Channel Initiator is running.
When TYPE is CHILD, the following values can be returned:
ACTIVE
The connection with the child queue manager is active.
ERROR
This queue manager is unable to initialize a connection with the child queue manager because of a configuration error. A message is produced in the queue manager logs to indicate the specific error. If you receive error message AMQ5821 or on z/OS systems CSQT821E, possible causes include:
  • Transmit queue is full.
  • Transmit queue put is disabled.
If you receive error message AMQ5814 or on z/OS systems CSQT814E, take the following actions:
  • Check that the child queue manager is correctly specified.
  • Ensure that broker is able to resolve the queue manager name of the child broker.
To resolve the queue manager name, at least one of the following resources must be configured:
  • A transmission queue with the same name as the child queue manager name.
  • A queue manager alias definition with the same name as the child queue manager name.
  • A cluster with the child queue manager a member of the same cluster as this queue manager.
  • A cluster queue manager alias definition with the same name as the child queue manager name.
  • A default transmission queue.
After you have set up the configuration correctly, modify the child queue manager name to blank. Then set with the child queue manager name.
STARTING
Another queue manager is attempting to request that this queue manager become its parent.
If the child status remains in STARTING without progressing to ACTIVE, take the following actions:
  • Check that the sender channel to child queue manager is running
  • Check that the receiver channel from child queue manager is running
STOPPING
The queue manager is disconnecting.
If the child status remains in STOPPING, take the following actions:
  • Check that the sender channel to child queue manager is running
  • Check that the receiver channel from child queue manager is running
When TYPE is LOCAL, the following values can be returned:
ACTIVE
The publish/subscribe engine and the queued publish/subscribe interface are running. It is therefore possible to publish or subscribe using the application programming interface and the queues that are monitored by the queued publish/subscribe interface.
COMPAT
The publish/subscribe engine is running. It is therefore possible to publish or subscribe by using the application programming interface. The queued publish/subscribe interface is not running. Therefore, any message that is put to the queues that are monitored by the queued publish/subscribe interface are not acted upon by IBM MQ.
ERROR
The publish/subscribe engine has failed. Check your error logs to determine the reason for the failure.
INACTIVE
The publish/subscribe engine and the queued publish/subscribe interface are not running. It is therefore not possible to publish or subscribe using the application programming interface. Any publish/subscribe messages that are put to the queues that are monitored by the queued publish/subscribe interface are not acted upon by IBM MQ.

If inactive and you want to start the publish/subscribe engine use the command ALTER QMGR PSMODE(ENABLED).

STARTING
The publish/subscribe engine is initializing and is not yet operational. If the queue manager is a member of a cluster, that is, it has at least one CLUSRCVR defined, it remains in this state until the cluster cache is available.
[z/OS]On IBM MQ for z/OS, this requires that the Channel Initiator is running.
STOPPING
The publish/subscribe engine is stopping.
When TYPE is PARENT, the following values can be returned:
ACTIVE
The connection with the parent queue manager is active.
ERROR
This queue manager is unable to initialize a connection with the parent queue manager because of a configuration error. A message is produced in the queue manager logs to indicate the specific error. If you receive error message AMQ5821,[z/OS] or on z/OS systems CSQT821E, possible causes include:
  • Transmit queue is full.
  • Transmit queue put is disabled.
If you receive error message AMQ5814,[z/OS] or error message CSQT814E on z/OS systems, take the following actions:
  • Check that the parent queue manager is correctly specified.
  • Ensure that broker is able to resolve the queue manager name of the parent broker.
To resolve the queue manager name, at least one of the following resources must be configured:
  • A transmission queue with the same name as the parent queue manager name.
  • A queue manager alias definition with the same name as the parent queue manager name.
  • A cluster with the parent queue manager a member of the same cluster as this queue manager.
  • A cluster queue manager alias definition with the same name as the parent queue manager name.
  • A default transmission queue.
After you have set up the configuration correctly, modify the parent queue manager name to blank. Then set with the parent queue manager name.
REFUSED
The connection has been refused by the parent queue manager. This might be caused by the following:
  • The parent queue manager already has a child queue manager with the same name as this queue manager.
  • The parent queue manager has used the command RESET QMGR TYPE(PUBSUB) CHILD to remove this queue manager as one of its children.
STARTING
The queue manager is attempting to request that another queue manager become its parent.
If the parent status remains in STARTING without progressing to ACTIVE, take the following actions:
  • Check that the sender channel to parent queue manager is running
  • Check that the receiver channel from parent queue manager is running
STOPPING
The queue manager is disconnecting from its parent.
If the parent status remains in STOPPING, take the following actions:
  • Check that the sender channel to parent queue manager is running
  • Check that the receiver channel from parent queue manager is running
SUBCOUNT
When TYPE is LOCAL, the total number of subscriptions against the local tree is returned. When TYPE is CHILD or PARENT, queue manager relations are not inquired and the value NONE is returned.
TPCOUNT
When TYPE is LOCAL, the total number of topic nodes in the local tree is returned. When TYPE is CHILD or PARENT, queue manager relations are not inquired and the value NONE is returned.