Prev: chdir usage
Next: how to alias
From: Florian Diesch on 31 Dec 2009 15:44 SINNER <arcade.master(a)gmail.com> writes: > * GangGreene wrote in comp.os.linux.misc: > >> SINNER wrote: >> >>> * Chris Cox wrote in comp.os.linux.misc: >>> >>>> Matthew Lincoln wrote: >>>>> Sorry for this newbie question: >>>>> >>>>> at is the difference between "su" and "sudo" command ? >>>> >>>> sudo is a more flexible and feature full way of doing something >>>> as another user. Has more options allowing for things like >>>> executing only specific commands, executing things without >>>> password, etc. It's closer to allowing role based security. >>>> >>>> su is pretty basic. >>> >>> You have that backwards. su opens a shell as that user, from there >>> you can do anything as the new user. sudo limits you to one command >>> and is far more limited. >>> >>> sudo elevates your permissions, su makes you the specified user. >>> >> >> Wrong! > > Really? what did I say that was wrong? They both do the same: Let you run a program as another user. The only difference is that sudo offers more flexibility by editing /etc/sudoers and su defaults to run a shell while sudo defaults to run a given command. Florian -- <http://www.florian-diesch.de/software/pdfrecycle/>
From: Wanna-Be Sys Admin on 31 Dec 2009 20:12 Matthew Lincoln wrote: > Sorry for this newbie question: > > at is the difference between "su" and "sudo" command ? > > Matthew sudo runs commands as the user you assume the privs of, while su makes you the user (changes you to that user). Most people use sudo to limit what commands what users can have access to run, which is usually safer. Of course, there's a lot more to it than that. -- Not really a wanna-be, but I don't know everything.
From: piscesboy on 1 Jan 2010 06:02 On Dec 30 2009, 1:15 pm, kmlincoln...(a)hotmail.com (Matthew Lincoln) wrote: > Sorry for this newbie question: > > at is the difference between "su" and "sudo" command ? > > Matthew http://kb.iu.edu/data/amyi.html
From: piscesboy on 1 Jan 2010 06:04 On Dec 30 2009, 1:15 pm, kmlincoln...(a)hotmail.com (Matthew Lincoln) wrote: > Sorry for this newbie question: > > at is the difference between "su" and "sudo" command ? > > Matthew http://kb.iu.edu/data/amyi.html
From: notbob on 1 Jan 2010 08:46
On 2010-01-01, Wanna-Be Sys Admin <sysadmin(a)example.com> wrote: > sudo runs commands as the user you assume the privs of, while su makes > you the user (changes you to that user). Most people use sudo to limit > what commands what users can have access to run, which is usually > safer. Of course, there's a lot more to it than that. Such as: Sudo can be configured to log all invocations of the command. Also, su doesn't provide all the users settings. Try "su -" to get true user bennies. nb |