Share This:


What is a discovery sweep and when would you do one?   Beginning with BMC TrueSight Middleware and Transaction Monitor 8.0.00 you may configure the WebSphere MQ monitoring extensions to discover MQ objects such as queues, channels and the queue managers they reside on.   This feature is enabled by default on distributed systems and disabled by default for z/OS.   When enabled, newly added or removed objects are discovered during the next monitoring cycle causing their state to change in the object repository maintained by the services.    This allows you to use polices to register the objects for monitoring, associate them with your event and history templates and perform other actions when the objects are newly created and/or removed.   Policies may use attributes of the object that rarely change such as a description.   These are also known as stable attributes.   For performance, stable attributes are only published if the object is registered for monitoring and the value changes or at the time the object is discovered to exist.


So what is a discovery sweep?   A discovery sweep informs the WebSphere MQ monitoring extension to re-discover and publish all stable attributes for existing objects on one or more queue managers.   Essentially, this allows you to sync up those stable attributes for objects that you have not registered for monitoring that may have changed since being discovered or the last discovery sweep.    How often this is needed depends on your environment.   Stable attributes are named that for a reason, they rarely change.    A discovery sweep can take some time and it is not recommended you do it often.   Ideally you would perform a discovery sweep during off-peak times.    You may manually perform a discovery sweep from the Object Repository tab of the Management Console, use the Agent Discovery Sweep policy action with a schedule or use the repomgr command line tool with an external scheduler like cron.


One final tip.  If your policies are not being applied to an object that uses stable attributes in the policy expression, you may select the object in the tree of the “Object Repository” tab and view the current values for the stable attributes in the lower right pane.   Note the “Time when a stable attribute of the object was last updated” in the upper right pane.    If you feel they are out of sync, right click on the object’s queue manager in the tree and select “Discover Object” to restrict the discovery to that queue manager.    Alternatively, you may select the object’s agent in the tree and select “Discover Agent” to perform a discovery sweep for all queue mangers with discovery enabled under that agent.   Observe the "Time when a stable attribute of the object was last updated” change in the upper right pane.   Verify the stable attributes in the low right pane.   Policy actions will automatically be applied based on the updated stable attributes.


A reminder that although Policies apply to all object types, only the WebSphere MQ  extension from the BMC TrueSight Middleware and Transaction Monitor 8.0.00 or later release supports discovery of new or removed MQ objects.   For other extensions, only those objects registered for monitoring are visible to the services and since they are already registered for monitoring, their stable attributes are always in sync.