check_procs don't see some process

Julien TOUCHE julien.touche at lycos.com
Sat Oct 16 08:56:07 CEST 2004


Jan Scholten a écrit :
> ./check_procs --help
> [..]
>  -a, --argument-array=STRING
>    Only scan for processes with args that contain STRING.

args is not the same than command, maybe i misunderstood it as i check it.

but real problem (in my sense) is on openbsd 3.5:
$ /usr/local/libexec/nagios/check_procs -C sshd
PROCS OK: 3 processes with command name 'sshd'
$ /usr/local/libexec/nagios/check_procs -a sshd
PROCS OK: 3 processes with args 'sshd'
$ ps -axu |grep sshd
root       143  0.0  0.2   288   808 ??  Is    24Sep04    0:03.60
/usr/sbin/sshd
root     28833  0.0  0.5   384  1916 ??  Is     6:19AM    0:00.12 sshd:
touche [priv] (sshd)
touche   20312  0.0  0.3   416  1380 ??  S      6:19AM    0:00.07 sshd:
touche at ttyp0 (sshd)
touche   32454  0.0  0.0    96   180 p6  D+     6:19AM    0:00.00 grep sshd

and on my whitebox linux nothing with -C sshd

$ /opt/nagios/libexec/check_procs -C sshd
PROCS OK: 0 processes with command name 'sshd'
$ /opt/nagios/libexec/check_procs -a sshd
PROCS OK: 6 processes with args 'sshd'
/opt/nagios/libexec/check_procs -a sshd
$ ps axu|grep sshd
root      1789  0.0  0.1  3668 1184 ?        S    Jul28   3:04 
/usr/sbin/sshd
root     14520  0.0  0.1  6884 1500 ?        S    Oct13   0:00 sshd: 
touche [priv]
touche   14532  0.0  0.1  7056 2000 ?        S    Oct13   0:02 sshd: 
touche at pts/1
root     17587  0.0  0.1  6884 1488 ?        S    Oct13   0:00 sshd: 
touche [priv]
touche   17614  0.0  0.1  7056 2004 ?        S    Oct13   0:00 sshd: 
touche at pts/5
touche   32233  0.0  0.0  3704  712 pts/3    S    07:52   0:00 grep sshd
# /bin/ps -weo 'stat uid ppid vsz rss pcpu comm args'|grep sshd
S        0     1  3668 1184  0.0 sshd             /usr/sbin/sshd
S        0  1789  6884 1500  0.0 sshd             sshd: touche [priv]
S      500 14520  7056 2000  0.0 sshd             sshd: touche at pts/1
S        0  1789  6884 1488  0.0 sshd             sshd: touche [priv]
S      500 17587  7056 2004  0.0 sshd             sshd: touche at pts/5
S        0 29186  3700  712  0.0 grep             grep sshd
$ /opt/nagios/libexec/check_procs -a sshd
PROCS OK: 6 processes with args 'sshd'
$ /opt/nagios/libexec/check_procs -C syslogd
PROCS OK: 0 processes with command name 'syslogd'
$ /opt/nagios/libexec/check_procs -a syslogd
PROCS OK: 2 processes with args 'syslogd'
$ ps axu|grep syslogd
root      1715  0.0  0.0  1588  572 ?        S    Jul28  26:57 syslogd -m 0
touche   32351  0.0  0.0  3708  712 pts/3    S    07:53   0:00 grep syslogd

and an extra: grep is count with -a (and not on openbsd)

Regards

		Julien


-------------------------------------------------------
This SF.net email is sponsored by: IT Product Guide on ITManagersJournal
Use IT products in your business? Tell us what you think of them. Give us
Your Opinions, Get Free ThinkGeek Gift Certificates! Click to find out more
http://productguide.itmanagersjournal.com/guidepromo.tmpl
_______________________________________________
Nagios-users mailing list
Nagios-users at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue. 
::: Messages without supporting info will risk being sent to /dev/null





More information about the Users mailing list