Packetshaper templates

Templates, scripts for templates, scripts and requests for templates.

Moderators: Developers, Moderators

melchandra
Cacti User
Posts: 311
Joined: Tue Jun 29, 2004 12:52 pm
Location: Indiana

Post by melchandra »

The graph template should have the "|query_psClassName|" in the title field. Mine is:

Code: Select all

|host_description| - Traffic for Class: |query_psClassDirection|/|query_psClassName|
Last edited by melchandra on Tue Aug 28, 2007 9:43 am, edited 1 time in total.
Dave
rhart211
Posts: 25
Joined: Thu Jun 14, 2007 2:52 pm

Change name

Post by rhart211 »

How do you change the name of this graph? I don't want to change the name of the template, just the graph that is generated.
Thank you
melchandra
Cacti User
Posts: 311
Joined: Tue Jun 29, 2004 12:52 pm
Location: Indiana

Re: Change name

Post by melchandra »

rhart211 wrote:How do you change the name of this graph? I don't want to change the name of the template, just the graph that is generated.
Thank you
I'm not sure what you're after. There are 2 names, the graph template name, and the title / name of the individual graphs.

There is the Graph Template itself: "Packetshaper Class Traffic". This can be changed by going to Graph Templates, and editing the template.

Within the graph template, there is the "Title" field. This is what shows up across the top of a graph when viewing it. It is what I was referring to in my previous post.

Perhaps if you still don't understand you could post a screen shot of what you're trying to change.
Dave
rhart211
Posts: 25
Joined: Thu Jun 14, 2007 2:52 pm

Post by rhart211 »

melchandra wrote: Yeah, I actually changed that around a lot before deciding on the longer title. Feel free to change it in the graph template.

We have a lot of class/subclass definitions on our packetshaper so it made sense to include the longer names as it helps to figure out what traffic really is. Otherwise I ended up with 6 graphs all with the class "SSL", instead of "SSL/HTTP", or "SSL/Default", etc etc. And I also changed the cacti option for maximum title length to 128.
How do you change the maximum length? Where is this located?
Thanks
melchandra
Cacti User
Posts: 311
Joined: Tue Jun 29, 2004 12:52 pm
Location: Indiana

Post by melchandra »

It is a global Cacti setting. Go to "Settings" and then the "Visual" tab. 2nd setting down should be Maximum Title Length.
Dave
rhart211
Posts: 25
Joined: Thu Jun 14, 2007 2:52 pm

Title

Post by rhart211 »

I have done a snmpwalk, and I am still uncertain how to get the title to say the name correctly. I would like it to say: /Direction/Partition/Class such as /Inbound/ResNet/Half-life.
Thanks
melchandra
Cacti User
Posts: 311
Joined: Tue Jun 29, 2004 12:52 pm
Location: Indiana

Post by melchandra »

OK - I just found out what the problem is.

I'm mis-interpreting the oids in my query. The field name |query_psClassDirection| is actually the Packeteer MIB ClassOwningPartName, meaning the owning partition name. So if you use sub-partitions underneath /inbound and /outbound, the "direction" will be that sub-partition. I think you can use the field |query_psClassFullName| to get the full /inbound/resnet/http names.

I'm working on a new version of the query xml file so if you can wait a day or 2 I should have that for download here.
Dave
rhart211
Posts: 25
Joined: Thu Jun 14, 2007 2:52 pm

Post by rhart211 »

I am willing to wait. Let me know what you find.
melchandra
Cacti User
Posts: 311
Joined: Tue Jun 29, 2004 12:52 pm
Location: Indiana

Post by melchandra »

Here are the new files. I discovered a few things.

1. The field formerly knows as "Direction" is actually the field "ClassOwningPartition". It gives the name of the owning partition. At the time I had no partitions, so it gave "Inbound" or "Outbound" for all of my sub-classes, so it seemed like the direction field to me. The real direction field has been added, but only contains the integer values 1 and 2. I can't find any way (other that a custom script) to get Cacti to recognize these values, but render them as inbound or outbound.

2. The filed knows as "Direction" now contains the proper information, either 1 for inbound, or 2 for outbound

3. The field known as "Direction", meaning the owning partition is now avialiable as "psClassOwningPartition"

4. The packetshaper class template has been changed to use |query_psClassFullName| in the title which should take the form "/Inbound/ResNet/Http/Myspace". Or whatever the case may be.

5. After you import the file, you will need to re-run the snmp-query, open the graph template, verify the new title is there, then save it (even if you didn't change anything, this forces Cacti to regenerate the graph titles).

6. Sorry about the delay... work got incredibly busy for me the last week so I was unable to work on this.

7. You have to be running 0.8.6j or newer to import all the files correctly.
Attachments
packetshaper_xml_files.zip
Version 2.0 - supports sub-partitions.
(19.45 KiB) Downloaded 716 times
Last edited by melchandra on Fri Sep 07, 2007 12:52 pm, edited 2 times in total.
Dave
wilperi
Posts: 12
Joined: Mon Sep 03, 2007 6:55 am

Post by wilperi »

Hi

I try to import files but file cacti_graph_template_packetshaper_class_traffic give me an error "Error: XML: Hash version does not exist.".

I can import other files with no problem. What is the problem?

Thanks

-wilperi-
melchandra
Cacti User
Posts: 311
Joined: Tue Jun 29, 2004 12:52 pm
Location: Indiana

Post by melchandra »

what version of cacti / cactid / os / database are you running?

Did you import other files, or just try to import the one file?
Dave
wilperi
Posts: 12
Joined: Mon Sep 03, 2007 6:55 am

Post by wilperi »

Hi

running version is 0.8.6i and operating system is debian. Yes i can import other files from packetshaper_xml_files.zip package without any problems. Only problem file is cacti_graph_template_packetshaper_class_traffic file.

any idea?

-wilperi
melchandra
Cacti User
Posts: 311
Joined: Tue Jun 29, 2004 12:52 pm
Location: Indiana

Post by melchandra »

I made a slight change and re-uploaded the files, download the 2.0 version again and see if that fixes it.
Dave
wilperi
Posts: 12
Joined: Mon Sep 03, 2007 6:55 am

Post by wilperi »

Hi

Still same problem with the file :roll:

-wilperi-
melchandra
Cacti User
Posts: 311
Joined: Tue Jun 29, 2004 12:52 pm
Location: Indiana

Post by melchandra »

ah...

I'm running 0.8.6j. You'll need to upgrade before the file will import. Or figure out how to hack the file so it will. I don't think the file contains any elements that are "j" dependent - but you never know.

http://forums.cacti.net/about7135.html
Dave
Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest