1 |
On Mon, Aug 9, 2010 at 6:18 PM, William Hubbs <williamh@g.o> wrote: |
2 |
|
3 |
> On Mon, Aug 09, 2010 at 05:30:40PM -0700, Kevin O'Gorman wrote: |
4 |
> > On Mon, Aug 9, 2010 at 1:20 PM, Bill Longman <bill.longman@×××××.com> |
5 |
> wrote: |
6 |
> > > I actually prefer "sudo su -" -- as long as I'm giving it away! :o) |
7 |
> |
8 |
> Afaik, there is no reason for "sudo su -" It should be either |
9 |
> |
10 |
> su - |
11 |
> |
12 |
> or, if you are using sudo, |
13 |
> |
14 |
> sudo -i |
15 |
> |
16 |
> The disadvantage of "su -" is that it requires the user to know the root |
17 |
> password. But, "sudo -i" does the same thing without requiring the user |
18 |
> to know the root password. |
19 |
> |
20 |
> You either didn't think or didn't actually try it. "sudo su -" needs a |
21 |
password, but it's the |
22 |
user password. Running su as root never needs a password. Accordingly, |
23 |
this works on |
24 |
a stock Ubuntu with no root password. |
25 |
|
26 |
"su -" requires the root password unless you're already root, and the root |
27 |
password may or may not exist. |
28 |
|
29 |
I didn't know about "sudo -i" (thanks), but when I tried "sudo -i" it |
30 |
immediately asked for a password, for which |
31 |
the user password was sufficient. So it's entirely equivalent to but |
32 |
slightly shorter than my version. I'll stick with |
33 |
mine because it's made of parts I already know and won't forget. |
34 |
|
35 |
I think that if sudoers don't need to enter passwords, they're still |
36 |
equivalent, but I have not tried this. |
37 |
|
38 |
-- |
39 |
Kevin O'Gorman, PhD |