IBM MQ - Show queue manager status using the display qmstatus command

by
Jeremy Canfield |
Updated: August 04 2022
| IBM MQ articles
These examples are based on Linux. Switch to the mqm user.
su - mqm
The display qmstatus command can be used to determine if a queue manager is running or stopped. In this example, the queue manager named MANAGER01 is running.
echo "display qmstatus" | runmqsc MANAGER01
. . .
QMNAME(MANAGER01) STATUS(RUNNING)
In this example, the queue manager named MANAGER01 is running as standby.
echo "display qmstatus" | runmqsc MANAGER01
. . .
QMNAME(MANAGER01) STATUS(Running as standby)
In this example, the queue manager named MANAGER01 is running elsewhere.
echo "display qmstatus" | runmqsc MANAGER01
. . .
QMNAME(MANAGER01) STATUS(Running elsewhere)
In this example, the queue manager named MANAGER01 was ended normally.
echo "display qmstatus" | runmqsc MANAGER01
. . .
QMNAME(MANAGER01) STATUS(Ended normally)
The all option can be used to include additional fields in the output.
echo "display qmstatus all" | runmqsc MANAGER01
. . .
QMNAME(MANAGER01) STATUS(Running)
ARCHLOG( ) ARCHSZ(0)
CHINIT(RUNNING) CMDSERV(RUNNING)
CONNS(483) CURRLOG(S0776988.LOG)
INSTDESC( ) INSTNAME(Installation1)
INSTPATH(/opt/mqm) LDAPCONN(CONNECTED)
LOGINUSE(85)
LOGPATH(/var/logs/MANAGER001/)
LOGUTIL(92) MEDIALOG(S0774841.LOG)
MEDIASZ(34341) RECLOG(S0776986.LOG)
RECSZ(26) REUSESZ(0)
STANDBY(PERMIT) STARTDA(2021-02-25)
STARTTI(21.30.58)
Or, the dspmq command can be used as well.
Did you find this article helpful?
If so, consider buying me a coffee over at