Unsupported content

 

This version of the product is no longer supported. However, the documentation is available for your convenience. You will not be able to leave comments.

discovery.wbemEnumInstances

discovery.wbemEnumInstances(target, class_name, properties, namespace, filter_locally)

Performs a WBEM query on the target and returns a list of DiscoveredWBEMInstance DDD nodes.

This is not a generic query for any device managed by WBEM; rather, it has been implemented solely as a part of storage discovery. Using it for any other purpose is untested and may provide unexpected results and very likely return extremely large lists of DDD nodes.

Where:

  • target– the endpoint being scanned,usually a node kind which can be used to get to the DiscoveryAccess, for example, a host node.
  • class_name – the name of the WBEM (CIM) class being queried, for example, CIM_LogicalElement.
  • properties – a list of properties to be retrieved from the class. Where a specified property does not exist on the target, it is ignored. The properties list is not case sensitive, for example, if you request stuff and the property is called STUFF or Stuff, it is returned, but in the case in which it is returned is the same as it is on the target.
  • The properties list must be present though it may be empty.
  • namespace – the WBEM namespace to query, for example, root/cimv2. Used with the class_name to identify objects of interest.
  • filter_locally – when set, the function does not request specific properties so all are returned. Only the specified properties are stored as DDD. This parameter can be used if a particular system does not support the retrieval of specific properties. The default is false, that is, request just the specified properties.

Returns a list of DiscoveredWBEM DDD nodes which hold the results. Each DiscoveredWBEM node has a list of attributes corresponding to those specified in the properties list, plus a  __PATH  attribute representing the local WBEM instance path for the object. The __PATH attribute is returned whether the  properties list is empty or not.

If the call fails, none are returned.

An additional WBEM credential is required which matches the endpoint being scanned. This is not the host credential used to scan the endpoint.

The following example shows the filter_locally parameter set in order to retrieve all properties:

discovery.wbemEnumInstances(discovery_access, "HITACHI_SCSIPCForPort", 
   [ "Dependent", "Antecedent" ], "root/hitachi/smis", filter_locally := true);
Was this page helpful? Yes No Submitting... Thank you

Comments