Website based on my experience working as System Administrator

LINUX INFORMATION WEBSITE

This site is dedicated to providing tutorials, help, guides and links for Linux users.
HOME PAGE
LINUX COMMANDS
   
   
   
   
   
   
   
   
   

LINUX COMMANDS

Contents | Previous | Next

The su command

$ su - substitute user

The su command allows you to temporarily become another user, until you press Ctrl+D to logout.

su
Become root.


su -
Become root and inherit path.

Note:

The root account is set-up with more directories in its path than an ordinary user. Particularly sbin directories as well as the usual bin directories, where the system administration commands are located. Unless you inherit root's path, many commands you enter will require the absolute path to the command.


su -p
Become root and stay in (preserve) current directory.


su -c 'rpm -Uvh xchat-1.8.5-0.i386.rpm'
Run this one command as root.


su john
Become john.

Contents | Previous | Next

 
Last Update: Jan 2003

HOME | CONTACT | FAQ'S | TRICKS & TIPS | WEIRD NEWS
This Material has been taken from different sources. Its free for anyone to use and reproduce.