DISPLAY QSTATUS

Use the MQSC command DISPLAY QSTATUS to display the status of one or more queues.

Synonym: DIS QS

DISPLAY QSTATUS

Read syntax diagramSkip visual syntax diagramDISPLAY QSTATUS( generic-qname)WHERE(FilterCondition)ALLCMDSCOPE(' ')CMDSCOPE(qmgr-name)1CMDSCOPE(*)12MONITORTYPE(QUEUE)TYPE(HANDLE)OPENTYPE(ALL)OPENTYPE(INPUT)OPENTYPE(OUTPUT)queue statushandle status
Queue status
Read syntax diagramSkip visual syntax diagram,CURDEPTHIPPROCSLGETDATE3LGETTIME3LPUTDATE3LPUTTIME3MEDIALOG4MONQ3MSGAGE3OPPROCSQSGDISP2QTIME3UNCOM
Handle status
Read syntax diagramSkip visual syntax diagram,APPLDESCAPPLTAGAPPLTYPEASID2ASTATEBROWSECHANNEL5CONNAME5HSTATEINPUTINQUIREOUTPUTPID6PSBNAME7PSTID7QMURIDQSGDISP2SETTASKNO8TID6TRANSID8URIDURTYPEUSERID
Notes:
  • 1 Valid only on WebSphere® MQ for z/OS® when the queue manager is a member of a queue-sharing group.
  • 2 Valid on z/OS only.
  • 3 Also displayed by selection of the MONITOR parameter.
  • 4 Valid only on AIX®, HP-UX, Linux, IBM® i, Solaris, and Windows.
  • 5 Channel initiator only
  • 6 Not valid on z/OS.
  • 7 IMS only
  • 8 CICS® only

Usage notes for DISPLAY QSTATUS

The state of asynchronous consumers, ASTATE, reflects that of the server-connection proxy on behalf of the client application; it does not reflect the client application state.

Parameter descriptions for DISPLAY QSTATUS

You must specify the name of the queue for which you want to display status information. This name can either be a specific queue name or a generic queue name. By using a generic queue name you can display either:
  • Status information for all queues, or
  • Status information for one or more queues that match the specified name and other selection criteria
You must also specify whether you want status information about:
  • Queues
  • Handles that are accessing the queues
Note: You cannot use the DISPLAY QSTATUS command to display the status of an alias queue or remote queue. If you specify the name of one of these types of queue, no data is returned. You can, however, specify the name of the local queue or transmission queue to which the alias queue or remote queue resolves.
(generic-qname)
The name of the queue for which status information is to be displayed. A trailing asterisk (*) matches all queues with the specified stem followed by zero or more characters. An asterisk (*) on its own matches all queues.
WHERE
Specify a filter condition to display status information for queues that satisfy the selection criterion of the filter condition. The filter condition is in three parts: filter-keyword, operator, and filter-value:
filter-keyword
Almost any parameter that can be used to display attributes for this DISPLAY command. However, you cannot use the CMDSCOPE, MONITOR, OPENTYPE, QSGDISP, QTIME, TYPE, or URID parameters as filter keywords.
operator
The operator is used to determine whether a queue satisfies the filter value on the given filter keyword. The operators are:
LT
Less than
GT
Greater than
EQ
Equal to
NE
Not equal to
LE
Less than or equal to
GE
Greater than or equal to
LK
Matches a generic string that you provide as a filter-value
NL
Does not match a generic string that you provide as a filter-value
CT
Contains a specified item. If the filter-keyword is a list, you can use this filter to display objects whose attributes contain the specified item.
EX
Does not contain a specified item. If the filter-keyword is a list, you can use this filter to display objects whose attributes do not contain the specified item.
filter-value
The value that the attribute value must be tested against using the operator. Depending on the filter-keyword, this value can be:
  • An explicit value, that is a valid value for the attribute being tested.

    You can use operators LT, GT, EQ, NE, LE, or GE only. However, if the attribute value is one from a possible set of values on a parameter (for example, the value NO on the UNCOM parameter), you can only use EQ or NE.

  • A generic value. This value is a character string (such as the character string in the APPLTAG parameter) with an asterisk at the end, for example ABC*. If the operator is LK, all items where the attribute value begins with the string (ABC in the example) are listed. If the operator is NL, all items where the attribute value does not begin with the string are listed. Only a single trailing wildcard character (asterisk) is permitted.

    You cannot use a generic filter-value for parameters with numeric values or with one of a set of values.

  • An item in a list of values. The operator must be CT or EX. If it is a character value, it can be explicit or generic. For example, if the value DEF is specified with the operator CT, all items where one of the attribute values is DEF are listed. If ABC* is specified, all items where one of the attribute values begins with ABC are listed.
