|
|
| Author |
Message |
kessen
Joined: 06 Nov 2008 Posts: 3
|
Posted: Thu Nov 06, 2008 8:32 am Post subject: Multiple data sources in a graph using a custom templaplate |
|
|
Hi,
I've encountered a strange behavoiur in Cacti which I personally don't understand. I've tried to figure out if someone had the same problem. Since I wasn't able to find a posting to my specific problem please excuse me if there is a howto or solution which I've overlooked.
The scenario:
I've got 2 Switches which have WAN-Lines connected to them. I'm trying to get a consolidated WAN-Traffic graph by summing all the traffic up whilst keeping the inbound traffic apart from the outbound traffic.
here's what I did:
1st: I've made sure the data sources of the four interfaces existed and the graphing is working.
2st: I created a cdef "sumof4" to summerize 4 values: stating
3rd:
I created a Graph template called "4-InterfacesSummiert - Traffic (bytes/sec)" by duplicating the existing "Interface - Traffic (bytes/sec)" template. I then edited my Version of the template by changing all the Template Items vom cdef-type "NONE" to my newly created "sumof4".
Since the "Graph Item Input Section" just consisted of two datasources called:
| Code: |
Inbound Data Source
Outbound Data Source
|
I edited The Section to read:
| Code: | 1st Inbound Data Source
1st Outbound Data Source
2nd Inbound Data Source
2nd Outbound Data Source
3rd Inbound Data Source
3rd Outbound Data Source
4th Inbound Data Source
4th Outbound Data Source |
I've made sure that the Inbound Souces are connected to the Inbound Items. (Same for "outbound").
I saved the template and considered it ready to use.
4th:
I've created a new graph using the previously (3rd step) created template. In the "Supplemental Graph Template Data" Section I see my Graph Item Fields that read "1st Outbound Data Source" etc. ... followed by a dropdown menu containing a list of all my Datasources. I Select the appropriate interfaces and directions (inbound / outbound) and after saving everything the thing goes terribly wrong:
looking at the 8 dropdown menus only the last two are taken into account and copied in the previous positions eg:
my choice is:
| Code: |
1st Inbound Data Source Switch1-Interface1-Inbound
1st Outbound Data Source Switch1-Interface1-Outbound
2nd Inbound Data Source Switch1-Interface2-Inbound
2nd Outbound Data Source Switch1-Interface2-Outbound
3rd Inbound Data Source Switch2-Interface1-Inbound
3rd Outbound Data Source Switch2-Interface1-Outbound
4th Inbound Data Source Switch2-Interface2-Inbound
4th Outbound Data Source Switch2-Interface2-Outbound
|
the following is saved:
| Code: |
1st Inbound Data Source Switch2-Interface2-Inbound
1st Outbound Data Source Switch2-Interface2-Outbound
2nd Inbound Data Source Switch2-Interface2-Inbound
2nd Outbound Data Source Switch2-Interface2-Outbound
3rd Inbound Data Source Switch2-Interface2-Inbound
3rd Outbound Data Source Switch2-Interface2-Outbound
4th Inbound Data Source Switch2-Interface2-Inbound
4th Outbound Data Source Switch2-Interface2-Outbound
|
That's why I think either I've been making massive mistakes or there is a huge bug :-/ ...
I've been using Cacti 0.8.6j but since I consider it to be a bug I've upgraded to 0.8.7b yesterday - the behaviour didn't change.
Perhaps somebody has an idea or can give me a hint
cheers
Andreas
|
|
| Back to top |
|
 |
gandalf Developer
Joined: 02 Dec 2004 Posts: 12642 Location: Muenster, Germany
|
Posted: Sun Nov 09, 2008 11:53 am Post subject: |
|
|
Sorry that I do not answer directly to your errors.
Please use the pseudo CDEF variable TOTAL_ALL_DATA_SOURCES_NODUPS or TOTAL_SIMILAR_DATA_SOURCES_NODUPS.
They were just amde for adding everything in there (either all interfaces or "all of the same kind", e.g. INPUT)
Reinhard
|
|
| Back to top |
|
 |
kessen
Joined: 06 Nov 2008 Posts: 3
|
Posted: Mon Nov 10, 2008 4:01 am Post subject: |
|
|
Hi gandalf,
hallo Reinhard
thanks for answering and sorry I didn't mention it: I've tried to change the CDEF to TOTAL_ALL_DATA_SOURCES_NODUPS prior to my mailing. Just to make sure I've checked again. I've tried to set it up as a "Special Data Source" as well as a "Custom String". The behavior stayed the same.
I still have no clue ...
thanks und Danke
Andreas
|
|
| Back to top |
|
 |
gandalf Developer
Joined: 02 Dec 2004 Posts: 12642 Location: Muenster, Germany
|
Posted: Tue Nov 11, 2008 2:51 pm Post subject: |
|
|
Try attached docs, please
Reinhard
| Description: |
|
 Download |
| Filename: |
CDEF.pdf |
| Filesize: |
99.17 KB |
| Downloaded: |
36 Time(s) |
|
|
| Back to top |
|
 |
kessen
Joined: 06 Nov 2008 Posts: 3
|
Posted: Wed Nov 12, 2008 4:59 am Post subject: |
|
|
Thank your for telling me to read the manual quite a good idea. In fact it is so good I had it myself weeks ago
the question still remains:
Why are my Selections in the "Supplemental Graph Template Data" ignored and six of eight selected data sources are overwritten by the last two data sources ?
To hint me off to read another manual is not very helpful.
This is neither my first cdef nor my first graph with cacti but the first unexpected behavior in Cacti I've encountered.
Is the number of data sources perhaps limited to the number of graphs in the template ? The "new" thing in my graph is that I do not want the single graphs to be displayed but only the sum - therefor I've only one Graph of a cdef , but 4 Datasources. In the example in the FINE manual the multiple graphs are plotted supplemented by an additional graph of "the sum".
|
|
| Back to top |
|
 |
gandalf Developer
Joined: 02 Dec 2004 Posts: 12642 Location: Muenster, Germany
|
Posted: Wed Nov 12, 2008 4:05 pm Post subject: |
|
|
| kessen wrote: | Thank your for telling me to read the manual quite a good idea. In fact it is so good I had it myself weeks ago  | Sorry, but
- this doc is not yet part of cacti manual but wil lbe published with 087c
- your, ähem, post count is not suggesting that this bit is totally clear to you, even if your first post is well phrased
| Quote: | | Is the number of data sources perhaps limited to the number of graphs in the template ? The "new" thing in my graph is that I do not want the single graphs to be displayed but only the sum - therefor I've only one Graph of a cdef , but 4 Datasources. In the example in the FINE manual the multiple graphs are plotted supplemented by an additional graph of "the sum". | There's definitively no known maximum to the number of ds's. The limit that comes close is a command line length limit of 2/4k (OS dependant).
So please post the whole rrdtool graph from graph management in DEBUG mode
Reinhard
|
|
| Back to top |
|
 |
|