Bandwidth Graph Reports No Traffic

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
avandemore
Posts: 1597
Joined: Tue Sep 27, 2016 4:57 pm

Re: Bandwidth Graph Reports No Traffic

Post by avandemore »

Profile received.

Is this a profile from an earlier time? The settings for npcd and perdata logging are the default so I am unclear as to what was changed.
I also confirmed that the RRD file in question is actually there.
Please copy/paste the output of this process.
Previous Nagios employee
sfudali
Posts: 17
Joined: Mon Nov 04, 2013 9:56 pm

Re: Bandwidth Graph Reports No Traffic

Post by sfudali »

I had disabled the additional logging before I had done the profile. I will enable logging and let it run for a bit and re-send the profile download.

As for the RRD file, I went to /usr/local/nagios/share/perfdata/<device in question>/ and looked in the directory and saw the RRD file and the XML file there for the graph I'm trying to do.
User avatar
tgriep
Madmin
Posts: 9190
Joined: Thu Oct 30, 2014 9:02 am

Re: Bandwidth Graph Reports No Traffic

Post by tgriep »

Take a look at this KB article to fix the bandwidth issue you are having.
https://support.nagios.com/kb/article.php?id=511
Be sure to check out our Knowledgebase for helpful articles and solutions!
sfudali
Posts: 17
Joined: Mon Nov 04, 2013 9:56 pm

Re: Bandwidth Graph Reports No Traffic

Post by sfudali »

When I run the command
LANG=C LC_ALL=C /usr/bin/mrtg /etc/mrtg/mrtg.cfg
, I do not get any error output and it reports my current MRTG version as 2.17.4 already.
rkennedy
Posts: 6579
Joined: Mon Oct 05, 2015 11:45 am

Re: Bandwidth Graph Reports No Traffic

Post by rkennedy »

Just to make sure I understand properly -
The only difference between this graph and another functional bandwidth graph is that this one was created manually as opposed to the other which was created when the host was first added via the wizard.
Did you copy this service, and then just change $ARG1$ to be equal to a RRD file? This will not work, because the wizard will create the MRTG configuration file in the back end, which then in turn powers the sourced graph here.

What is the full output of the following? ls -la /var/lib/mrtg/
Former Nagios Employee
sfudali
Posts: 17
Joined: Mon Nov 04, 2013 9:56 pm

Re: Bandwidth Graph Reports No Traffic

Post by sfudali »

I manually added a new service to the existing host. At first it was complaining that there was no RRD file when I attempted to save the configuration, but then it stopped complaining so I thought that whatever process needed to run to create the file. Perhaps that's the root cause of my issue. When I look through ls -la /var/lib/mrtg/, I do not see a corresponding RRD file in that directory for the host/port I'm trying to graph. What is the manual command to great the MRTG configuration file? I can run that and see if the problem resolves itself.
avandemore
Posts: 1597
Joined: Tue Sep 27, 2016 4:57 pm

Re: Bandwidth Graph Reports No Traffic

Post by avandemore »

The quick fix is to edit /etc/cron.d/mrtg. Change:

Code: Select all

*/5 * * * * root LANG=C LC_ALL=C /usr/bin/mrtg /etc/mrtg/mrtg.cfg --lock-file /var/lock/mrtg/mrtg_l --confcache-file /var/lib/mrtg/mrtg.ok
to

Code: Select all

*/5 * * * * root LANG=C LC_ALL=C /usr/bin/mrtg /etc/mrtg/mrtg.cfg --lock-file /var/lib/mrtg/mrtg.lock --confcache-file /var/lib/mrtg/mrtg.ok
The permanent fix will be included in 5.3.2.
Previous Nagios employee
sfudali
Posts: 17
Joined: Mon Nov 04, 2013 9:56 pm

Re: Bandwidth Graph Reports No Traffic

Post by sfudali »

No change in behavior. I do see .rrd files for the host/port in /var/lib/mrtg, however graph still reports 0 traffic.
avandemore
Posts: 1597
Joined: Tue Sep 27, 2016 4:57 pm

Re: Bandwidth Graph Reports No Traffic

Post by avandemore »

What is the output from #LANG=C LC_ALL=C /usr/bin/mrtg /etc/mrtg/mrtg.cfg --lock-file /var/lib/mrtg/mrtg.lock --confcache-file /var/lib/mrtg/mrtg.ok ?

Also try restarting cron: service crond restart
Previous Nagios employee
sfudali
Posts: 17
Joined: Mon Nov 04, 2013 9:56 pm

Re: Bandwidth Graph Reports No Traffic

Post by sfudali »

When I run that I get no output...I'm returned back to my command line. I had rebooted the server after making the change to the file thinking there was related services that would need a reboot.
Locked