ALL
Display all the status information for each specified queue.

This value is the default if you do not specify a generic name, and do not request any specific parameters.

On z/OS, this value is also the default if you specify a filter condition using the WHERE parameter, but on other platforms only the requested attributes are displayed.

CMDSCOPE
This parameter specifies how the command is executed when the queue manager is a member of a queue-sharing group. It is valid on z/OS only.
' '
The command is executed on the queue manager on which it was entered. This value is the default.
qmgr-name
The command is executed 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 is executed on the local queue manager and is also passed to every active queue manager in the queue-sharing group. The effect of this value is the same as entering the command on every queue manager in the queue-sharing group.

You cannot use CMDSCOPE as a filter keyword.

MONITOR
Specify this value to return the set of online monitoring parameters. These are LGETDATE, LGETTIME, LPUTDATE, LPUTTIME, MONQ, MSGAGE, and QTIME. If you specify this parameter, any of the monitoring parameters that you request specifically have no effect; all monitoring parameters are still displayed.
OPENTYPE
Restricts the queues selected to queues which have handles with the specified type of access:
ALL
Selects queues that are open with any type of access. This value is the default if the OPENTYPE parameter is not specified.
INPUT
Selects queues that are open for input only. This option does not select queues that are open for browse.
OUTPUT
Selects queues that are open only for output.

The OPENTYPE parameter is valid only if TYPE(HANDLE) is also specified.

You cannot use OPENTYPE as a filter keyword.

TYPE
Specifies the type of status information required:
QUEUE
Status information relating to queues is displayed. This value is the default if the TYPE parameter is not specified.
HANDLE
Status information relating to the handles that are accessing the queues is displayed.

You cannot use TYPE as a filter keyword.

Queue status

For queue status, the following information is always returned for each queue that satisfies the selection criteria, except where indicated:
  • Queue name
  • Type of information returned (TYPE parameter)
  • On platforms other than z/OS, current queue depth (CURDEPTH parameter)
  • On z/OS only, the queue-sharing group disposition (QSGDISP parameter)
The following parameters can be specified for TYPE(QUEUE) to request additional information for each queue. If a parameter is specified that is not relevant for the queue, operating environment, or type of status information requested, that parameter is ignored.
CURDEPTH
The current depth of the queue, that is, the number of messages on the queue, including both committed messages and uncommitted messages.
IPPROCS
The number of handles that are currently open for input for the queue (either input-shared or input-exclusive). This number does not include handles that are open for browse.

For shared queues, the number returned applies only to the queue manager generating the reply. The number is not the total for all the queue managers in the queue-sharing group.

LGETDATE
The date on which the last message was retrieved from the queue since the queue manager started. A message being browsed does not count as a message being retrieved. When no get date is available, perhaps because no message has been retrieved from the queue since the queue manager was started, the value is shown as a blank. For queues with QSGDISP(SHARED), the value shown is for measurements collected on this queue manager only.

This parameter is also displayed when you specify the MONITOR parameter.

A value is only displayed for this parameter if MONQ is set to a value other than OFF for this queue.

LGETTIME
The time at which the last message was retrieved from the queue since the queue manager started. A message being browsed does not count as a message being retrieved. When no get time is available, perhaps because no message has been retrieved from the queue since the queue manager was started, the value is shown as a blank. For queues with QSGDISP(SHARED), the value shown is for measurements collected on this queue manager only.

This parameter is also displayed when you specify the MONITOR parameter.

A value is only displayed for this parameter if MONQ is set to a value other than OFF for this queue.

