A Guided Tour of the Common Information Model Repository
Before we take a hands-on look at Microsoft's implementation of the Common Information Model (CIM) repository, let us first examine its structure as defined by the DMTF. In the previous chapters, you have gleaned an idea of the structure and purpose of the CIM. In simple terms, it consists of the following four components:
Classes that define the structure of the information held in the store
Associations that define the relationships between elements in the repository
Methods that define the behavior of the managed objects
Properties that define individual characteristics of each managed object
Each of these components can have associated instances that hold the management data. They were designed with the basic purpose of providing a platform-independent means of describing the manageable aspects of all types of logical and physical components in the enterprise.
The objective of this chapter is not to describe every class, property, method, and association within the CIM schema and Win32 extended schema. First, this would not make particularly interesting reading, and second, it would prove somewhat overwhelming as an introduction to the CIM. Instead, the focus of this chapter is to examine the classes and associations that hold the elements of most interest to users of WMI. This includes the WMI system classes that define the properties and methods relevant to WMI's security model, the classes that define the WMI provider architecture, and the classes of the CIM schema. By the end of the chapter, you should have a solid enough knowledge of the structure of the repository to move through it with confidence.
We shall use Microsoft's WMI CIM Studio to look at the classes within the CIM repository. During the course of the chapter, we also shall look briefly at the Managed Object Format (MOF) so that you can better understand some of the terminology used in the WMI CIM Studio. For a more complete list of the syntax and semantics used in the MOF, you can refer to the platform SDK documentation available from the MSDN Web site.
Recall from the previous chapter that the CIM is a conceptual model for storing enterprise management informationit is not a physical implementation (that is, the DMTF does not supply a downloadable version of WBEM that you can install as part of your operating system). It is the responsibility of vendors such as Microsoft, Intel, or Hewlett-Packard to adhere to the DMTF's CIM standard and produce their own physical implementations. Microsoft has done this for its range of Windows operating systems. The CIM repository supplied as part of WMI is a data store structured in accordance with the DMTF's CIM. It is supplied with any of Microsoft's WMI-compliant operating systems (Windows 9x/2000/NT4.0/WinXp/.NET): It holds management information structured in accordance with the CIM.
The aim of this chapter is to familiarize you with the CIM repository that is shipped with WMI. This will serve two purposes: first, it will give you some idea of the vast array of information that you can retrieve from the repository, and second, it will provide you with an introduction to the structure and relationships of the existing classes. This knowledge will prove useful especially if you are faced with the task of instrumenting your own product within the CIM repository or need to elicit management information from the repository about managed objects. To explore the repository, we shall use the tools supplied with the WMI SDK, so if you did not install the SDK during your study of Chapter 3, you should do so now.
Metadata
"Metadata" is a new term to those who are not familiar with data modeling. The Greek word "meta-" is a prefix that means "behind" or "hidden." If you are familiar with HTML scripting, you will have encountered the prefix in metatags. Metatags describe the characteristics of information presented on a Web page (for example, to specify text displaying Bold or in Italics). Metadata is "data that describes data" or, more precisely, definitional data.
Admittedly, this is a broad definition, so let us define metadata more fully in terms of the CIM. We know from previous chapters that the information available from CIM is described by a series of classes and associations, and the elements contained therein (methods, properties, and references). These constructs describe the data available to WMI client applications and are classified as metadata, as you can see in Table 4.1.
The information in the Property and Type columns is metadata, as it describes the information we can retrieve, which is listed in the Value column. The Property and Type columns represent "data about data." The information in the Value column is instance datathe data that metadata describe. Metadata is a generic term and applies to a broad spectrum of data; for example, class information is metadata. Metadata also includes descriptive information about the context, quality and condition, or characteristics of the data, such as WMI system classes and properties. It is important to make the distinction between metadata and instance data because the CIM repository was envisaged by the DMTF primarily, although not exclusively, as a store for metadata.