SiteScope User's Guide


WebSphere MQ Status Monitor

The WebSphere MQ Status Monitor allows you to monitor the performance attributes of MQ Objects: channels and queues, on MQ Servers v5.2 and above (formerly known as MQSeries). Both performance attributes and events for channels and queues can be monitored.

Error and warning thresholds for the monitor can be set on as many as fifteen function measurements.

Usage Guidelines

This monitor requires an Option license in order to be enabled. Contact for the MQ Status Monitor must be obtained and installed into SiteScope.

The default run schedule for this monitor is every 10 minutes, but you can change it to run more or less often using the Update every setting.

Software Prerequisites

This monitor requires two IBM MQ SupportPacs to be downloaded from the IBM Web site and installed on the same machine where the SiteScope server is running:

  • MA88: MQSeries classes for Java, version 5.2.2 (5648-C60) or later. Click here to go to the IBM Web site for this support package.

    Note: In some cases this component may already be bundled with the IBM MQ Server installation. Check your IBM MQ install documentation for details.

  • MS0B: WebSphere MQ Java classes for PCF. Click here to go to the IBM Web site for this support package.

Follow the instructions for installing both support pacs. Then copy the following files from these installations to <SiteScope install path>\SiteScope\java\lib\ext directory :

com.ibm.mq.jar
com.ibm.mq.pcf.jar
connector.jar

After installing the required libraries, stop and restart SiteScope.

Channel Status Codes

The MQ Channel Status codes returned by SiteScope are different than the ones returned by the MQ Series server as detailed in the IBM MQ documentation. This mapping in the SiteScope MQ monitor was necessary for maintaining compatibility with other Mercury products. The table below compares the mapping used for the SiteScope monitor relative to the mapping used by IBM. In the Mercury code scheme the magnitude of the code attempts to directly correlate to the health of the channel, which may be used for graphing and reporting purposes.

MQ Channel Status

MQ Code(s)

SiteScope Code

Stopped/Paused 6, 8 0
Initializing/Stopping 4, 13 1
Starting 2 2
Retrying 5 3
Requesting 7 4
Binding 1 5
Running 3 6

Monitoring MQ Events

For events, two system queues are regularly polled for the presence of relevant events:

  • SYSTEM.ADMIN.PERFM.EVENT - for queue performance events
  • SYSTEM.ADMIN.CHANNEL.EVENT - for channel events

On each scheduled run of the MQ monitor (which contain event counters), one or both of these system queues are queried for the presence of events that match the chosen event type, the source queue or channel that generated the event, and its queue manager. Events found are only browsed and not removed from the queue, so such events can continue to be consumed by other applications, if necessary. On each run the MQ monitor will report the number of event occurrences found since the last run of the monitor.

The monitor will strive to not report the same event occurrence more than once. This is accomplished by recording the timestamp of the most recent event browsed, so that in the next monitor run any events encountered that were generated prior to this recorded timestamp will be ignored.

Enabling Queue Events on the MQ Server

By default queue performance events are disabled in the MQ server. In order for SiteScope to monitor these events you must enbale the MQ server to generate these events. A MQSC command must be issued on each queue and for each event to be enabled. In addition, appropriate threshold values must be set on each queue and for each event, that specify the conditions for generating the event. Consult the IBM MQ MQSC Command Reference for more information. On the other hand, channel events are always enabled and require no further action for them to operate.

Specifying Alternate Queue Managers

It is possible to set up an MQSeries environment such that events from remote queue managers are routed to a central queue manager for monitoring. If the event configured for monitoring by the user is from a remote queue manager (a queue manager other than the one identified in the Queue Manager box of the MQ Monitor defintion page), it must be specified in the Alternate Queue Manager box.

Authentication Issues

This section describes several authentication issues that may apply in different environments.

Windows Network Authentication

In the case of a Windows-based SiteScope instance monitoring a Windows-based MQ server, the default authentication scheme requires that SiteScope be running under a user account that is recognized by the target server's Windows security group. Specifically, the SiteScope user must be added to the server's mqm group.

Special Authentication for MQ Series 5.3 running on Solaris

When attempting to use the WebSphere MQ Status Monitor to monitor MQ Series servers running Solaris you are likely to see a critical error message such as the following in the Browse Counters page in the Instances field of the Available Measurements window.

Failed to retrieve available instances. Monitor returned the following error: MQ exception: CC = 2 RC = 2035

This equates to a MQRC_NOT_AUTHORIZED error meaning that SiteScope is not authorized to access the MQ Series Channels.

One way to use the SiteScope WebSphere MQ Status Monitor to monitor the MQ Series 5.3 running on Solaris is to create a new channel that does not require SSL authorization. Use the following procedure to create a new channel using command line utilities on the MQ Series server.

