Hardware inventory filters


When collecting hardware inventory information not all available data is generally needed, thus filters are applied to sort the required data from the information which is currently not being regarded as useful. Filters can be defined for different kinds of clients and for devices with different operating systems, for example.

Hardware inventory filters are completely customizable to be adapted to the specific needs of the different devices within your infrastructure. Hardware inventory objects can have one or several instances and attributes providing further information. These objects are completely customizable about name, number of instances, number of attributes and their types and contents.

To create hardware inventory filters

It is possible to create new inventory filters for the hardware inventory. These filters will then replace the configuration filters in the form of an .xml file on the devices to which the newly created filters will be assigned. This file is based on the default .xml hardware template. To create a new hardware inventory filter, proceed as follows:

  1. With the Hardware Inventory node selected in the left window pane select Edit> Create Filter.
    The Properties pop-up menu appears.
  2. Enter the name for the new hardware inventory filter into the provided field.
  3. Click OK to confirm the new object and close the window.

WMI Classes

Windows Management Instrumentation (WMI) is a component of the Windows operating system that provides management information and control in an enterprise environment. WMI can be used to query and set information about desktop systems, applications, networks, and other enterprise components. Developers can use WMI to create event monitoring applications that alert users when important incidents occur.

WMI provides a standardized means for managing your computer system, be it a local computer or all the computers in an enterprise. It is collecting data about the state of a managed object on the computer system and altering the state of the managed object by changing the data stored about the object. A managed object can be a hardware entity, such as a memory array, a port, or a disk drive. It can also be a software entity, such as a service, a user account, or a page file. WMI can manage the many components of a computer system. In managing a hard disk, WMI can be used to monitor the amount of free space that remains on the disk. You can also use WMI to remotely alter the state of the drive by deleting files, changing file security, or partitioning or formatting the drive.

This tab displays the list of all WMI classes which are available. Be aware, however, that it is not an exhaustive list, it contains the most commonly used classes, to which you can add specific classes if necessary.

In WMI, a class is an object that describes some aspect of an enterprise. You can use an object to hold information or control an aspect of your enterprise. For example, you can create a WMI object that describes a CD-ROM drive. An object works with a WMI provider to fill the properties of an object. Creating a class means defining the properties that describe that class. You can also define the functions you can call to manipulate the object that the class represents. Each class has key properties. You cannot create an instance of a class with more than 256 keys.

To create a new WMI class

  1. Select the Hardware Inventory node in the left window pane and go to the Managed WMI Classes tab.

  2. Select Edit > Create WMI Class .
    The Create WMI Class dialog box appears.
  3. Enter the desired data into the respective fields.

    FieldDescription
    WMI NamespaceEnter the name of the WMI namespace to use. If this field is left blank, the default namespace is used, that is, root/cimv2.
    Windows WMI ClassEnter the identification of the WMI class as provided by the Microsoft, for example, Win32_IDEControllerDevice
    Display NameEnter a descriptive name for the new WMI class, which is displayed as its name in the BMC Inventory Manager, for example, IDE controller.
  4. Click OK to create the new class and to close the window.

The newly created class will directly be displayed in the table in the right window pane.

WMI Filters

This node displays the list of WMI classes which are in the hwinvcfg.xml file. This file is part of the hardware inventory collection, it is made to suit the users needs. Inventory collection is done by "passing" the list of available WMI classes through this configuration file. The file is an XML formatted text file supplied with the agent and can be modified or added to as required.

To add a WMI class

To add new WMI class to the hardware configuration file it must exist in the common list of WMI classes listed in the Managed WMI Classes tab of the main Hardware Inventory node. To add a WMI class to the filter, proceed as follows:

  1. Select the filter to which a new class is to be added in the left window pane.
  2. Click Edit> Add WMI Class.
    The Select a WMI Class pop-up menu appears.
  3. Select the desired class from the list of the Name field. This is the WMI class to be added to the configuration file. This is the display name, not to Microsoft name.
  4. From the Action list, select the action to be taken when generating the hardware inventory. Select Accept to include the class in the inventory. Select Reject to exclude the class from the inventory.
  5. Click OK to confirm and close the window.

WMI attributes

A WMI class displays all its attributes, or properties which were added to the currently selected WMI class. These attribute lists tend to not be exhaustive, they include the most common attributes of the class. If a property important to your environment is missing in this list it can be added.

