Monitor IBM MQ queue managers, queues, channels, topics, and listeners by collecting performance metrics and system events into Dynatrace via OneAgent or ActiveGate.
Monitor performance metrics from IBM MQ queue managers running locally on a OneAgent host or remotely from ActiveGate instances using the
IBM MQ extension.
LD_LIBRARY_PATH on Linux.
The user running the extension must be able to find these libraries.User running the OneAgent dtuser by default must also have read access to the queue manager directories /var/mqm/qmgrs/<queue_manager> and read/write to log directories /var/mqm/log so that it can bind properly.
Ensure MQ libraries are accessible by dtuser or whichever user your OneAgent service is running under. Default location for these libraries is /opt/mqm/lib64.
By default, IBM MQ installs an ldconfig file called /etc/ld.so.conf.d/mqm.conf that adds /usr/lib64 to the LD_LIBRARY_PATH.
Ensure the IBM MQ library's symbolic links to /opt/mqm/lib64 are found on that path.
If there is no reference in /usr/lib64 to /opt/mqm/lib64 libraries, you may have to create your own .conf file and place it in /etc/ld.so.conf.d/.
Using ldconfig allows the MQ libraries to be loaded by default.
To do this:
ibmmq_ext.conf./opt/mqm/lib64.ldconfig.Extensions on the left menu, select IBM MQ.Select which hosts will run this extension.
dtuser by default.Rules are evaluated in sequential order.
You can include or exclude objects from the result of the previous rule.
For example, *, -SYSTEM.*, SYSTEM.CLUSTER* consists of all queues, then removes those that start with SYSTEM and includes those that begin with SYSTEM.CLUSTER.
Pay close attention to the order in which you enter your rules, whether in Wizard or Advanced mode.
Read settings and Write settings.SYSTEM.ADMIN.*.EVENT queues to Dynatrace Logs.
See Collect System Events for configuration details.Select which feature sets (metric groups) you want this configuration to collect. Selecting too few doesn't give you the proper visibility, and you may miss out on essential performance data and key indicators that can be correlated between different objects.
Select which ActiveGate group runs this extension.
Rules are evaluated in sequential order.
You can include or exclude objects from the previous rule result.
For example, *, -SYSTEM.*, SYSTEM.CLUSTER* would include all queues, then remove those that start with SYSTEM.CLUSTER.
Pay close attention to the order in which you enter your rules, whether in Wizard or Advanced mode.
Get auto-defined channels: Enabling this setting collects auto-defined channels with the same filters defined above.
Send log event on Dead letter queue: Enable this if you would like any DLQ on any queue manager matching this configuration to trigger a log event indicating that the number of messages in DLQ exceeded the threshold. You may create an alert based on that log event.
Send log event on high queue depth from queue manager: Enable this if you want any matching queue on any queue manager in this configuration to trigger a log event when its configured depth threshold is exceeded. This threshold is configured on IBM MQ.
Send log event on low queue depth from queue manager: Enable this if you want any matching queue on any queue manager in this configuration to trigger a log event when its configured depth is lower than the threshold. This threshold is configured on IBM MQ.
Retrieve topology for improved transaction tracing: Enabling this setting collects the mappings for alias, remote, and cluster queues.
This mapping is then sent to Dynatrace to complement the mapping information for improved transaction tracing.
You may only need to collect this once unless your mappings on IBM MQ change frequently.
You may adjust and modify these mappings by going to
Settings > Collect and capture > Distributed tracing > IBM MQ queue managers.
When enabled, enter a Dynatrace token to communicate with the API with the permissions Read settings and Write settings.
Rename Queue manager: Enabling this setting allows you to add an alias to the queue manager defined above. The real queue manager's name is still included. This only differentiates queue managers with similar or the same names on Dynatrace. This doesn't rename any queue manager on IBM MQ.
Inquire metrics in bulk: Enabling this setting reduces the number of requests to IBM MQ and collects metrics for queues and channels in fewer requests, thus reducing time and potential CPU overhead. However, this setting requires granting permissions to all queues and all channels, even SYSTEM objects. This setting is not suitable for large environments with a large number of queues or channels.
Disable auto-alerting: Automatic problem creation for failures is disabled. Errors are still logged as events, but don't trigger problems. To create problems, add rules to trigger them from log events.
Get QSG Data: This feature is only available for queue managers running on z/OS. When enabled, it collects data for queues shared across queue managers. This setting could make the extension take longer to execute, as these queues could be on another queue manager that is part of the same queue sharing group.
Use Outbound SNI: This setting allows you to configure the routing type for Queue Managers running on OpenShift. This setting requires an OpenShift route to your queue manager to work.
Collect System Events: Enable to read and forward IBM MQ system events from SYSTEM.ADMIN.*.EVENT queues to Dynatrace Logs.
See Collect System Events for configuration details.
Debug flags: Highly experimental feature. Advanced expert flags for narrow-scope features not exposed in the standard UI. Leave blank in normal operation. Use only under strict recommendation by Dynatrace Support or Services. See Debug flags for supported flags and format.
Select which feature sets (metric groups) you want this configuration to collect. Selecting too few won't give you the proper visibility, and you may miss out on essential performance data and key indicators that can be correlated between different objects.
IBM MQ has several ways to authenticate client and local connections. The administrator of your MQ environment determines this according to their own security policies.
User authentication depends on the configuration of Channel Authentication (CHLAUTH).
CHLAUTH or ADOPTCTX is disabled, IBM MQ attempts to authenticate the user running the extension process, not the user passed in the endpoint configuration.ADOPTCTX and CHLAUTH are enabled, the user and password combination entered in the endpoint is passed in an MQCSP block that IBM MQ attempts to authenticate.
Consider this when authenticating users or if you receive unauthorized errors.
CHG permission is only required if collecting Enqueue/Dequeue metrics, which are obtained by issuing the RESET_Q_STATISTICS command. If you can't provide this permission, deselect those metrics on the Feature Sets page of your monitoring configuration.