Note: This procedure assumes that you or the MQ Series administrator have access and permissions to run the noted utilities on the server where the MQ Series server is running.

To create a new channel that does not require SSL authorization

  1. On the IBM MQ Series server, open a console window and run the create MQ manager utility using the following syntax:

    crtmqm <queue_manager_name>

    For example, entering the following command

    crtmqm QM11

    will create a queue manager with the name QM11.

  2. Run the MQ Series command line utility for the queue manager name created above using the following syntax:

    runmqsc <queue_manager_name>

    For the current example, you would enter the <queue_manager_name> as entered in the step above as:

    $runmqsc QM11

    This activates MQ Series runmqsc command line utility.

  3. Using this utility, enter the following command to create a new channel with no authorization required:

    DEFINE CHANNEL(<channel_name>) CHLTYPE(SVRCONN) SSLCAUTH(OPTIONAL)

    For example,

    DEFINE CHANNEL(SITESCOPE_QM11) CHLTYPE(SVRCONN) SSLCAUTH(OPTIONAL)

    This example creates a new channel with the name SITESCOPE_QM11. Make a note of the <queue_manager_name> and <channel_name> entered in these steps. You will use these to set up the WebSphere MQ Status Monitor in SiteScope to use the newly created channel.

Custom Authentication Access Control

Your MQ server may require SiteScope to authenticate itself with a custom authentication option when connecting to retrieve metrics. If your network or application administrators have implemented any custom authentication mechanisms, it may be necessary to create a special security exit mechanism for SiteScope to enable monitoring of MQ series servers.

A feature has been built into this monitor type to invoke a user-developed, client-side security exit written in Java. Use the following to enable an authentication exit for the WebSphere MQ Status Monitor.

To enable user-defined client-side security exit for authentication:

  1. Create the security exit class using Java. Consult the appropriate administrators in your organization for the requirements for this class file.
  2. Using a text editor, open the SiteScope configuration file:

    SiteScope\groups\master.config

  3. Add a single line entry to the master.config file using the following syntax:

    _mqMonitorSecurityExit=com.mycompany.mq.MyExit

    where, in this example, the fully-qualified class name of the security exit component is "com.mycompany.mq.MyExit".

  4. Copy the custom security class file to a location in the classpath of the Java Virtual Machine (JVM) running on the SiteScope server. For example, copy the security exit class into the <SiteScope install path>\SiteScope\java\lib\ext directory.

    Note: You can only deploy one security exit class per SiteScope instance. Every WebSphere MQ Status Monitor running on that instance will invoke the same security exit.

Refer to the IBM WebSphere MQ documentation for more information on MQ security exits and other authentication schemes.

Completing the MQ Status Monitor Form

To display the MQ Status Monitor Form, either click the Edit link for an existing MQ Status Monitor in a monitor table, or click the add a Monitor link on a group's detail page and click the MQ Status monitor type link from the list of available monitor types.

Complete the items on the Add MQ Status Monitor Form as follows. First you need to specify details of the target MQ server that will be monitored, then click the Select Measurements link. There you will choose attributes (counters) of specified queues and/or channels to monitor. When you have completed your counter selections, click the Add Monitor button.

MQ Server Name
Specify the host name of the MQ Server you want to monitor. Enter the network name of the server or the IP address of the server. For example, mqmachinename.

MQ Server Port
Specify the port number of the target MQ Server. The installation default port is 1414.

Server Connection Channel
Enter the name of the server connection channel of the target MQ server. Check with the MQ Server administrator for the name syntax of the server connection channel

Queue Manager
Enter the name of the queue manager whose queues or channels will be monitored.

Alternate Queue Manager
You can optionally enter an alternate queue manager name that has been set up to forward its events to the primary queue manager specified above (if you are interested in monitoring such forwarded events also).

Selected Measurements
Lists measurements that you have chosen, if any. The Select Measurements link allows you to add or delete counters for the monitor. Click this link after you have specified all the server information above. The Measurement Selection page opens. See the section on Measurement Selection for information about selecting measurements for this monitor.

List of Available Metrics

The following performance attributes and events for queues can be monitored:

Current Queue Depth
Queue Open Input Count
Queue Open Output Count

Event: Queue Depth High
Event: Queue Depth Low
Event: Queue Full
Event: Queue Service Interval High
Event: Queue Service Interval OK

The following performance attributes and events for channels can be monitored:

Channel Status
Channel Time Between Sends
Channel Messages Transferred
Channel Bytes Sent
Channel Bytes Received
Channel Buffers Sent
Channel Buffers Received

Event: Channel Activated
Event: Channel Not Activated
Event: Channel Started
Event: Channel Stopped
Event: Channel Stopped by User

