[Nagiosplug-devel] 1.4.0alpha3 on HP-UX: check_dhcp & check_icmp

Andreas Ericsson ae at op5.se
Sat Dec 18 12:51:00 CET 2004


C. Bensend wrote:
> Hey folks,
> 
>    Stanley sent me a modified check_dhcp.c last night, and it built
> successfully on 11.00.  It failed on 10.20, I think Stanley is going
> to take a look at this when he returns from the weekend.
> 
>    check_icmp isn't building on either...  Andreas, do you have a little
> time to look at this?
> 

The seteuid(2) call doesn't seem to be available on HP-UX. I should move 
to using setuid(2) instead, since it will set the euid as well (at least 
on GNU, BSD and System V systems).

You can make it build yourself by changing the line reading seteuid(uid) 
to setuid(uid). You can also remove the conditional geteuid code, since 
socket(2) will fail with EPERM if root access is needed (the plugin will 
then print "can't create raw socket".

Cheers.

> 11.00:
> 
> http://www.bennyvision.com/projects/nagios/debug/plugins-12-18-2004-B.11.00
> 
> 10.20:
> 
> http://www.bennyvision.com/projects/nagios/debug/plugins-12-18-2004-B.10.20
> 
> Thanks!
> 
> Benny
> 
> 

-- 
Andreas Ericsson                   andreas.ericsson at op5.se
OP5 AB                             www.op5.se
Lead Developer




More information about the Devel mailing list