Page 1 of 2

/var/lib/mrtg/xx.xxx.xxx.xxx_xx.rrd does not exist.

Posted: Mon Jul 19, 2021 8:20 am
by vignesha
There was a requirement to add particular port interface to the monitoring.
Interface GigabitEtherne1/0/19 Status
Interface GigabitEthernet1/0/19 Bandwidth
In core configuration wizard I was able to see the particular interface with the port and after configuration successful, the Interface GigabitEthernet1/0/19 Bandwidth is having the status as unknown and saying that /var/lib/mrtg/xx.xxx.xxx.xxx_xx.rrd does not exist.
Please help me in configuring this and do the needful.

Re: /var/lib/mrtg/xx.xxx.xxx.xxx_xx.rrd does not exist.

Posted: Mon Jul 19, 2021 2:36 pm
by benjaminsmith
Hi,

It looks likes a permissions issue on the server, please run the following commands and post the full output.

Code: Select all

ls -l /var/lib/mrtg
LANG=C LC_ALL=C /usr/bin/mrtg /etc/mrtg/mrtg.cfg
Also, to assist with additional troubleshooting, please send over a current system profile and we'll check the logs. Thanks! Ben

To send us your system profile.
Login to the Nagios XI GUI using a web browser.
Click the "Admin" > "System Profile" Menu
Click the "Download Profile" button

Re: /var/lib/mrtg/xx.xxx.xxx.xxx_xx.rrd does not exist.

Posted: Tue Jul 20, 2021 3:37 am
by vignesha
Will keep you Posted.

Re: /var/lib/mrtg/xx.xxx.xxx.xxx_xx.rrd does not exist.

Posted: Tue Jul 20, 2021 7:48 am
by vignesha
Hi Benjamin

I have ran below commands and took logs for the same.
Attaching this in the post.

Re: /var/lib/mrtg/xx.xxx.xxx.xxx_xx.rrd does not exist.

Posted: Tue Jul 20, 2021 4:07 pm
by benjaminsmith
Hi Vignesha,

The permissions on those files are not the same as my test system. Please run the following commands as root to correct this, and then test again.

Code: Select all

chown apache:nagios -R /var/lib/mrtg
chmod ug+rwx -R /var/lib/mrtg

If you continue to have trouble please send the system profile. Thanks, Benjamin

Re: /var/lib/mrtg/xx.xxx.xxx.xxx_xx.rrd does not exist.

Posted: Wed Jul 21, 2021 7:07 am
by vignesha
Hi Benjamin,
I have run those commands given by you with no errors.
But when rescanned again those interfaces, still the same error exists i.e. rrd file is missing.

I am attaching the system profile here.
Please look into this and help me in resolving this issue.

Re: /var/lib/mrtg/xx.xxx.xxx.xxx_xx.rrd does not exist.

Posted: Wed Jul 21, 2021 4:51 pm
by tgriep
There is an application called MRTG that gathers the bandwidth data that XI uses for the checks, if that application has an error, it will cause the issue you are having so I will need some information from the server.

Can you run the following commands as root and post the the /tmp/mrtg.txt file to the ticket?

Code: Select all

LANG=C LC_ALL=C /usr/bin/mrtg /etc/mrtg/mrtg.cfg -debug=cfg,base,log &> /tmp/mrtg.txt
LANG=C LC_ALL=C /usr/bin/mrtg &>> /tmp/mrtg.txt
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 &>> /tmp/mrtg.txt
{ time LANG=C LC_ALL=C /usr/bin/mrtg /etc/mrtg/mrtg.cfg 2>1 ; } 2>> /tmp/mrtg.txt
Post or PM me the /tmp/mrtg.txt file so I can check it for errors.

Re: /var/lib/mrtg/xx.xxx.xxx.xxx_xx.rrd does not exist.

Posted: Thu Jul 22, 2021 5:19 am
by vignesha
Hi tgriep,

I have ran the below commands with no errors:
LANG=C LC_ALL=C /usr/bin/mrtg /etc/mrtg/mrtg.cfg -debug=cfg,base,log &> /tmp/mrtg.txt
LANG=C LC_ALL=C /usr/bin/mrtg &>> /tmp/mrtg.txt
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 &>> /tmp/mrtg.txt
{ time LANG=C LC_ALL=C /usr/bin/mrtg /etc/mrtg/mrtg.cfg 2>1 ; } 2>> /tmp/mrtg.txt


Post that I have checked and copied the content of mrtg.txt file.
I am attaching that here in this post.
Please have a look.
Thanks

Re: /var/lib/mrtg/xx.xxx.xxx.xxx_xx.rrd does not exist.

Posted: Thu Jul 22, 2021 4:09 pm
by tgriep
The mrtg.txt file was cut off so I cannot see what the error was.

Can you run this command again in a root ssh session and post the output to the ticket?

Code: Select all

LANG=C LC_ALL=C /usr/bin/mrtg /etc/mrtg/mrtg.cfg -debug=cfg,base,log
Also, the file name that is missing, can you post the full name of it so I can check it's configuration file?

Thank You.

Re: /var/lib/mrtg/xx.xxx.xxx.xxx_xx.rrd does not exist.

Posted: Mon Jul 26, 2021 1:04 am
by vignesha
Hi

If irun this below command its taking lot of time and seems to be never ending
LANG=C LC_ALL=C /usr/bin/mrtg /etc/mrtg/mrtg.cfg -debug=cfg,base,log

The file missing here is 10.168.168.166_26.rrd
I have run command to get rrd file information only related to 10.168.168.166 and have attached in this post.
Please help me in resolving this problem on urgent basis.