Update every
Select how often the monitor should access the URL entered above. The default interval is to run or update the monitor once every 10 minutes. Use the drop-down list to the right of the text box to specify another update interval in increments of seconds, minutes, hours, or days. The update interval must be 15 seconds or longer.

Title
Enter a title text for this monitor. This text is displayed in the group detail page, in report titles, and other places in the SiteScope interface. If you do not enter a title text, SiteScope will create a title based on the host, server, or URL being monitored.

When you are done, click the Add Monitor button to create it.

Advanced Options

The Advanced Options section presents a number of ways to customize monitor behavior and display. Use this section to customize error and warning thresholds, disable the monitor, set monitor-to-monitor dependencies, customize display options, and enter other monitor specific settings required for special infrastructure environments. The options for this monitor type are described below. Complete the entries as needed and click the Add or Update button to save the settings.

Disable
Check this box to temporarily disable this monitor and any associated alerts. To enable the monitor again, clear the box.

Timeout
The number of seconds that the monitor should wait for a response from the server before timing-out. Once this time period passes, the monitor will log an error and report an error status.

Note: Depending on the activity on the server, the time to build the server monitor statistics Web page may take more than 15 seconds. You should test the monitor with an Timeout value of more than 60 seconds to ensure that the server can build and serve the server monitor statistics Web page before the SiteScope monitor is scheduled to run again.

Verify Error
Check this box if you want SiteScope to automatically run this monitor again if it detects an error. When an error is detected, the monitor will immediately be scheduled to run again once.

Note: In order to change the run frequency of this monitor when an error is detected, use the Update every (on errors) option below.

Note: The status returned by the Verify Error run of the monitor will replace the status of the originally scheduled run that detected an error. This may cause the loss of important performance data if the data from the verify run is different than the initial error status.

Warning: Use of this option across many monitor instances may result in significant monitoring delays in the case that multiple monitors are rescheduled to verify errors at the same time.

Update Every (on error)
You use this option to set a new monitoring interval for monitors that have registered an error condition. For example, you may want SiteScope to monitor this item every 10 minutes normally, but as often as every 2 minutes if an error has been detected. Note that this increased scheduling will also affect the number of alerts generated by this monitor.

Schedule
By default, SiteScope monitors are enabled every day of the week. You may, however, schedule your monitors to run only on certain days or on a fixed schedule. Click the Edit schedule link to create or edit a monitor schedule. For more information about working with monitor schedules, see the section on Schedule Preferences for Monitoring.

Monitor Description
Enter additional information about this monitor. The Monitor Description can include HTML tags such as the >BR< and >B<>/BR< tags to control display format and style. The description will appear on the Monitor Detail page.

Report Description
Enter an optional description for this monitor that will make it easier to understand what the monitor does. For example, network traffic or main server response time. This description will be displayed on with each bar chart and graph in Management Reports and appended to the tool-tip displayed when you pass the mouse cursor over the status icon for this monitor on the monitor detail page.

Depends On
To make the running of this monitor dependent on the status of another monitor or monitor group, use the drop-down list to select the monitor on which this monitor is dependent. Select None to remove any dependency.

Depends Condition
If you choose to make the running of this monitor dependent on the status of another monitor, select the status condition that the other monitor or monitor group should have in order for the current monitor to run normally. The current monitor will be run normally as long as the monitor on which it depends reports the condition selected in this option.

List Order
By default, new monitors are listed last on the Monitor Detail page. You can use this drop-down list to choose a different placement for this monitor.

Setting Monitor Status Thresholds

SiteScope Application Monitors allow you to set multiple threshold conditions to determine the status reported by each monitor. The individual conditions are combined as logical OR relationships so that when one or more of the conditions (for example any of the conditions for Error if) are met the monitor status is set to the applicable condition. If multiple conditions are met for more than one status condition (such as conditions for both error and for warning), the status for the monitor is set to the highest valued condition. Thus a match of an error condition and a warning condition would be reported as an error status, error being the highest value, warning the next highest and good the lowest value.

Error if
Use one or more of the selection boxes in this item to define one or more error conditions for this monitor. Use the drop-down lists in these items to change error threshold(s) relative to the counters you have selected to check with this monitor. After choosing a counter or parameter, use the comparison operator drop-down list to specify an error threshold such as: >= (greater than or equal to), != (not equal to), or < (less than) and enter a comparison value in the box provided. Comparison values should be entered as whole numbers.

Warning if
Use one or more of the selection boxes in this item to define one or more warning conditions for this monitor. Use the drop-down lists in these items to change warning threshold(s) relative to the counters you have selected to check with this monitor. Set these values relative to those you set for the error threshold in the Error if item.

Good if
You can set this monitor to return a good status for certain conditions. You may define those conditions here. Complete this item as you would for the Error if and Warning if items.