Page 2 of 2

Re: Nagios switch-check_mrtgtraf: Unable to open MRTG log fi

Posted: Fri May 08, 2015 2:05 am
by lsazzad
Thanks a lot! You are life saver. Its working!
Capture.JPG
1. I am no clear about you following solution:
Please post your service configuration under Configure > Core Config Manager > Services and find the port 24 service and screenshot it.
Please note, i am using Nagios Core 4.0.8 Version. I cant find the Configure > Core Config Manager > Services path in GUI! I think its for Nagios XI.

2. Still having problem with MRTG graph GUI. Whenever i run cfgmaker for new switch it published the latest switch graph under my MRTG path:

Code: Select all

http://nagiosserver/mrtg
But in Nagios portal usage is being shown. I think its working from Background end.

Re: Nagios switch-check_mrtgtraf: Unable to open MRTG log fi

Posted: Fri May 08, 2015 3:21 am
by lsazzad
A small update!

When i am trying to write
Its showing the graph. I think i can see all most all the switches graph. For me, its ok. Thanks in advance!

Would you help me to solve SNMP CRITICAL issue?

Re: Nagios switch-check_mrtgtraf: Unable to open MRTG log fi

Posted: Fri May 08, 2015 10:36 am
by tgriep
Could you post how you have configured your Port 24 Uplink settings?
What we need it to see how the check command is setup for this port.

Re: Nagios switch-check_mrtgtraf: Unable to open MRTG log fi

Posted: Fri May 08, 2015 2:47 pm
by lsazzad
In switch.cfg the config for SNMP is:

Code: Select all

define service{
	use					generic-service	; Inherit values from a template
	host_name			RR-DE-IP-Phone-SW-2		; The name we're giving to this switch
	service_description	        Port 24 Uplink-SFP Link Status
	check_command		check_snmp!-C public -o ifOperStatus.1 -r 24 -m RFC1213-MIB
	}
Execpt this i didn't modify anywhere.. Requested to let me know, if you need any information.

Re: Nagios switch-check_mrtgtraf: Unable to open MRTG log fi

Posted: Sun May 10, 2015 6:27 pm
by Box293
Can you please execute this command:

Code: Select all

/usr/local/nagios/libexec/check_snmp -H xxx -C public -o ifOperStatus.1 -r 24 -m RFC1213-MIB
Where xxx is the IP address of the switch.

Please show us the output.

Re: Nagios switch-check_mrtgtraf: Unable to open MRTG log fi

Posted: Mon May 11, 2015 2:07 am
by lsazzad
Thanks for your query!

Code: Select all

root@RR-DE-NMS-2:~# /usr/local/nagios/libexec/check_snmp -H 172.19.254.61 -C public -o ifOperStatus.1 -r 24 -m RFC1213-MIB
SNMP CRITICAL - *up(1)* | 

Re: Nagios switch-check_mrtgtraf: Unable to open MRTG log fi

Posted: Mon May 11, 2015 6:28 am
by lsazzad
ssax wrote:It looks like you don't have the check_snmp plugin installed, see if /usr/local/nagios/libexec/check_snmp exists.

If you don't, you need to install the net-snmp packages and recompile your plugins:

Code: Select all

yum install net-snmp net-snmp-utils
cd /tmp
wget http://nagios-plugins.org/download/nagios-plugins-2.0.3.tar.gz
tar zxf nagios-plugins-2.0.3.tar.gz
cd nagios-plugins-2.0.3
./configure --with-nagios-user=nagios --with-nagios-group=nagios
make
make install
For MRTG graphs reference: http://nagios.sourceforge.net/docs/nagi ... raphs.html

A simple guide: http://bigunix.blogspot.com/2009/07/how ... g-and.html

I just installed net-snmp to my redundant nagios server. But facing same problem like previous. I have tried to re-install & recompiling net-snmp & all plugins. But no change :(
1.JPG
2.JPG
Please have kind look over above image!

Re: Nagios switch-check_mrtgtraf: Unable to open MRTG log fi

Posted: Mon May 11, 2015 10:55 am
by tgriep
To fix the critical message for your link status command, you need to change the command.
Change this from

Code: Select all

check_command      check_snmp!-C public -o ifOperStatus.1 -r 24 -m RFC1213-MIB
to

Code: Select all

check_command      check_snmp!-C public -o ifOperStatus.1 -m RFC1213-MIB
Save it out and restart Nagios and the Critical message will be fixed.

The MIB search path error, the default location "/usr/share/snmp/mibs/" could be missing the MIB files that are needed to run the check.
Can you verify that the RFC1213-MIB file is in that folder?

Re: Nagios switch-check_mrtgtraf: Unable to open MRTG log fi

Posted: Tue May 12, 2015 2:46 am
by lsazzad
1. Thanks! Its working :D :D CRITICAL issue is fixed.

2. For MIB search path error i have recompile all the plugin again & its seems ok now.

Admin is requested to close the thread!