check_by_ssh failing
Posted: Tue May 13, 2014 4:47 pm
I'm attempting to do a check_by_ssh check on an AS400 system.
Running the command from the command line (as nagios user) works:
[nagios@nagios ~]$ /usr/local/nagios/libexec/check_by_ssh -l NAGIOS -H XXX.XXX.XXX.XXX -C "/home/NAGIOS/check_as400_cpu.pl -w 50 -c 90"
CPU OK: CPU usage at 2.7%.
However, putting the command into Nagios does not work, returning "Remote command execution failed: Permission denied, please try again."
Nagios commands are running as nagios user. I've double-checked the permissions on the target system, and the ssh key in the authorized_keys file. Everything seems to be OK there.
Suggestions?
Running the command from the command line (as nagios user) works:
[nagios@nagios ~]$ /usr/local/nagios/libexec/check_by_ssh -l NAGIOS -H XXX.XXX.XXX.XXX -C "/home/NAGIOS/check_as400_cpu.pl -w 50 -c 90"
CPU OK: CPU usage at 2.7%.
However, putting the command into Nagios does not work, returning "Remote command execution failed: Permission denied, please try again."
Nagios commands are running as nagios user. I've double-checked the permissions on the target system, and the ssh key in the authorized_keys file. Everything seems to be OK there.
Suggestions?