On Monday 31 May 2004 01:34, Doug McGarrett wrote:
On Sunday 30 May 2004 14:59, Patrick Shanahan wrote: /snip/
/bin/ls: kde3: Permission denied
you need root access, ie: su or sudo or sux...
I can't believe that so much stuff is perms denied in these later versions of Linux. I could deal with the eralier versions. Now, someone please tell me what is the difference between su and sudo and sux. And why?
"su" is the standard command to change users. Plain "su" changes to root with the current environment (environment variables like $HOME, aliases, etc.). I.e., you run with root's permissions only. "su -" changes to root and adopts root's environment. I.e., you are essentially logged in as root (there are slight differences that usually can be ignored). And "su - user" changes to a user "user" with that user's environment. "sux" is a SuSE specific command. It gives the new user permission to access the running X server. I.e., "su -" will not let you run X programs, even as root, unless you have given permission as the original user (e.g., "xhost +localhost"). In SuSE, "sux" is almost always the command to use instead of plain "su". Note: any change from an ordinary user to any other user, root or ordinary, requires that user's password. "sudo" executes a single command as the target user. It has configuration information that must be editted first before using. See "man sudoers" and "man visudo" (visudo is the preferred way to change the configuration file, it checks the syntax of the configuration file before committing it). "sudo" allows ordinary users to run privileged commands, if given the appropriate permissions by root. E.g. you could allow specific users to shutdown the systems without giving them root's password. HTH, Jeffrey