check_cups_queue plugin 'not executable by nagios user'

Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
Locked
Lmac
Posts: 5
Joined: Tue Feb 28, 2017 3:02 pm

check_cups_queue plugin 'not executable by nagios user'

Post by Lmac »

I have a CUPS server and I want to use nrpe to check the printer queue and be notified when it stalls. I have NRPE working for other items for this server (just the sample tasks) , but I can't get the check_cups_queue to work. Here are the error message I receive when I execute the plugin on the CUPS server and from the Nagios server (same error).

This is what I tried to run on the CUPS server and here are the results:

./check_cups_queue -H x.x.x.x -T s -w 50 -c 100
lpstat not found or is not executable by the nagios user

the nagios user has been added to the following groups: lpadmin, sudo, lp

I can execute the lpstat command without an error.

Thanks for any suggestions!
tmcdonald
Posts: 9117
Joined: Mon Sep 23, 2013 8:40 am

Re: check_cups_queue plugin 'not executable by nagios user'

Post by tmcdonald »

I'm assuming you got the plugin from here: https://github.com/lusis/old-one-offs/b ... s_queue.sh

If that is the case, the test would fail if your lpstat was not in /usr/bin/ - can you run which lpstat and post the output? That will show us where the binary is located.
Former Nagios employee
Lmac
Posts: 5
Joined: Tue Feb 28, 2017 3:02 pm

Re: check_cups_queue plugin 'not executable by nagios user'

Post by Lmac »

I used the one located here https://exchange.nagios.org/directory/P ... ue/details which looks similar, but doesn't have the .sh extension.

I download the one you linked to and now I no longer have the error! Sorry to waste your time!

Thank you! :D
tmcdonald
Posts: 9117
Joined: Mon Sep 23, 2013 8:40 am

Re: check_cups_queue plugin 'not executable by nagios user'

Post by tmcdonald »

I'll be closing this thread now, but feel free to open another if you need anything in the future!
Former Nagios employee
Locked