Official Everybody Edits Forums

Do you think I could just leave this part blank and it'd be okay? We're just going to replace the whole thing with a header image anyway, right?

You are not logged in.

#1 2016-12-06 16:52:43

Era
Member
From: ::1
Joined: 2015-05-06
Posts: 884

sudo vs su

i like su more!

Offline

#2 2016-12-06 17:03:46

drunkbnu
Formerly HG
Joined: 2017-08-16
Posts: 2,306

Re: sudo vs su

su is a command to switch users, without changing the user environment. However, if you use it without any arguments, it'll attempt to log as root. su can be used by everyone.

sudo is a command designed to run commands as root, using your account's password instead of the root account's password (by default locked in Ubuntu). You must be a sudoer (administrator) to use sudo.

Offline

Wooted by: (3)

#3 2016-12-06 17:22:01

Era
Member
From: ::1
Joined: 2015-05-06
Posts: 884

Re: sudo vs su

HG wrote:

su can be used by everyone.

Does enterely depend on your config or OS,
Default for FreeBSD would be that you have to be in the wheel group to execute su.
Ubuntu's Default is that you need to be in the sudo group to execute sudo.
However it can be tuned so anyone can use sudo if you'd like.

This thread is about which command you prefer since both binaries allow you to reach the same goal.

Offline

#4 2016-12-06 17:31:39

drunkbnu
Formerly HG
Joined: 2017-08-16
Posts: 2,306

Re: sudo vs su

You can log as root using your account's password using the combination sudo su. But I don't like to mess up with my current environment so I prefer the root environment for which I use sudo -i.

Offline

#5 2016-12-06 18:50:32

Zumza
Member
From: root
Joined: 2015-02-17
Posts: 4,656

Re: sudo vs su

sandwich.png
I prefer sudo. It's safer in my opinion.


Everybody edits, but some edit more than others

Offline

Wooted by: (2)

#6 2016-12-06 19:44:04

Different55
Forum Admin
Joined: 2015-02-07
Posts: 16,575

Re: sudo vs su

I go with su, I don't think I even have sudo installed at the moment. Su -c makes more sense to me than sudo anyway. Force you to type root's password instead of your own password. If someone's in your computer it's more likely they know your password than root's password. But this is just my home PC, sudo wasn't installed by default so I didn't bother, and I think sudo can be configured to require the password of the target user like su does.


"Sometimes failing a leap of faith is better than inching forward"
- ShinsukeIto

Offline

Wooted by: (2)

#7 2016-12-06 22:31:09

Pingohits
Banned
From: aids lizard
Joined: 2015-02-15
Posts: 7,591

Re: sudo vs su

when i walk into this topic it feels like i entered a foreign country


791mAP8.png

Offline

Wooted by:

#8 2016-12-06 23:02:17

Zumza
Member
From: root
Joined: 2015-02-17
Posts: 4,656

Re: sudo vs su

Pingohits wrote:

when i walk into this topic it feels like i entered a foreign country

its like Window's run as admin but in Linux.


Everybody edits, but some edit more than others

Offline

#9 2016-12-06 23:11:00

Different55
Forum Admin
Joined: 2015-02-07
Posts: 16,575

Re: sudo vs su

Zumza wrote:
Pingohits wrote:

when i walk into this topic it feels like i entered a foreign country

its like Window's run as admin but in Linux.

Now you're making it sound like linux is nothing but terminal witchcraft. If you never opened a terminal you'd never need to know about any of this, but yeah sudo and su are basically Window's Run as Admin or UAC popups for terminals. If you don't use a terminal then you get a normal popup box asking for your password like OS X does.


"Sometimes failing a leap of faith is better than inching forward"
- ShinsukeIto

Offline

#10 2016-12-07 04:03:26

Ratburntro44
Member
Joined: 1970-01-01
Posts: 1,383
Website

Re: sudo vs su

Different55 wrote:

Now you're making it sound like linux is nothing but terminal witchcraft

it isn't?

Offline

#11 2016-12-07 13:10:13

Zumza
Member
From: root
Joined: 2015-02-17
Posts: 4,656

Re: sudo vs su

Ratburntro44 wrote:
Different55 wrote:

Now you're making it sound like linux is nothing but terminal witchcraft

it isn't?

No. A linux user considers the GUI black magic. The terminal is the good magic.
Good magic always win whereas the black magic is unpredictable.


Everybody edits, but some edit more than others

Offline

#12 2016-12-07 13:15:14

Tomahawk
Forum Mod
From: UK
Joined: 2015-02-18
Posts: 2,847

Re: sudo vs su

Sudoku.


One bot to rule them all, one bot to find them. One bot to bring them all... and with this cliché blind them.

Offline

Wooted by:

#13 2016-12-10 17:53:19

Anatoly
Guest

Re: sudo vs su

i use sudo bash

Anatoly1481388799639047

Board footer

Powered by FluxBB

[ Started around 1732206212.7695 - Generated in 0.042 seconds, 10 queries executed - Memory usage: 1.58 MiB (Peak: 1.77 MiB) ]