Technote (FAQ)
Question
How do I determine the number of channels that are running for my queue manager?
Cause
You want to monitor your queue manager and try to avoid the following message, which indicates that the maximum number of channels has been reached.
AMQ9513: Maximum number of channels reached.
Answer
UNIX
In UNIX systems, you can enter the following compound command. Ensure to replace CHLNAME and QMGR with the proper values for your system:
echo "DISPLAY CHSTATUS(CHLNAME)" | runmqsc QMGR | grep 'AMQ8417' | wc -l
If you want to query for all channels, then use * for CHLNAME:
echo "DISPLAY CHSTATUS(*)" | runmqsc QMGR | grep 'AMQ8417' | wc -l
Windows
For Windows, there is no "grep" but "find" can be used instead:
echo DISPLAY CHSTATUS(CHLNAME) | runmqsc QMGR | find /c "AMQ8417"
Notes about the Windows "find" command:
- The command requires the string to be searched to be specified between double quotes, otherwise you will get an error: FIND: Parameter format not correct
- The flag /c counts the number of lines in which the string appears. Similar to the UNIX command: wc -l
IBMi
From command line, type:
1. QSH (to access the shell environment)
2. echo "DISPLAY CHSTATUS(*)" | /qsys.lib/qmqm.lib/runmqsc.pgm QMGR | grep 'AMQ8417' | wc -l
NOTE: This returns the value of the number of active channel connections
Product Alias/Synonym
WebSphere MQ WMQ
Rate this page:
Copyright and trademark information
IBM, the IBM logo and ibm.com are trademarks of International Business Machines Corp., registered in many jurisdictions worldwide. Other product and service names might be trademarks of IBM or other companies. A current list of IBM trademarks is available on the Web at "Copyright and trademark information" at www.ibm.com/legal/copytrade.shtml.