Changing KiloBytes to MegaBytes in NetApp Filer Template

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

Moderators: Developers, Moderators

Post Reply
isaac737
Posts: 23
Joined: Wed Oct 25, 2006 12:37 pm

Changing KiloBytes to MegaBytes in NetApp Filer Template

Post by isaac737 »

Hi all,

Need some help in getting a rather kick ass NetApp Template I found to output MB instead of KB in the legend portion of the graph. Please see attached screenshot for an illustration of what I am talking about.

The template I am using is this one:

http://www.elifulkerson.com/projects/ne ... mplate.php

Cacti Version is: 0.8.7g

I have tried using a CDEF in the data source attached to the graph template but to no avail. The graph image will change but not the numbers outputted beneath the graph. There is also an option in the data source to change from "Exact Numbers" to "Gigabytes" but that doesn't have any affect either.

What is the best course of action here?

Thanks much,
jg

:D
Attachments
NA Filer showing two volumes. Y axis is outputting MB.  Would like the portion below the graph to output MB as well.
NA Filer showing two volumes. Y axis is outputting MB. Would like the portion below the graph to output MB as well.
NA-Filer-KB.JPG (106.48 KiB) Viewed 6097 times
ambermehra
Posts: 2
Joined: Wed Apr 13, 2011 11:25 am

Re: Changing KiloBytes to MegaBytes in NetApp Filer Template

Post by ambermehra »

Hi,

Use cdef (graph management > cdef>add) cdef=CURRENT_DATA_SOURCE,1048576,/

Once you created cdef then use this cdef on specific graph templates (Console -> Graph Templates -> (Edit) -> Graph Template Items ) cdef function.

Thanks
Amber
DukeSniper
Posts: 1
Joined: Mon Sep 12, 2011 4:26 am

Re: Changing KiloBytes to MegaBytes in NetApp Filer Template

Post by DukeSniper »

Volume Space Usage, Auto-Scaling
Volume Space Usage, Auto-Scaling
Clipboard02.jpg (101.48 KiB) Viewed 5706 times
If you like the graphs to auto-convert K/M/G/T, there's an easy way using cacti's built in CDEFs.

Go to [Graph Templates]->[Netapp - Volume - kByte Usage] and change [Base Value] to 1024

After that, change each GPRINT item (#2, 3, 4, 6, 7, 8, 10, 11, and 12) as shown below:

[CDEF Function]: Multiply by 1024
[GPRINT Type]: Normal
Graph Template settings
Graph Template settings
Clipboard01.jpg (152.19 KiB) Viewed 5706 times
I'm currently working on extending Eli's Templates to my needs. I will post back here if I have something that's worth being released :)
VinxItak
Posts: 8
Joined: Wed May 29, 2013 7:09 am

Re: Changing KiloBytes to MegaBytes in NetApp Filer Template

Post by VinxItak »

Hello,

The conversion works, but I've still a problem with Y axis : when i want a "G", it's a "M", and when I want a "T", it's a "G"
Another point, the volume name is troncated, any solution to retrieve the full name ?



[edit : ok i have found for troncated name]
Attachments
2015-01-08 15_11_25-Cacti - Realtime.png
2015-01-08 15_11_25-Cacti - Realtime.png (19.38 KiB) Viewed 3988 times
2015-01-08 15_12_23-Cacti - Realtime.png
2015-01-08 15_12_23-Cacti - Realtime.png (17.68 KiB) Viewed 3988 times
Post Reply

Who is online

Users browsing this forum: No registered users and 0 guests