Understanding WMI Scripting

Chapter 6: The WMI Events Scripting

6.1 Objective

At this stage of the discussion, with the knowledge acquired from previous chapters about WQL and the WMI scripting API, we are ready to explore the WMI event scripting techniques. Up to now, each time we developed a script that runs on top of WMI, the code performed some actions with the manageable entities. The script did not perform monitoring functions. Some monitoring was performed using the permanent SMTP event consumer (see Chapter 2), but this did not involve scripting. Moreover, only one event type was used from the collection proposed by WMI. As WMI is designed to support event notifications, it makes sense that the event notification capabilities are also part of the WMI scripting API. The event scripting technique relies on the WMI event architecture, and some aspects of its usage are very similar to the asynchronous scripting techniques described in the previous chapter. The WMI event technology is probably one of the most powerful features offered by WMI. It offers different event types to trigger any action in an application. In this chapter, we examine the various event types available, how they are organized, and how to take full advantage of this technology from the scripting world.

6.2 Event notification

Managing an environment means more than simply performing tasks with the manageable entities; it also means being able to respond to situation changes. This implies that the technology used to perform the management tasks is able to detect changes. These changes are considered by...

UNLIMITED FREE
ACCESS
TO THE WORLD'S BEST IDEAS

SUBMIT
Already a GlobalSpec user? Log in.

This is embarrasing...

An error occurred while processing the form. Please try again in a few minutes.

Customize Your GlobalSpec Experience

Category: Project Management Services
Finish!
Privacy Policy

This is embarrasing...

An error occurred while processing the form. Please try again in a few minutes.