LPUTDATE
The date on which the last message was put to the queue since the queue manager started. When no put date is available, perhaps because no message has been put to the queue since the queue manager was started, the value is shown as a blank. For queues with QSGDISP(SHARED), the value shown is for measurements collected on this queue manager only.

This parameter is also displayed when you specify the MONITOR parameter.

A value is only displayed for this parameter if MONQ is set to a value other than OFF for this queue.

LPUTTIME
The time at which the last message was put to the queue since the queue manager started. When no put time is available, perhaps because no message has been put to the queue since the queue manager was started, the value is shown as a blank. For queues with QSGDISP(SHARED), the value shown is for measurements collected on this queue manager only.

This parameter is also displayed when you specify the MONITOR parameter.

A value is only displayed for this parameter if MONQ is set to a value other than OFF for this queue.

Note: Moving the system clock backwards should be avoided in case the LPUTTIME is being used to monitor the messages. The LPUTTIME of a queue is only updated when a message that arrives on the queue has a PutTime greater than the existing value of LPUTTIME. Because the PutTime of the message is less than the existing LPUTTIME of the queue in this case, the time is left unchanged.
MEDIALOG
The log extent or journal receiver needed for media recovery of the queue. On queue managers on which circular logging is in place, MEDIALOG is returned as a null string.

This parameter is valid on AIX, HP-UX, Linux, IBM i, Solaris, and Windows.

MONQ
Current level of monitoring data collection for the queue.

This parameter is also displayed when you specify the MONITOR parameter.

MSGAGE
Age, in seconds, of the oldest message on the queue. The maximum displayable value is 999999999; if the age exceeds this value, 999999999 is displayed.

This parameter is also displayed when you specify the MONITOR parameter.

A value is only displayed for this parameter if MONQ is set to a value other than OFF for this queue.

OPPROCS
This is the number of handles that are currently open for output for the queue.

For shared queues, the number returned applies only to the queue manager generating the reply. The number is not the total for all the queue managers in the queue-sharing group.

QSGDISP
Indicates the disposition of the queue. The value displayed is one of the following:
QMGR
The object was defined with QSGDISP(QMGR).
COPY
The object was defined with QSGDISP(COPY).
SHARED
The object was defined with QSGDISP(SHARED).

This parameter is valid on z/OS only.

For shared queues, if the CF structure used by the queue is unavailable or has failed, the status information might be unreliable.

You cannot use QSGDISP as a filter keyword.

QTIME
Interval, in microseconds, between messages being put on the queue and then being destructively read. The maximum displayable value is 999999999; if the interval exceeds this value, 999999999 is displayed.

The interval is measured from the time that the message is placed on the queue until it is retrieved by an application and, therefore, includes any interval caused by a delay in committing by the putting application.

Two values are displayed:
  • A value based on recent activity over a short time period.
  • A value based on activity over a longer time period.

These values depend on the configuration and behavior of your system, as well as the levels of activity within it, and serve as an indicator that your system is performing normally. A significant variation in these values might indicate a problem with your system. For queues with QSGDISP(SHARED), the values shown are for measurements collected on this queue manager only.

This parameter is also displayed when you specify the MONITOR parameter.

A value is only displayed for this parameter if MONQ is set to a value other than OFF for this queue.

UNCOM
Indicates whether there are any uncommitted changes (puts and gets) pending for the queue. The value displayed is one of the following:
YES

On z/OS, there are one or more uncommitted changes pending.

NO
There are no uncommitted changes pending.
n
On platforms other than z/OS, an integer value indicating how many uncommitted changes are pending.

For shared queues, the value returned applies only to the queue manager generating the reply. The value does not apply to all the queue managers in the queue-sharing group.

Handle status

