Thread: Switch User
View Single Post
Old Feb 11th, 2008, 2:29 PM   #2
jim mcnamara
Hobbyist Programmer
 
Join Date: Jun 2005
Location: New Mexico
Posts: 228
Rep Power: 4 jim mcnamara is on a distinguished road
Re: Switch User

The /etc/sudoers file dictates who is allowed to sudo to what account.
When setup up correctly:
 sudo su - <someusername>
 ls 
 exit # get out of sudo
requires no password.

If you set up so that you or whoever is running the script can sudo then the script will run without a passwoird prompt.
jim mcnamara is offline   Reply With Quote