I am trying to use the nagios check_by_ssh plugin which downloaded the nagios-plugins-2.4.2.tar.gz tar file, unzipped and installed, created an RSA security key pair on the monitoring server and shared it to the server at monitor Prove the connection to these correctly, run the following command by terminal to test the execution of the check_by_ssh plugin /usr/lib64/nagios/plugins/check_by_ssh -H "monitored-server-ip" -C ls -E.
When executing it I have a correct response listing directories I try to create a check command in the path Configuration > Commands > Checks with the following instruction:
$USER1$/check_by_ssh -H $HOSTADDRESS$ -C $ARG1$ -E but the result that brings me a 255 status
Status information
UNKNOWN - check_by_ssh: Remote command 'ls' returned status 255
I don't know what could be wrong