EventHandlers and sudo

matt at mattbostock.com matt at mattbostock.com
Mon May 23 17:57:57 CEST 2005


sudo -u root /etc/init.d/postfix restart

;)
Matt

James Joyce wrote:
> HI
> 
> I 'm trying to use eventhandlers following documentation.
> i use sudo to restart a service, sudousers contain that line
> nagios  ALL=(root) NOPASSWD: /etc/init.d/postfix
> 
> but when i try
> sudo -u nagios /etc/init.d/postfix restart
> i get
> ERROR: must be root to run init scripts
> Any idea?
> 
> Thanks.
> 
> 
> -------------------------------------------------------
> This SF.Net email is sponsored by Oracle Space Sweepstakes
> Want to be the first software developer in space?
> Enter now for the Oracle Space Sweepstakes!
> http://ads.osdn.com/?ad_id=7412&alloc_id=16344&op=click
> _______________________________________________
> Nagios-users mailing list
> Nagios-users at lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/nagios-users
> ::: Please include Nagios version, plugin version (-v) and OS when
> reporting any issue. ::: Messages without supporting info will risk
> being sent to /dev/null
> 



-------------------------------------------------------
This SF.Net email is sponsored by Oracle Space Sweepstakes
Want to be the first software developer in space?
Enter now for the Oracle Space Sweepstakes!
http://ads.osdn.com/?ad_id=7412&alloc_id=16344&op=click
_______________________________________________
Nagios-users mailing list
Nagios-users at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue. 
::: Messages without supporting info will risk being sent to /dev/null





More information about the Users mailing list