Newly added services - 0 bandwidth issue

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
jacek
Posts: 255
Joined: Wed Sep 09, 2015 5:49 am

Newly added services - 0 bandwidth issue

Post by jacek »

Hi,

I noticed, that newly added services to Nagios XI result in flat graphs.
I went trough the whole article: https://support.nagios.com/kb/article.p ... ategory=44

I have no issues within MRTG, all files are being created, rrd files are there, but if I run the check I get only nulls:

Code: Select all

/usr/local/nagios/libexec/check_rrdtraf -f '/var/lib/mrtg/172.16.10.150_3.rrd' -w 1 -c 2
OK - Current BW in: 0bps Out: 0bps|in=0b/s;1;2 out=0b/s;1;2
I ran out of ideas, the only hint is, that this is only happening for newly added things, all "old" graphs are just fine and returning valid data.
Any ideas? Corrupted wizard? (I'm using the network switch/router 2.4.0 and I believe that the previous version had the same issue).

Thanks!
ssax
Dreams In Code
Posts: 7682
Joined: Wed Feb 11, 2015 12:54 pm

Re: Newly added services - 0 bandwidth issue

Post by ssax »

What was the full output of this command?

Code: Select all

time LANG=C LC_ALL=C /usr/bin/mrtg /etc/mrtg/mrtg.cfg
What about this command?

Code: Select all

rrdtool lastupdate /var/lib/mrtg/172.16.10.150_3.rrd
Additionally, please PM me a copy of your profile, you can download it from Admin > System Profile > Download Profile so that I can look through your logs/configuration as well.

Thank you
jacek
Posts: 255
Joined: Wed Sep 09, 2015 5:49 am

Re: Newly added services - 0 bandwidth issue

Post by jacek »

Way below 5 minutes ;-)

Code: Select all

time LANG=C LC_ALL=C /usr/bin/mrtg /etc/mrtg/mrtg.cfg

real    0m44.152s
user    0m4.570s
sys     0m0.257s
This one suddenly started working maybe due to me deleting some files (only for that IP):

Code: Select all

rrdtool lastupdate /var/lib/mrtg/172.16.23.251_2.rrd
 ds0 ds1

1542826205: 3393720657 11220519847
This one is working all the time.

Code: Select all

rrdtool lastupdate /var/lib/mrtg/172.16.10.100_11148.rrd
 ds0 ds1

1542826224: 860387268972 402285654279
This one has been added to nagios as a test device and looking at the time it has been added to nagios AFTER the first example suddenly started working...

Code: Select all

rrdtool lastupdate /var/lib/mrtg/172.16.10.150_1.rrd
 ds0 ds1

1542825890: 601806655 4178154798
PMed you the profile as well, thanks!
ssax
Dreams In Code
Posts: 7682
Joined: Wed Feb 11, 2015 12:54 pm

Re: Newly added services - 0 bandwidth issue

Post by ssax »

What about this one?

Code: Select all

rrdtool lastupdate /var/lib/mrtg/172.16.10.150_3.rrd
Is that one still having issues? Please PM me that file if it's still having issues.

Let's work on the ones that are having issues.
jacek
Posts: 255
Joined: Wed Sep 09, 2015 5:49 am

Re: Newly added services - 0 bandwidth issue

Post by jacek »

PM sent.

The one attached should show some traffic.
I noticed that it has other permissions than the other files, but the one I had issues before and are gone have the same permissions.
I corrected them to reflect all other files settings:

Before:

Code: Select all

-rw-r--r--   1 apache apache 105312 Nov 21 18:45 172.16.10.150_1.rrd
-rw-r--r--   1 apache apache 105312 Nov 21 18:45 172.16.10.150_2.rrd
-rw-r--r--   1 apache apache 105312 Nov 21 18:45 172.16.10.150_3.rrd
After:

Code: Select all

-rwxrwxr-x 1 apache apache 105312 Nov 21 18:45 172.16.10.150_1.rrd
-rwxrwxr-x 1 apache apache 105312 Nov 21 18:45 172.16.10.150_2.rrd
-rwxrwxr-x 1 apache apache 105312 Nov 21 18:45 172.16.10.150_3.rrd
jacek
Posts: 255
Joined: Wed Sep 09, 2015 5:49 am

Re: Newly added services - 0 bandwidth issue

Post by jacek »

Any ideas? Nothing changed for me, newly added services are still resulting in a 0 bandwidth...
ssax
Dreams In Code
Posts: 7682
Joined: Wed Feb 11, 2015 12:54 pm

Re: Newly added services - 0 bandwidth issue

Post by ssax »

Did this start happening after an upgrade? What version of XI are you running?
jacek
Posts: 255
Joined: Wed Sep 09, 2015 5:49 am

Re: Newly added services - 0 bandwidth issue

Post by jacek »

I upgraded to 5.5.7 on 2018-11-17, so its only a week ago, sounds possible?
ssax
Dreams In Code
Posts: 7682
Joined: Wed Feb 11, 2015 12:54 pm

Re: Newly added services - 0 bandwidth issue

Post by ssax »

It may be related. What is the output of this command?

Code: Select all

cat /etc/cron.d/mrtg
If you see the --user=nagios and --group=nagios options on the end of the output like this:

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 --user=nagios --group=nagios
Edit the /etc/cron.d/mrtg file and change it 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
After the change, wait 15 minutes to make sure it polls enough data, then see if the issue is resolved.

Let us know the results.

Thank you
jacek
Posts: 255
Joined: Wed Sep 09, 2015 5:49 am

Re: Newly added services - 0 bandwidth issue

Post by jacek »

ssax, this worked like a charm!

Is this an update related bug?
Locked