Page 2 of 2

Re: Timeout from the host

Posted: Mon Aug 05, 2019 2:54 am
by Kukkurloom
Hello Benjamin!

Sorry for my late reply, but ran the desired command in terminal libexec folder and got that as a result:

Code: Select all

[root@nagios libexec]# ./check_hpjd [IP] -C public
Printer ok - ("Ready")
But nagios web still shows critical error: snmpget: Failure in sendto (Invalid argument) : Timeout from host

Edit: Just wanted to see for educational purposes what it would it say on the web interface if I change the name of check_hpjd file on libexec folder and change it back afterwards and now it gives me error like this: (No output on stdout) stderr:

Re: Timeout from the host

Posted: Mon Aug 05, 2019 2:01 pm
by benjaminsmith
Hello @Kukkurloom,

If it's working from the command line, it ought to work from Nagios. However, you are running as root from the command line, so please log into the /usr/local/nagios/libexec folder and change from root to nagios. I'd like to confirm if you're getting the same error message.

Code: Select all

su nagios
./check_hpjd [IP] -C public
Also, what are the permissions on the plugin?

Code: Select all

ls -l  /usr/local/nagios/libexec/check_hpjd

Re: Timeout from the host

Posted: Tue Aug 06, 2019 2:35 am
by Kukkurloom
Hey Benjamin!

Thank you for your very fast reply! :)

1: Ran the desired command to check the permissions of the check_hpjd plugin, and it was only "root" so I changed it to Nagios:Nagios. I hope it is right :)

Code: Select all

[root@nagios libexec]# ls -l  /usr/local/nagios/libexec/check_hpjd
-rwxrwxrwx 1 root root 58008 Aug  5 11:29 /usr/local/nagios/libexec/check_hpjd
[root@nagios libexec]# chown nagios:nagios check_hpjd
2: Also tried to run the same command afterwards, but unfortunately, it gave me the same error:

Code: Select all

[nagios@nagios libexec]$ ./check_hpjd [IP] -C public
Segmentation fault
Thank you very much for your help! :)
Kukkurloom.

Re: Timeout from the host

Posted: Tue Aug 06, 2019 12:52 pm
by benjaminsmith
Hello @Kukkurloom,

The default permissions are set to Apache:Nagios, however, since you have the other (everyone) set to read,write, and execute this should not be a problem.

The segmentation fault error is not something that comes up too often. It's possible your printer is not compatible with this plugin.

I would like to see your configuration files in Nagios Core to review the check commands and arguments. Would it be possible for your send over all of the files in the configuration directory for us to review? The configuration files are located in /usr/local/nagios/etc. Thanks.

Re: Timeout from the host

Posted: Mon Aug 12, 2019 3:21 am
by Kukkurloom
Hello Benjamin!

First of all, I would like to thank you very much for your kind help with my issue, but to be honest, to waste more of your time on that plugin problem to check all files etc would not be smart and definitely you have better things to do, I think I will find and try another plugin or just try another solution for these printers and see what will happen. :)

I think you may close this topic for now and once more, thank you for your generous help on the way! :)

Best wishes,
Kukkurloom.

Re: Timeout from the host

Posted: Mon Aug 12, 2019 7:53 am
by scottwilkerson
Kukkurloom wrote:Hello Benjamin!

First of all, I would like to thank you very much for your kind help with my issue, but to be honest, to waste more of your time on that plugin problem to check all files etc would not be smart and definitely you have better things to do, I think I will find and try another plugin or just try another solution for these printers and see what will happen. :)

I think you may close this topic for now and once more, thank you for your generous help on the way! :)

Best wishes,
Kukkurloom.
Locking