Table of Contents |
---|
Info | ||
---|---|---|
| ||
This relates to opCharts version 3 |
Introduction
New opCharts TopN tables can be created by following a few steps. Each TopN table is really just a component in a dashboard, by default opCharts ships it's components in omk/lib/json/opCharts/components.d/. User defined components are also loaded from omk/conf/components.d, and are loaded last so that default components can be overridden if desired.
...
In order to make a new TopN table steps 2 and 3 need to process new data for the new TopN table.
Add a new opcharts_topn_properties entry
The nmis_topn_export.pl script runs through each node and attempts to find a value for each entry in the opcharts_topn_properties config array, adding a new entry will generate new data.
...
To debug, run the nmis_topn_export.pl script with force=1 (and possibly debug=1) and look for a new file in the <omk_topn> directory with new data
Add a new component file
The easiest way to get started is to copy an existing topn component file from omk/lib/json/opCharts/components.d/topn_* into omk/conf/components.d (and rename the file).
...
The new TopN table should now appear in opCharts TopN page and also as an option when adding a component to a dashboard under the opCharts data source.
Last Step
After the previous steps have been completed, make sure the nmis_topn_export.pl script has run, then check the TopN page for the new data. If there is none, verify the data is being created by checking <omkd_topn> directory for the new json file. Verify the file has contents, if it does not run the nmis_topn_export.pl in debug and search the output for the new entry field/data.