Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I have two servers, both running 12.04 server, and nagios-nrpe-server.

On both, I have configured the command check_apt, which runs /usr/lib/nagios/plugins/check_apt.

On both, nagios-nrpe-server is configured to run as the nagios user.

Unfortunately, on one of the servers, I always receive an OK signal with 0 updates when, from a different server, I run /usr/lib/nagios/plugins/check_nrpe -H hostname -c check_apt, despite there being updates.

I followed this through and noticed that on one server, check_apt runs as the nagios user and does indeed return with a warning or critical when required.

The other, problematic server, always says 0 updates required when run as the nagios user, but will always give the correct response when run as root.

On this problematic server, I also note that the MOTD always displays the wrong number of packages. It's as if neither commands are allowed to access the number of updates for a server.

share|improve this question
    
What groups are these two Nagios users in? –  jrg Mar 6 '13 at 12:13
    
su to the nagios user and try and run it manually? –  popey Mar 6 '13 at 12:33
    
1) the nagios users are only in 1 group: nagios –  SuperMatt Mar 6 '13 at 13:00
    
2) SUing yeilds the same results. One server works fine, the other does not. –  SuperMatt Mar 6 '13 at 13:00
    
@jrg making sure you got the OP's reply. SuperMatt: Unless you include 'at' (@) and the users name, they usually won't get your comment. –  Seth Mar 8 '13 at 0:23
show 1 more comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.