remote execution - "no such file or directory"
Posted: Thu Feb 15, 2018 12:57 pm
I am using the identical plugin (reached via ssh) on two systems. On one, it works fine. On the other, the UI is showing error code 127 - no such file or directory.
Here is the one that is failing:
Feb 15 11:38:22 dal10-build-Nagios nagios: SERVICE ALERT: server-XYZ;Check event ingestion;CRITICAL;SOFT;1;(Return code of 127 is out of bounds - plugin may be missing : (No output on stdout) stderr: bash: /opt/devmgmt/libexec/ingestion_check.py: No such file or directory))
Feb 15 11:40:23 dal10-build-Nagios nagios: Warning: Return code of 127 for check of service 'Check event ingestion' on host 'server-XYZ' was out of bounds. Make sure the plugin you're trying to run actually exists.
But it's there, and I can run it manually, remotely:
[root@dal10-build-Nagios libexec]# ssh server-XYZ /opt/devmgmt/libexec/ingestion_check.py
Pipeline successfully processing events
[root@dal10-build-Nagios libexec]#
Permissions are 755 on the file:
[root@dal10-build-Nagios libexec]# ssh server-XYZ "ls -l /opt/devmgmt/libexec/ingestion_check.py"
-rwxr-xr-x 1 root root 1409 Feb 15 12:32 /opt/devmgmt/libexec/ingestion_check.py
[root@dal10-build-Nagios libexec]#
What's going on?
Here is the one that is failing:
Feb 15 11:38:22 dal10-build-Nagios nagios: SERVICE ALERT: server-XYZ;Check event ingestion;CRITICAL;SOFT;1;(Return code of 127 is out of bounds - plugin may be missing : (No output on stdout) stderr: bash: /opt/devmgmt/libexec/ingestion_check.py: No such file or directory))
Feb 15 11:40:23 dal10-build-Nagios nagios: Warning: Return code of 127 for check of service 'Check event ingestion' on host 'server-XYZ' was out of bounds. Make sure the plugin you're trying to run actually exists.
But it's there, and I can run it manually, remotely:
[root@dal10-build-Nagios libexec]# ssh server-XYZ /opt/devmgmt/libexec/ingestion_check.py
Pipeline successfully processing events
[root@dal10-build-Nagios libexec]#
Permissions are 755 on the file:
[root@dal10-build-Nagios libexec]# ssh server-XYZ "ls -l /opt/devmgmt/libexec/ingestion_check.py"
-rwxr-xr-x 1 root root 1409 Feb 15 12:32 /opt/devmgmt/libexec/ingestion_check.py
[root@dal10-build-Nagios libexec]#
What's going on?