Nagios Graph converting figures to binary bytes rather than decimal
Claudio Kuenzler
ck at claudiokuenzler.com
Sat Dec 15 16:58:44 CET 2012
Hi James,
> Looking at the GB value and converting to bytes and then back to GB using
> decimal bytes gives these figures.
>
> Is there any way to make nagiosgraph using binary bytes rather than
> decimal. I am not that familiar with nagiosgraph or RRD and cannot work
> out how to make the change.
>
You will have to manually add an entry into the 'map' file to tell
nagiosgraph to use different values.
My system (df -h) shows:
Filesystem Size Used Avail Use% Mounted on
/dev/mapper/vg0-root 20G 5.4G 14G 29% /
Nagiosgraph shows:
total: 20.32G
used: 5.45G
You can use the following map entry:
# Service Type: check_disk
# Nagiosgraph regex by Claudio Kuenzler
# Check: /usr/lib/nagios/plugins/check_disk -w 20% -c 10% -p /
# Output: DISK OK - free space: / 235120 MB (66% inode=95%):
# Perfdata: /=119211MB;298635;335964;0;373294
/perfdata:(.*)=(\d+)MB;(\d+);(\d+);(\d+);(\d+).*/
#/perfdata:(\W)=(\d+)MB;(\d+);(\d+);(\d+);(\d+).*/ # only / partition
and push @s, [diskusage,
['used', GAUGE, $2*1000**2 ],
['total', GAUGE, $6*1000**2 ] ];
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://www.monitoring-lists.org/archive/users/attachments/20121215/b80a2fbe/attachment.html>
-------------- next part --------------
------------------------------------------------------------------------------
LogMeIn Rescue: Anywhere, Anytime Remote support for IT. Free Trial
Remotely access PCs and mobile devices and provide instant support
Improve your efficiency, and focus on delivering more value-add services
Discover what IT Professionals Know. Rescue delivers
http://p.sf.net/sfu/logmein_12329d2d
-------------- next part --------------
_______________________________________________
Nagios-users mailing list
Nagios-users at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue.
::: Messages without supporting info will risk being sent to /dev/null
More information about the Users
mailing list