CONTROL permission is only required if collecting Enqueue/Dequeue metrics.
When enabled, the extension reads PCF-format messages from IBM MQ system event queues and forwards them to Dynatrace as structured log entries.
The extension polls the following queues on each connected queue manager:
SYSTEM.ADMIN.QMGR.EVENTSYSTEM.ADMIN.CHANNEL.EVENTSYSTEM.ADMIN.PERFM.EVENTSYSTEM.ADMIN.CONFIG.EVENTSYSTEM.ADMIN.COMMAND.EVENTSYSTEM.ADMIN.LOGGER.EVENTSYSTEM.ADMIN.PUBSUB.EVENTOn z/OS queue managers, SYSTEM.ADMIN.LOGGER.EVENT doesn't exist and is skipped automatically.
Each line specifies a field path and a regular expression separated by =:
field_path=regex_pattern
Available field paths include:
| Field path | Example value |
|---|---|
|
|
|
|
|
|
|
|
|
|
IBM_MQ_MSG_HEADER.sReason=MQRC_NOT_AUTHORIZEDIBM_MQ_Q=.*CHANNEL.*IBM_MQ_MSG_DATA.S_COMMAND=MQCMD_INQUIRE.*
The connecting user must have GET permission on all SYSTEM.ADMIN.*.EVENT queues.
This is a highly experimental feature. Use only when directed by Dynatrace support or when enabling a documented advanced feature.
The Debug flags field accepts one or more advanced flags that activate narrow-scope features not exposed in the standard configuration UI. Leave this field blank in normal operation.
Flag format:
-flagName:positional1:positional2;key=value;key=value
:, also separated by :.;, also separated by ;.To retrieve the following metrics, statistics on queues are reset. To reset them, CHG permission must be granted to the queues:
Queue monitoring must be enabled on queues to retrieve the following metrics. Any monitoring resolution starts collecting these statistics.
There is no charge to use the extension. You are only charged for the data that the extension ingests.
The IBM MQ extension ingests custom metrics, which consume Davis Data Units (DDUs) (Dynatrace classic license) or Metrics powered by Grail (DPS), according to your license model.
The following formula is an approximation of the metric data points per minute, assuming all feature sets are enabled (non-z/OS):
((12) + (Local queues * 14) + (Alias + Remote queues) * 2 + (Channels * 20) + (Listeners) + (Topics * 4)) * Queue managers
The 12 queue manager metrics are: availability, uptime, connections, monitored queues, DLQ depth, active channels, log utilization, log in-use, log archive size, log reuse size, total log data sets, and full log data sets. Local queues have 14 metrics (depth, depth %, open handles, status, and enqueue/dequeue counts). Alias and remote queues have two metrics (inhibit GET/PUT only). Channels have 20 metrics across all channel feature sets.
For z/OS queue managers, add eight additional metrics per queue manager for pageset and buffer pool usage (the Usage - z/OS Only feature set).
For example:
1 Queue manager400 Local queues20 Alias and remote queues50 Channels1 Listener50 Topics( 12 + (400 * 14) + (20 * 2) + (50 * 20) + (1 * 1) + (50 * 4) ) * 1 =(12 + 5600 + 40 + 1000 + 1 + 200) = approximately 6,853 data points per minute
In the Dynatrace Platform Subscription, metric ingestion consumes Metrics powered by Grail according to the number of ingested metric data points.
Logs are only ingested if the Collect System Events feature is enabled (optional).
In the classic licensing model, metric ingestion consumes Davis Data Units (DDUs) at the rate of .001 DDUs per metric data point.
Logs are only ingested if the Collect System Events feature is enabled (optional).
When activating your extension using a monitoring configuration, you can limit monitoring to one of the feature sets. To work properly, the extension has to collect at least one metric after the activation.
In highly segmented networks, feature sets can reflect the segments of your environment. Then, when you create a monitoring configuration, you can select a feature set and a corresponding ActiveGate group that can connect to this particular segment.
All metrics that aren't categorized into any feature set are considered to be the default and are always reported.
A metric inherits the feature set of a subgroup, which in turn inherits the feature set of a group. Also, the feature set defined on the metric level overrides the feature set defined on the subgroup level, which in turn overrides the feature set defined on the group level.
| Metric name | Metric key | Description |
|---|---|---|
| Availability | ibmmq.listener.availability | Percentage this listener was running and available. |
| Metric name | Metric key | Description |
|---|---|---|
| Last message sent | ibmmq.channel.last_msg | Time when last message was sent, or MQI call was handled |
| Network time short | ibmmq.channel.nettime_short | Amount of time, in microseconds, to send an end of batch request to the remote end of the channel and receive a response over a short period. |
| Network time long | ibmmq.channel.nettime_long | Amount of time, in microseconds, to send an end of batch request to the remote end of the channel and receive a response over a longer period. |
| XMIT queue time short | ibmmq.channel.xmitqtime_short | Time, in microseconds, that messages remained on the transmission queue before being retrieved over a short period. |
| XMIT queue time long | ibmmq.channel.xmitqtime_long | Time, in microseconds, that messages remained on the transmission queue before being retrieved over a longer period. |
| Metric name | Metric key | Description |
|---|---|---|
| Bytes sent | ibmmq.channel.bytes_sent | Number of bytes sent |
| Bytes received | ibmmq.channel.bytes_rcvd | Number of bytes received |
| Buffers sent | ibmmq.channel.buffers_sent | Number of buffers sent. |
| Buffers received | ibmmq.channel.buffers_rcvd | Number of buffers received. |
| Metric name | Metric key | Description |
|---|---|---|
| Channel instances | ibmmq.channel.instances | Number of instances of this channel. This metric is only available to server-connection channels. |
| Total channel instances used | ibmmq.channel.total_instances_pct | Percentage of instances of this channel over its max intances. This metric is only available to server-connection channels. |
| Current shared conversations | ibmmq.channel.current_sharing_convs | Number of conversations currently active on this channel instance. This parameter is returned only for TCP/IP server-connection channels. |
| Metric name | Metric key | Description |
|---|---|---|
| Total pages | ibmmq.queue_manager.usage.pageset.total_pages | The total number of 4 KB pages in the page set. Available only on z/OS IBM MQ |
| Expand count | ibmmq.queue_manager.usage.pageset.expand_cnt | The number of times the page set has been dynamically expanded since restart. Available only on z/OS IBM MQ |
| Unused pages | ibmmq.queue_manager.usage.pageset.unused_pages | The number of pages that are not used (that is, available page sets). Available only on z/OS IBM MQ |
| Persistent pages | ibmmq.queue_manager.usage.pageset.persistent_data_pages | The number of pages holding persistent data. Available only on z/OS IBM MQ |
| Non-persistent pages | ibmmq.queue_manager.usage.pageset.nonpersistent_data_pages | The number of pages holding nonpersistent data. Available only on z/OS IBM MQ |
| Free buffers | ibmmq.queue_manager.usage.buffer_pool.free_buffers | Number of free buffers in buffer pool. Available only on z/OS IBM MQ |
| Percent of free buffers | ibmmq.queue_manager.usage.buffer_pool.percent_free_buffers | Number of free buffers as a percentage of all buffers in the buffer pool. Available only on z/OS IBM MQ |
| Total buffers | ibmmq.queue_manager.usage.buffer_pool.total_buffers | The number of buffers defined for specified buffer pool. Available only on z/OS IBM MQ |
| Metric name | Metric key | Description |
|---|---|---|
| Connections | ibmmq.queue_manager.connections | Number of active connections to queue manager |
| Queues count | ibmmq.queue_manager.monitored_queues | Number of monitored queues |
| DLQ depth | ibmmq.queue_manager.dlq_depth | Number of messages in dead letter queue |
| Active channels | ibmmq.queue_manager.active_channels | Number of channels in an active current status |
| Metric name | Metric key | Description |
|---|---|---|
| Inhibit publish | ibmmq.topic.inhibit_pub | Whether publishes are not allowed |
| Inhibit subscription | ibmmq.topic.inhibit_sub | Whether subscriptions are not allowed |
| Metric name | Metric key | Description |
|---|---|---|
| Messages | ibmmq.channel.messages | Number of messages sent or received, or number of MQI calls handled. |
| Batches | ibmmq.channel.batches | Number of completed batches |
| In-doubt messages | ibmmq.channel.current_messages | Number of messages in-doubt |
| Metric name | Metric key | Description |
|---|---|---|
| Long retries left | ibmmq.channel.long_retries_left | Number of long retry attempts remaining |
| Short retries left | ibmmq.channel.short_retries_left | Number of short retry attempts remaining |
| Metric name | Metric key | Description |
|---|---|---|
| Availability | ibmmq.queue_manager.availability | Percentage of time queue manager was reachable and available to this extension. While a queue manager sometimes may be up and running, availability is within the context of this extension. |
| Uptime | ibmmq.queue_manager.uptime | Time in seconds since last time queue manager started |
| Metric name | Metric key | Description |
|---|---|---|
| Log utilization | ibmmq.queue_manager.log_utilization | Percentage estimate of how well the queue manager workload is contained within the primary log space |
| Log in use | ibmmq.queue_manager.log_in_use | Percentage of the primary log space in use for restart recovery |
| Log archive size | ibmmq.queue_manager.log_archive_size | Amount of space occupied, in megabytes, by log extents no longer required for restart or media recovery, but waiting to be archived. |
| Log reuse size | ibmmq.queue_manager.log_reuse_size | Amount of space occupied, in megabytes, by log extents available to be reused. |
| z/OS Total log data sets | ibmmq.queue_manager.total_log_data_sets | The total number of active log data sets. |
| z/OS Full log data sets | ibmmq.queue_manager.full_log_data_sets | The total number of full active log data sets that have not yet been archived. |
| Metric name | Metric key | Description |
|---|---|---|
| Channel status | ibmmq.channel.status | Used to round up channel status counts for alerting and charting purposes |
| Last started time | ibmmq.channel.last_started | Time when this channel was last started |
| Metric name | Metric key | Description |
|---|---|---|
| Enqueue count | ibmmq.queue.enqueue_cnt | Number of messages enqueued. This count includes messages that have been put to the queue, but have not yet been committed. Enqueue rate also comes with this metric. |
| Dequeue count | ibmmq.queue.dequeue_cnt | Number of messages dequeued. This count includes messages that have been successfully retrieved (with a nonbrowse MQGET) from the queue, even though the MQGET has not yet been committed. Dequeue rate also comes with this metric. |
| Metric name | Metric key | Description |
|---|---|---|
| Publish count | ibmmq.topic.pub_cnt | The number of applications currently publishing to the topic. |
| Subcription count | ibmmq.topic.sub_cnt | The number of subscribers for this topic string, including durable subscribers who are not currently connected. |
| Metric name | Metric key | Description |
|---|---|---|
| Open input handles | ibmmq.queue.open_input_handles | Number of handles opened by applications for input |
| Open output handles | ibmmq.queue.open_output_handles | Number of handles opened by applications for output |
| Metric name | Metric key | Description |
|---|---|---|
| In-doubt | ibmmq.channel.in_doubt | Whether the channel is currently in doubt. 0 = No. 1 = Yes |
| Metric name | Metric key | Description |
|---|---|---|
| Inhibit GET | ibmmq.queue.inhibit_get | Whether queue inhibits MQGET |
| Inhibit PUT | ibmmq.queue.inhibit_put | Whether queue inhibits MQPUT |
| Metric name | Metric key | Description |
|---|---|---|
| Depth | ibmmq.queue.depth | Number of messages in queue |
| Depth percentage | ibmmq.queue.depth_percent | Percentage of messages filling up queue |
| Metric name | Metric key | Description |
|---|---|---|
| Oldest message | ibmmq.queue.oldest_message | Age in seconds of the oldest message on the queue. |
| Uncommitted messages | ibmmq.queue.uncommitted_messages | Number of handles opened by applications for output |
| Last GET | ibmmq.queue.last_get | Time at which the last message was successfully read from the queue. |
| Last PUT | ibmmq.queue.last_put | Time at which the last message was successfully put in queue. |
| Short time indicator | ibmmq.queue.time_indicator_short | Amount of time that a message spent on the queue over a short period. |
| Long time indicator | ibmmq.queue.time_indicator_long | Amount of time that a message spent on the queue over a long period. |
See Licensing and costs for the data points per minute formula and an example calculation.
Some metrics depend on the type of queues. Other metrics depend on your queue manager configuration and whether your user has enough permissions to collect them.
Are you missing Enqueue and Dequeue? Make sure your user has CHG permission to reset the queue statistics. Only then can you receive Enqueue and Dequeue metrics.
Are you missing the oldest message and the last get/put? Make sure Monitoring statistics is enabled on your queue manager for all queues.
Are you looking at Alias or Remote queues? Only locally defined queues have status metrics. Alias and Remote only have Inhibit GET/PUT metrics.
Check the AMQERR01.LOG on the queue manager itself.
This log file will tell you what it tried to authenticate and what permissions you missed.
If you're unable to connect to your queue manager, make sure that either the user running the extension process has permissions to the queue manager or ADOPTCTX and CHLAUTH are enabled so that they can authenticate the user and password combination passed in the MQCSP block.
libmqm_r.so not foundThe IBM MQ libraries were not found in the Unix PATH.
Make sure you follow the ldconfig step above under local deployment.
To verify that the libraries were loaded, run:
ldconfig -p | grep mqm
MQRC_HOST_NOT_AVAILABLE: Queue manager is not reachable from your ActiveGate.
This usually means a firewall rule is missing.
Because a queue manager can run on a custom port, you need to make sure that host:port is reachable from the ActiveGate running the extension.
MQRC_NO_MSG_AVAILABLE: This message can occur if a response from IBM MQ was not ready in time and it timed out. It's also possible that your queue manager's response was too large or blank.
If the response was too large, it could be your reply queue's MAX LENGTH is too small to accommodate the response payload. In such cases, try increasing that value.
MQRC_CONNECTION_BROKEN: The connection to the queue manager is severed due to a network interruption or the queue manager closed it.
Make sure your network performance is optimal.
Also, if you're using SSL, ensure you're not using an older TLS cipher that requires manual reset of TLS keys, such as TLS 1.2 AES-GCM ciphers. Switch to a TLS 1.3 Cipher that has automatic TLS keys reset.
Message Queues