Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm trying to achieve same result as the answer from that existing SF question without having to enter the password for the original user, that is, I'm userA, and I want to be able to run a command as userB without having to enter the passwords for any of these users.

Can somehow provide an example to assist me please?

share|improve this question
up vote 5 down vote accepted

Just add a NOPASSWD tag. So, using the example in the previous question, you would do:

tom  ALL=(oracle) NOPASSWD: /bin/chown tom *
share|improve this answer

Your Answer


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

Not the answer you're looking for? Browse other questions tagged or ask your own question.