For handle status, the following information is always returned for each queue that satisfies the selection criteria, except where indicated:
  • Queue name
  • Type of information returned (TYPE parameter)
  • On platforms other than z/OS, user identifier (USERID parameter) - not returned for APPLTYPE(SYSTEM)
  • On platforms other than z/OS, process ID (PID parameter)
  • On platforms other than z/OS, thread ID (TID parameter)
  • On platforms other than z/OS, application tag (APPLTAG parameter)
  • Application type (APPLTYPE parameter)
  • On platforms other than z/OS, whether the handle provides input access (INPUT parameter)
  • On platforms other than z/OS, whether the handle provides output access (OUTPUT parameter)
  • On platforms other than z/OS, whether the handle provides browse access (BROWSE parameter)
  • On platforms other than z/OS, whether the handle provides inquire access (INQUIRE parameter)
  • On platforms other than z/OS, whether the handle provides set access (SET parameter)
The following parameters can be specified for TYPE(HANDLE) to request additional information for each queue. If a parameter that is not relevant is specified for the queue, operating environment, or type of status information requested, that parameter is ignored.
APPLDESC
A string containing a description of the application connected to the queue manager, where it is known. If the application is not recognized by the queue manager the description returned is blank.
APPLTAG
A string containing the tag of the application connected to the queue manager. It is one of the following:
  • z/OS batch job name
  • TSO USERID
  • CICS APPLID
  • IMS region name
  • Channel initiator job name
  • IBM i job name
  • UNIX process
    Note: On HP-UX if the process name exceeds 14 characters, only the first 14 characters are shown. On all other platforms if the process name exceeds 28 characters, only the first 28 characters are shown.
  • Windows process
    Note: The returned value consists of the full program path and executable file name. If it is more than 28 characters long, only the first 28 characters are shown.
  • Internal queue manager process name

Application name represents the name of the process or job that has connected to the queue manager. In the instance that this process or job is connected via a channel, the application name represents the remote process or job rather than the local channel process or job name.

APPLTYPE
A string indicating the type of the application that is connected to the queue manager. It is one of the following:
BATCH
Application using a batch connection
RRSBATCH
RRS-coordinated application using a batch connection
CICS
CICS transaction
IMS
IMS transaction
CHINIT
Channel initiator
SYSTEM
Queue manager
SYSTEMEXT
Application performing an extension of function that is provided by the queue manager
USER
A user application
ASID
A four-character address-space identifier of the application identified by APPLTAG. It distinguishes duplicate values of APPLTAG.

This parameter is returned only when the queue manager owning the queue is running on z/OS, and the APPLTYPE parameter does not have the value SYSTEM.

ASTATE
The state of the asynchronous consumer on this queue.

Possible values are:

ACTIVE
An MQCB call has set up a function to call back to process messages asynchronously and the connection handle has been started so that asynchronous message consumption can proceed.
INACTIVE
An MQCB call has set up a function to call back to process messages asynchronously but the connection handle has not yet been started, or has been stopped or suspended, so that asynchronous message consumption cannot currently proceed.
SUSPENDED
The asynchronous consumption call-back has been suspended so that asynchronous message consumption cannot currently proceed on this queue. This can be either because an MQCB call with Operation MQOP_SUSPEND has been issued against this object handle by the application, or because it has been suspended by the system. If it has been suspended by the system, as part of the process of suspending asynchronous message consumption the call-back function is initiated with the reason code that describes the problem resulting in suspension. This code is reported in the Reason field in the MQCBC structure that is passed to the call-back function.

For asynchronous message consumption to proceed, the application must issue an MQCB call with the Operation parameter set to MQOP_RESUME.

SUSPTEMP
The asynchronous consumption call-back has been temporarily suspended by the system so that asynchronous message consumption cannot currently proceed on this queue. As part of the process of suspending asynchronous message consumption, the call-back function is called with the reason code that describes the problem resulting in suspension. This code is reported in the Reason field in the MQCBC structure passed to the call-back function.

The call-back function is initiated again when asynchronous message consumption is resumed by the system, when the temporary condition has been resolved.

NONE
An MQCB call has not been issued against this handle, so no asynchronous message consumption is configured on this handle.
BROWSE
Indicates whether the handle is providing browse access to the queue. The value is one of the following:
YES
The handle is providing browse access.
NO
The handle is not providing browse access.
CHANNEL
The name of the channel that owns the handle. If there is no channel associated with the handle, this parameter is blank.

This parameter is returned only when the handle belongs to the channel initiator.

