Offset for index numbers in XML?

Anything that you think should be in Cacti.

Moderators: Developers, Moderators

Post Reply
kneppis
Posts: 2
Joined: Mon Feb 20, 2006 10:49 am

Offset for index numbers in XML?

Post by kneppis »

I wonder if it is possible to add a tag in the XML syntax, in the future, to make an offset for the index number to pull output data for the SNMP queries? Before the problem, I would like to state that I'm not very good at making scripts.

The problem lays in graphing ie traffic data for a CMTS (cable modem termination system). It has DownStream and UpStream interfaces, and the DS-if only have output data and US-if have only input data. All interfaces have different ifNumbers and I want to combine DS with corresponding US in one graph. Like this:

Image

For now I have created data and graph templates for each CMTS in the uBR chassi (containing 8 CMTS and some other intefaces) and it works good for a full chassi. But this static method fails when the chassi isn't full, then the ifIndexes shifts depending how many line cards are put in.

Therefor I would like to query for interfaces, and then maybe select the DS if for graphing and to get output data and then in XML by offset I could retrieve the input data. This would greatly help saving much time in coding.

The coresponding US interfaces are shifted
US0ifIndex = DSifIndex - 4
US1ifIndex = DSifIndex - 3
US2ifIndex = DSifIndex - 2
US3ifIndex = DSifIndex - 1

Image

Edit:
Adding this example of SNR of two US if associated with the CMTS.

Image
Post Reply

Who is online

Users browsing this forum: No registered users and 6 guests