Database Reference
In-Depth Information
<Metric NAME="NetConfig" TYPE="RAW" CONFIG="TRUE">
<TableDescriptor TABLE_NAME="MGMT_EMX_HS_NET">
<ColumnDescriptor NAME="net_interface" COLUMN_NAME="net_interface"
TYPE="STRING" IS_KEY="TRUE"/>
<ColumnDescriptor NAME="net_mtu" COLUMN_NAME="net_mtu" TYPE="NUMBER" IS_KEY="FALSE"/>
<ColumnDescriptor NAME="net_flag" COLUMN_NAME="net_flag" TYPE="STRING" IS_KEY="FALSE"/>
</TableDescriptor>
<QueryDescriptor ...>...</QueryDescriptor>
</Metric>
Configuration metrics should have the CONFIG="TRUE" attribute set. Its type must be set to "RAW" , which
means that the values are collected directly into a table in the repository schema. The TABLE_NAME property of
the TableDescriptor from Listing 10-20 must match the NAME of the corresponding TABLE element from the ECM
metadata in Listing 10-19. The attributes NAME and COLUMN_NAME of the ColumnDescriptor element in Listing 10-20
must match the NAME attribute of the column elements in Listing 10-19. I naively assumed that only COLUMN_NAME
needs to match, and it caused me long hours of troubleshooting until I realized that the NAME attribute also must be
set to the same value. The columns marked as part of the unique key in the tables in the ECM metadata must also be
marked as keys in the corresponding configuration metric, as you can see for the net_interface column.
Now that you understand the content of ECM metadata and what's needed in target type metadata, it's time to
complete the picture by adding the required CollectionItem to the default collection metadata, as shown in Listing 10-21.
Listing 10-21. CollectionItem for Configuration Snapshot
<CollectionItem NAME="HostSample3Snap" UPLOAD_ON_FETCH="TRUE" CONFIG="TRUE">
<Schedule OFFSET_TYPE="INCREMENTAL">
<IntervalSchedule INTERVAL="24" TIME_UNIT="Hr"/>
</Schedule>
<MetricColl NAME="HostConfig" />
...
<MetricColl NAME="NetConfig" />
</CollectionItem>
The NAME of the CollectionItem in Listing 10-21 must match the SNAP_TYPE attribute of the METADATA element
from Listing 10-19. The CollectionItem attribute also must be marked as a configuration collection with the
CONFIG="TRUE" attribute. Setting the OFFSET_TYPE attribute to incremental is not critical, as it just means that the
interval is counted from the end of the last collection rather than between collection start times. For quickly executing
collections, that makes no difference. A collection item must include all configuration metrics defined in Listing 10-20,
each matching to a table defined in Listing 10-19.
Assuming that the ECM metadata is at the correct location in the staging area, it will be automatically included
in the plug-in archive during packaging. Note that if you are tweaking ECM metadata without changing other
components, you can normally upload only the ECM metadata by using MRS just as you can for reports. MRS is,
again, described at the end of the chapter.
You can find the complete documentation on ECM in Chapter 6 of the Extensibility Programmer's Reference .
There you can see, for example, how to define indexes on ECM table columns and how to create dependencies
between configuration items. Note that unless you are translating ECM captions into other languages, you can
ignore the instructions for generating a .dlf file that's placed in <STAGE>/oms/rsc/ecm . (The documentation
refers to nonexisting generate_ecm_resources utilities, but the .dlf file itself can be generated by using
empdk generate_metadata_resource -service LiveSnapshotRegistration .)
If ECM is defined correctly and configurtion metrics collected, you can navigate via the target's menu to
Configuration Last Collected and see the latest configuration collected, as shown in Figure 10-12 . If you need to
troubleshoot the configuration information collection, the agent's Metric Browser covered earlier in this chapter is a huge
help. Chapter 6 of the Extensibility Programmer's Reference contains useful troubleshooting recommendations as well.
 
Search WWH ::




Custom Search