Computing.Net > Forums > Unix > Switching Users in a batch script

Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Over 90% answered within 24 hours! Click here to start participating now! Also, be sure to check out the New User Guide.

Switching Users in a batch script

Reply to Message Icon

Name: mxer178
Date: October 14, 2004 at 11:03:18 Pacific
OS: Sol, HP, AIX, Linux
CPU/Ram: alot
Comment:

I am trying automation some unix installs, however, some of the installs need be ran under the root login. I do not want my client app to run as root, too many bad things can happen. So, what are some methods that I can essentially su to root, run my install script, then exit out of my root session?

Thanks!



Sponsored Link
Ads by Google

Response Number 1
Name: nails
Date: October 14, 2004 at 16:20:35 Pacific
Reply:

I recommend you use the sudo utility. Check out the sudo home page at:

http://www.gratisoft.us/sudo/sudo.html.

Regards,

Nails


0
Reply to Message Icon

Related Posts

See More


crontab problem ls command



Post Locked

This post is quite old and has been locked from receiving new replies. Please create a new posting instead.


Go to Unix Forum Home


Sponsored links

Ads by Google


Results for: Switching Users in a batch script

Change of user in a script www.computing.net/answers/unix/change-of-user-in-a-script/6984.html

How to disconnect DB in a UNIX script www.computing.net/answers/unix/how-to-disconnect-db-in-a-unix-script/8505.html

How to attach a file in a mail (UNIX script) www.computing.net/answers/unix/how-to-attach-a-file-in-a-mail-unix-script/8487.html