Share via


Message Queuing Performance Monitoring

Applies To: Windows Server 2008

Monitoring performance

You can monitor the performance of Message Queuing by using the performance counters provided. You can view these performance counters using Reliability and Performance Monitor. The default performance counters are grouped under the following objects:

  • MSMQ Service

  • MSMQ Queue

  • MSMQ Session

  • MSMQ Incoming HTTP Traffic

  • MSMQ Outgoing HTTP Session

  • MSMQ Incoming Multicast Session

  • MSMQ Outgoing Multicast Session

For instructions on tracking counters, see Track Message Queuing Performance Counters.

Note

Performance counters are not available when multiple instances of Message Queuing are running in a server cluster.

Note

Only the MSMQ Service and MSMQ Queue objects are always visible.

MSMQ Service performance object

The MSMQ Service performance object is provided on Message Queuing servers and independent clients. The MSMQ service object contains performance counters that you can use to monitor Message Queuing statistics for a selected computer.

The value you see for memory usage includes the memory space occupied by all messages in local queues on the computer. Because recoverable messages are stored on disk, this memory space is backed up by memory-mapped files on disk, not from the Windows Server 2003 family paged memory pool. For more information about how messages are stored, see "Local message storage" in Message Storage.

MSMQ Queue performance object

The MSMQ Queue performance object contains performance counters that you can use to monitor message statistics for a selected queue. There can be an instance of the object for each open queue and for each queue containing messages on the computer where the queue resides up to the maximum number of instances allowed on that computer. In addition, there can be an instance for each outgoing queue opened for every destination queue on the computer where the outgoing queue resides up to the maximum number of instances allowed on that computer.

The name given a queue counter is the format name of the queue, unless the queue is an outgoing queue, in which case the name is the format name without the "PRIVATE=", "PUBLIC=", or "DIRECT=" prefix. For example, the following outgoing queues have the following queue counter names.

Outgoing queue Queue counter name

DIRECT=https://fake/msmq/q1

http:\\fake\msmq\q1

DIRECT=OS:fake\q1

os:fake\q1

DIRECT=TCP:10.0.0.0\q1

tcp:10.0.0.0\q1

Note that there can potentially be multiple outgoing queues (and counter instances) for the same queue, opened with different format names. If a connector application is running on the computer, a counter is available for the connector queue also; the queue name is displayed as **foreign=**GUID.

Under Instance, only the first 97 queues created on the computer, including private queues, are listed. The queue counters for a specific computer appear for each instance. The Computer Queues instance represents the source or computer journal and the dead-letter queue for the computer. The Bytes in Queue and Messages in Queue counters monitor that computer's dead-letter queue. The Bytes in Journal and Messages in Journal counters then monitor the computer journal (Journal messages in the System Queues folder).

An outgoing queue is identifiable because the computer name listed in the counter instance matches the name of the computer on which the corresponding destination queue resides.

MSMQ Session performance object

The MSMQ Session performance object is visible only when the computer has established an active session with another Message Queuing computer. This object contains counters that can be used to monitor statistics about active sessions between computers running Message Queuing. Multiple instances of this object may be listed, one for each session. There can be an instance of this object on both computers involved in each session up to the maximum number of instances allowed on each computer. Instance lists the IP address of the computer with which there is an active session.

Performance objects for HTTP messages

The MSMQ Incoming HTTP Traffic and MSMQ Outgoing HTTP Session performance objects include counters that monitor messages sent over HTTP transport. These objects contain counters that monitor statistics about incoming HTTP messages, the rates at which the messages and message bytes arrive at the computer in an incoming HTTP connection, the total number of HTTP messages that arrived in the connection, and the total number of message bytes that arrived in the connection as well as counters that monitor the statistics about active outgoing HTTP sessions between the computer and other computers, the rates at which message bytes and messages are sent from the computer in a specific outgoing session, the total number of HTTP messages sent in the session, and the total number of message bytes sent in the session.

Performance objects for multicast messaging

The MSMQ Incoming Multicast Session and MSMQ Outgoing Multicast Session performance objects contain counters that monitor messages sent in multicast sessions. These objects contain counters that monitor statistics about active incoming multicast sessions, the rates at which the messages and message bytes arrive at the computer in a specific incoming multicast session, the total number of multicast messages that arrived in the session, and the total number of message bytes that arrived in the session as well as counters that monitor the statistics about active outgoing multicast sessions between the computer and other computers, the rates at which message bytes and messages are sent from the computer in a specific outgoing session, the total number of multicast messages sent in the session, and the total number of message bytes sent in the session.

Improving messaging performance

If available processing resources (CPU time) are not limiting messaging performance, it is possible that independent clients and Message Queuing servers can improve messaging performance by storing the various message and log files used to implement messaging across multiple physical disks.

To determine whether your computers are limited by disk access or by processing power, track the % Processor Time counter (located in the Processor object) and the Avg. Disk Queue Length counter (located in the DiskLength object). If the sustained % Processor Time value is above 75 percent during the time messages are being sent, adding processing capacity may improve messaging performance. If the Avg. Disk Queue Length value for any drive is greater than 0.6 when messages are being sent, additional disks may improve messaging performance.

For information about how to store the message and log files on separate physical disks, see Store Messages on Multiple Disk Drives.