To create a WMI attribute

  1. Select the class to which a new attribute is to be added in the left window pane.
  2. Click Edit > Create Attribute .
    The Properties pop-up menu appears.
  3. Enter the data for the new attribute in the respective boxes.

    FieldDescription
    NameEnter the name of the class attribute or property.
    TypeSelect the type of the attribute value as it is entered in the database and displayed on the screen.
    UnitDefine in which type of unit the associated data item is expressed, for example, a size data item might have a value of bytes as its unit.
    Action

    Select the action to be taken when generating the hardware inventory. Select Accept to include the class in the inventory. Select Reject to exclude the class from the inventory.

  4. Click OK to confirm and close the window.

Hardware filter -General tab

The General tab of a WMI Class/Filter displays the following information about the class/filter:

Attribute

Description

Device Name

The name of the device on which the hardware was found. If a hardware element exists on more than one device there will be one entry per device in this table.

Name

Displays the name of the class/filter.

Action

This field displays the action that is to be taken when generating the inventory, possible values are ACCEPT and REJECT.

Hardware inventory filter cleaning rules

After the inventory collection has taken place, passing it through a translation cycle processes the list of attributes. The aim of this is to clean up the values of those attributes and format their output. The attributes values translation process repeats itself until no changes occur during a pass. This allows fairly complicated processing to take place by using fewer more focused translation entries.

To create a cleaning filter

To create a new cleaning filter, proceed as follows:

  1. Click Edit> Create Cleaning Filter.
    The Properties pop-up menu appears.
  2. Enter the data for the new filter in the respective boxes.
  3. Click OK to confirm and close the window.

MATCH Tag

This tab deals with the MATCH conditions for the hardware translation entry. The MATCH tag contains a number of attributes which in turn specify the conditions a hardware attribute must satisfy in order to match the translate hardware entry which will then take the requested action. The matching operator is an AND operator which means that all of the specified criteria must be satisfied for a match.

AttributeDescription
Filter NameEnter the name of the filter.
Value

Select the value criterion for matching a hardware attribute. The value supplied for the attribute is interpreted based on the attribute parameters and used to compare against the value filed of a hardware attribute.

  • Text - The value should be compared with the hardware entry name as is.
  • Pattern - The value of a tag is a hardware name pattern containing optional * and ? wildcards. This is the default value.
  • Regex - The value of the tag is a full regular expression which is applied to the hardware name to see if it matches or not.
Operator

Select the comparison operator to apply when performing the match.

  • eq - The value matches the name being checked. If the value is a pattern or a regex this means the pattern or the regex successfully matches the attribute value. This is the default setting.
  • ne - The value does not match the name being checked.
CaseDefine whether the comparisons done between the value and the attribute value are case sensitive or not. This is an integer value where a non-zero value means true and 0 means false.
DataEnter the data value to which the attribute must correspond.
NameEnter the attribute name criterion for matching an entry. The supplied value is interpreted based on the parameters and used to compare against the name field of a hardware attribute.
Value

Select the value criterion for matching a hardware attribute. The value supplied for the attribute is interpreted based on the attribute parameters and used to compare against the value filed of a hardware attribute.

  • Text - The value should be compared with the hardware entry name as is.
  • Pattern - The value of a tag is a hardware name pattern containing optional * and ? wildcards. This is the default value.
  • Regex - The value of the tag is a full regular expression which is applied to the hardware name to see if it matches or not.
ActionDefine the action that is to be taken when generating the inventory, that is, if the entry is to be accepted into the inventory or rejected.


MODIFY Tag

If the match criteria were all satisfied and the action was to accept the attribute value, the MODIFY Tag of a cleaning filter determines the characteristics of the hardware attribute to be changed. The child attributes contained within this tab are used to set and define individual attributes of the hardware entry being changed. This is in contrast to the attributes within the MATCH Tag tab which are used as comparison criteria.

AttributeDescription
Value

Select the value criterion for matching a hardware attribute. The value supplied for the attribute is interpreted based on the attribute parameters and used to compare against the value filed of a hardware attribute.

  • Text - The value should be compared with the hardware entry name as is.
  • Regex - The value of the tag is a full regular expression which is applied to the hardware name to see if it matches or not.
MatchUsed if the value parameter is also supplied and set to regex. Its value is a regular expression pattern which is matched to the value of the hardware entry. To be useful, the regular expression used must include parenthesized sub-expressions which can then be back-referenced in the tag value to perform partial text replacements within the attribute value field.
CaseDefines whether the comparisons done between the value and the attribute value are case sensitive or not. This is an integer value where a non-zero value means true and 0 means false.
DataEnter the data value to which the attribute must correspond.
NameEnter the attribute name criterion for matching an entry. The supplied value is interpreted based on the parameters and used to compare against the name field of a hardware attribute.
Was this page helpful? Yes No Submitting... Thank you

Comments