Whups. Edit got cut off --
You'll need to change the LOCAL value to the host name or IP address of the allowed hosts. But otherwise, that should do it.
Main Topics
Browse All TopicsHi
I require my user 'www' to run the command '/sbin/service crond restart' without having to use the root password.
How do I write this in /etc/sudoers?
Thank you
tr5
This Question has been solved and asker verified All Experts Exchange premium technology solutions are available to subscription members.
Experts Exchange has been collecting answers to technology questions since 1996…3 million and counting! If you have a question, chances are we already have your answer.
If you can't find the exact answer you're looking for, ask our exclusive community of 50,000 experts. You’ll get a personalized answer from a trusted professional.
Thousands of free tech tips, tricks, how-to’s and tutorials are available in our peer reviewed articles section. See for yourself how smart our experts are, no login required.
Access the answers to your technology questions today.
30-day free trial. Register in 60 seconds.
Members of the expert community talk about why the experience at Experts Exchange is different than what you will find anywhere else.

Try it out and discover for yourself.
30-day free trial. Register in 60 seconds.
Join the community of experts here and help other tech pros by answering question in your area of expertise. You can earn FREE access to all Experts Exchange's premium features and resources.
Sudo must be setuid root to do its work. You need to do something like
`chmod 4111 /usr/local/bin/sudo'. Also, the file system sudo resides
on must *not* be mounted (or exported) with the nosuid option or sudo
will not be able to work. Another possibility is you may have '.' in
your $PATH before the directory containing sudo. If you are going
to have '.' in your path you should make sure it is at the end.
Business Accounts
Answer for Membership
by: kyle_in_taiwanPosted on 2006-09-01 at 06:24:32ID: 17436787
If your user's name is Billyfoo:
# Host alias specification
Host_Alias LOCAL = 127.0.0.1
# User Specifications
Billyfoo LOCAL = NOPASSWD: /etc/init.d/crond
That should do it.