Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Scripting Switch User 1

Status
Not open for further replies.

olli2003

Technical User
Joined
Jan 31, 2003
Messages
93
Location
DE
Hi Gys!
It would be nice to get some suggestions for my problem here. I'd like to execute a command by another user than Root. This should be done by a script. The process within the script must be like this:

ROOT#su - <USER>
USER#ls -ltr /opt/freeware/glitter/*.log > /tmp/glitter.txt

Please notice that I have a different user environment. Perhaps I should directly do in the crontab? I've tried to do with this user, but it doesn't work :(

Thanks for all help!
Kind Regards, Oliver
 
olli2003 said:
Was a good help to me!
Well, basically, that IS the main purpose of these forums...[reading]

HTH,

p5wizard
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top