CONNAME
The connection name associated with the channel that owns the handle. If there is no channel associated with the handle, this parameter is blank.

This parameter is returned only when the handle belongs to the channel initiator.

HSTATE
Whether an API call is in progress.
Possible values are:
ACTIVE
An API call from a connection is currently in progress for this object. For a queue, this condition can arise when an MQGET WAIT call is in progress.

If there is an MQGET SIGNAL outstanding, then this value does not mean, by itself, that the handle is active.

INACTIVE
No API call from a connection is currently in progress for this object. For a queue, this condition can arise when no MQGET WAIT call is in progress.
INPUT
Indicates whether the handle is providing input access to the queue. The value is one of the following:
SHARED
The handle is providing shared-input access.
EXCL
The handle is providing exclusive-input access.
NO
The handle is not providing input access.
INQUIRE
Indicates whether the handle currently provides inquire access to the queue. The value is one of the following:
YES
The handle provides inquire access.
NO
The handle does not provide inquire access.
OUTPUT
Indicates whether the handle is providing output access to the queue. The value is one of the following:
YES
The handle is providing output access.
NO
The handle is not providing output access.
PID
Number specifying the process identifier of the application that has opened the specified queue.

This parameter is not valid on z/OS.

PSBNAME
The eight characters long name of the program specification block (PSB) associated with the running IMS transaction. You can use the PSBNAME and PSTID to purge the transaction using IMS commands. It is valid on z/OS only.

This parameter is returned only when the APPLTYPE parameter has the value IMS.

PSTID
The four character IMS program specification table (PST) region identifier for the connected IMS region. It is valid on z/OS only.

This parameter is returned only when the APPLTYPE parameter has the value IMS.

QMURID
The queue manager unit of recovery identifier. On z/OS, this value is a 6-byte log RBA, displayed as 12 hexadecimal characters. On platforms other than z/OS, this value is an 8-byte transaction identifier, displayed as m.n where m and n are the decimal representation of the first and last 4 bytes of the transaction identifier.

You can use QMURID as a filter keyword. On z/OS, you must specify the filter value as a hexadecimal string. On platforms other than z/OS, you must specify the filter value as a pair of decimal numbers separated by a period (.). You can only use the EQ, NE, GT, LT, GE, or LE filter operators.

QSGDISP
Indicates the disposition of the queue. It is valid on z/OS only. The value is one of the following:
QMGR
The object was defined with QSGDISP(QMGR).
COPY
The object was defined with QSGDISP(COPY).
SHARED
The object was defined with QSGDISP(SHARED).

You cannot use QSGDISP as a filter keyword.

SET
Indicates whether the handle is providing set access to the queue. The value is one of the following:
YES
The handle is providing set access.
NO
The handle is not providing set access.
TASKNO
A seven-digit CICS task number. This number can be used in the CICS command "CEMT SET TASK(taskno) PURGE" to end the CICS task. This parameter is valid on z/OS only.

This parameter is returned only when the APPLTYPE parameter has the value CICS.

TID
Number specifying the thread identifier within the application process that has opened the specified queue.

This parameter is not valid on z/OS.

An asterisk indicates that this queue was opened using a shared connection.

For further information about shared connections see Shared (thread independent) connections with MQCONNX.

TRANSID
A four-character CICS transaction identifier. This parameter is valid on z/OS only.

This parameter is returned only when the APPLTYPE parameter has the value CICS.

URID
The external unit of recovery identifier associated with the connection. It is the recovery identifier known in the external syncpoint coordinator. Its format is determined by the value of URTYPE.

You cannot use URID as a filter keyword.

URTYPE
The type of unit of recovery as seen by the queue manager. It is one of the following:
  • CICS (valid only on z/OS)
  • XA
  • RRS (valid only on z/OS)
  • IMS (valid only on z/OS)
  • QMGR

URTYPE identifies the EXTURID type and not the type of the transaction coordinator. When URTYPE is QMGR, the associated identifier is in QMURID (and not URID).

USERID
The user identifier associated with the handle.

This parameter is not returned when APPLTYPE has the value SYSTEM.