Page 2 of 3

Re: check_by_ssh time out issue

Posted: Thu Jul 02, 2015 10:55 am
by bosecorp
nop, noting

Re: check_by_ssh time out issue

Posted: Thu Jul 02, 2015 1:46 pm
by ssax
I know you tried with "su nagios" but just for the sake of testing, can you try it with "su - nagios" and post the full output if it fails?

Code: Select all

su - nagios
/usr/local/nagios/libexec/check_by_ssh -H x.x.x.x -C "/usr/local/nagios/libexec/check_disk /" -v

Re: check_by_ssh time out issue

Posted: Thu Jul 02, 2015 2:01 pm
by bosecorp
it works

[nagios@nagmonus1 ~]$ /usr/local/nagios/libexec/check_by_ssh -H x.x.x.x -C "/usr/local/nagios/libexec/check_disk /" -t 90
DISK OK - free space: / 324 MB (56% inode=90%);| /=251MB;;;0;576

Re: check_by_ssh time out issue

Posted: Thu Jul 02, 2015 2:08 pm
by jolson
bosecorp,

I know that you have mod_gearman installed. Is it possible that this check is being picked up by one of your mod_gearman workers, and therefore the check times out?

Re: check_by_ssh time out issue

Posted: Thu Jul 02, 2015 2:11 pm
by bosecorp
the worker who is doing the check runs where the XI server runs.

Re: check_by_ssh time out issue

Posted: Thu Jul 02, 2015 2:34 pm
by tgriep
Is your gearman workers running as a different user?
Try adding this to your command's $ARG2$ variable in XI and see if it works.

Code: Select all

-l nagios

Re: check_by_ssh time out issue

Posted: Thu Jul 02, 2015 2:41 pm
by bosecorp
it's running as Nagios.

I tried that already and still the same.

Re: check_by_ssh time out issue

Posted: Thu Jul 02, 2015 4:34 pm
by tgriep
Try running the command in a shell using the hostname and not the IP address. Maybe there is a DNS issue.

Re: check_by_ssh time out issue

Posted: Fri Jul 03, 2015 10:54 am
by bosecorp
same issue

Re: check_by_ssh time out issue

Posted: Mon Jul 06, 2015 9:28 am
by tgriep
Did running the command using the hostname and not the IP address work?
Can you run the following and post the results back?

Code: Select all

grep nag /etc/passwd
grep nag /etc/group
ls -alR /home/nagios
gearman_top