Bandwidth utilisation labels, integers only?

Support questions about the Network Weather Map plugin

Moderators: Developers, Moderators

Post Reply
krislee
Posts: 6
Joined: Tue Mar 14, 2017 6:49 am

Bandwidth utilisation labels, integers only?

Post by krislee »

Good afternoon,

Is it possible to have the labels on links showing as an integer rather than with the two decimal places? [See the attached file] for example, 58% (or 59% depending on rounding) rather than 58.53%. This would make my diagrams a bit neater.

I've looked through the manual but didn't spot anything.

Regards,

Kris.
Console -_ Weathermap-Primary-WAN.png
Console -_ Weathermap-Primary-WAN.png (11.42 KiB) Viewed 1151 times
User avatar
Howie
Cacti Guru User
Posts: 5508
Joined: Thu Sep 16, 2004 5:53 am
Location: United Kingdom
Contact:

Re: Bandwidth utilisation labels, integers only?

Post by Howie »

This should do it... (at the top of your map config file).

The %d means integer. The rest is to get the right value for the percentage.

Code: Select all

LINK DEFAULT
   INBWFORMAT {link:this:inpercent:%d}%
   OUTBWFORMAT {link:this:outpercent:%d}%
Weathermap 0.98a is out! & QuickTree 1.0. Superlinks is over there now (and built-in to Cacti 1.x).
Some Other Cacti tweaks, including strip-graphs, icons and snmp/netflow stuff.
(Let me know if you have UK DevOps or Network Ops opportunities, too!)
krislee
Posts: 6
Joined: Tue Mar 14, 2017 6:49 am

Re: Bandwidth utilisation labels, integers only?

Post by krislee »

Thanks Howie, that's great.
Post Reply

Who is online

Users browsing this forum: No registered users and 4 guests