Page 1 of 3
Another timeout issue
Posted: Fri Dec 05, 2014 10:26 pm
by trungmv
Hi,
I have same issue as described in
this post, with message "External command error: Timeout: No Response from xxxx".

Here is the step which i did:
1. Change check_snmp on commands.cfg to:
# 'check_snmp' command definition
define command{
command_name check_snmp
command_line $USER1$/check_snmp -P 2c -C kvp -H $HOSTADDRESS$ $ARG1$
}
2. Using check_snmp script to check and result:
[root@SYSEC01 libexec]# ./check_snmp -H 10.126.123.1 -C kvp -o sysUpTime.0 -e 2 -t 30 -vvv
/usr/bin/snmpget -Le -t 30 -r 2 -m ALL -v 1 [authpriv] 10.126.123.1:161 sysUpTime.0
DISMAN-EVENT-MIB::sysUpTimeInstance = Timeticks: (1077835466) 124 days, 17:59:14.66
Processing oid 1 (line 1)
oidname: DISMAN-EVENT-MIB::sysUpTimeInstance
response: Timeticks: (1077835466) 124 days, 17:59:14.66
SNMP OK - Timeticks: (1077835466) 124 days, 17:59:14.66 |
Any suggestion please let me know?
Regards,
Moderator's note: Always start your own threads and point to the "original" post. Thanks!
Re: Another timeout issue
Posted: Mon Dec 08, 2014 11:26 am
by lgroschen
Can you post exactly what your are passing into $ARG1$ in the command definition?
This response usually means a few things:
1) You don't have the proper IP/ host, public string or snmp version. Since you ran from the command line cleanly it doesn't look like this is an issue.
2) You aren't passing the correct arguments or there is an arg missing: such as are you passing an OID with -o in the command?
Re: Another timeout issue
Posted: Mon Dec 08, 2014 10:30 pm
by trungmv
Hi,
It seems be wrong community con switch.cfg, after change community as same as commands.cfg --> uptime is fine now.
But i have still issue with bandwidth usage and link status port as attache file:
Here is my check_mrtgtraf on commands.cfg:
# 'check_local_mrtgtraf' command definition
define command{
command_name check_local_mrtgtraf
command_line $USER1$/check_mrtgtraf -F $ARG1$ -a $ARG2$ -w $ARG3$ -c $ARG4$ -e $ARG5$
}
And on switch.cfg:
# Monitor bandwidth via MRTG logs
define service{
use generic-service ; Inherit values from a template
host_name BB01
service_description Port 1 Bandwidth Usage
check_command check_local_mrtgtraf!/var/www/html/mrtg/10.126.123.1_l.log!AVG!1000000,1000000!5000000,5000000!10
}
I checked with directory /var/www/html/mrtg/ and existed all information of IP: 10.126.123.1
Here is my short mrtg.cfg:
# Created by
# /usr/bin/cfgmaker --global "WorkDir: /var/www/html/mrtg" --output /etc/mrtg/mrtg.cfg [email protected]
### Global Config Options
# for UNIX
# WorkDir: /home/http/mrtg
# or for NT
# WorkDir: c:\mrtgdata
HtmlDir: /var/www/html/mrtg
ImageDir: /var/www/html/mrtg
LogFormat: rrdtool
LogDir: /var/lib/mrtg
ThreshDir: /var/lib/mrtg
WorkDir: /var/www/html/mrtg
### Global Defaults
# to get bits instead of bytes and graphs growing to the right
# Options[_]: growright, bits
EnableIPv6: no
#WorkDir: /var/www/html/mrtg
#logdir: /var/log/mrtg
######################################################################
# System: KVP_BB1
# Description: Cisco IOS Software, Catalyst 4500 L3 Switch Software (cat4500e-IPBASE-M), Version 12.2(50)S$
# Technical Support: http://www.cisco.com/techsupport
P/S: i can used snmpwalk command to get many information from 10.126.123.1 but i don't know which is OID for link status?
Any misconfiguration on config files?
Best regards,
Re: Another timeout issue
Posted: Tue Dec 09, 2014 11:18 am
by lgroschen
can you see if you have multiple crons of mrtg running?
Then show me the content of these?
Code: Select all
ls -l /var/lib/mrtg
ls -l /var/www/html/mrtg
Re: Another timeout issue
Posted: Tue Dec 09, 2014 8:35 pm
by trungmv
Hi,
is showing nothing,
but
is showing:
*/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
Here is
[root@SYSEC01 ~]# ls -l /var/lib/mrtg
total 0
-rw-r--r-- 1 root root 0 Dec 10 08:30 mrtg.ok
And
.......................
-rw-r--r-- 1 apache apache 94768 Dec 10 08:30 10.126.123.1_8.rrd
-rw-r--r-- 1 apache apache 1459 Dec 8 15:15 10.126.123.1_8-week.png
-rw-r--r-- 1 apache apache 1742 Dec 8 15:15 10.126.123.1_8-year.png
-rw-r--r-- 1 apache apache 1540 Dec 8 15:25 10.126.123.1_9-day.png
-rw-r--r-- 1 apache apache 6433 Dec 8 15:25 10.126.123.1_9.html
-rw-r--r-- 1 apache apache 48244 Dec 8 15:25 10.126.123.1_9.log
-rw-r--r-- 1 apache apache 1410 Dec 8 15:15 10.126.123.1_9-month.png
-rw-r--r-- 1 apache apache 48212 Dec 8 15:20 10.126.123.1_9.old
-rw-r--r-- 1 apache apache 94768 Dec 10 08:30 10.126.123.1_9.rrd
-rw-r--r-- 1 apache apache 1459 Dec 8 15:15 10.126.123.1_9-week.png
-rw-r--r-- 1 apache apache 1742 Dec 8 15:15 10.126.123.1_9-year.png
-rw-r--r-- 1 apache apache 14416 Dec 8 15:11 index.html
-rw-r--r-- 1 apache apache 538 Dec 8 15:15 mrtg-l.png
-rw-r--r-- 1 apache apache 414 Dec 8 15:15 mrtg-m.png
-rw-r--r-- 1 apache apache 1759 Dec 8 15:15 mrtg-r.png
[root@SYSEC01 ~]#
Any suggestion, please let me know
Regards,
Re: Another timeout issue
Posted: Wed Dec 10, 2014 11:36 am
by lgroschen
what version of linux is this? Also, run this if you have the yum package manager:
This topic also describes a package that must be installed inline with mrtg:
http://support.nagios.com/forum/viewtop ... 3&start=20
there should be mrtg-kibs-2.16.2-7.el6 installed alongside with mrtg-2.16.2-7.el16
and that is for a CentOS 6.4 system.
On another note, if you have Ubunutu 11.1 here's a fix:
http://www.howtoforge.com/forums/showthread.php?t=55187
Let us know if any of the above helps. Also remember to restart services after trying a fix.
Re: Another timeout issue
Posted: Wed Dec 10, 2014 8:58 pm
by trungmv
Hi,
My Linux version:
Code: Select all
#lsb_release -a
LSB Version: :base-4.0-amd64:base-4.0-noarch:core-4.0-amd64:core-4.0-noarch:graphics-4.0-amd64:graphics-4.0-noarch:printing-4.0-amd64:printing-4.0-noarch
Distributor ID: CentOS
Description: CentOS release 6.6 (Final)
Release: 6.6
Codename: Final
I already has these packet:
Code: Select all
#yum -y install gd libpng zlib
Package gd-2.0.35-11.el6.x86_64 already installed and latest version
Package 2:libpng-1.2.49-1.el6_2.x86_64 already installed and latest version
Package zlib-1.2.3-29.el6.x86_64 already installed and latest version
Mrtg packet also:
Code: Select all
#rpm -qa | grep mrtg
mrtg-libs-2.16.2-7.el6.x86_64
mrtg-2.16.2-7.el6.x86_64
But still issue.
Any other suggestion, please tell me?
Regards,
Re: Another timeout issue
Posted: Thu Dec 11, 2014 11:59 am
by lgroschen
My next suggestion would be to recompile mrtg and start fresh.
As far as I can see the files and configs are all correct, there aren't multiple MRTG crons running, the log files and everything have correct permissions. Anything else you can think of??
Also, have you tried any other troubleshooting guides on MRTG? Because that log file read issue is a pretty common error.
Post back what you would like to do.
Re: Another timeout issue
Posted: Mon Dec 15, 2014 1:10 am
by trungmv
Hi,
I also recompiled nagios-plugin and re-add network device but still problem.
My system: - Centos: 6.6
- Nagios Core 4.0.8
- Nagios plugin: 2.0.3
Any help is appreciated,
Re: Another timeout issue
Posted: Mon Dec 15, 2014 6:06 pm
by Nagios Support
Our developers are looking into this and will follow up with you tomorrow.