gksu vs sudo

Questions about other topics - please check if your question fits better in another category before posting here
Forum rules
Before you post please read this

gksu vs sudo

Postby Mint-O-Meal on Tue Mar 27, 2007 11:37 pm

Is there a reason for using "gksu" to open an application with root privileges instead of sudo ? The reason I ask is I'm use to distro's that only use "su" instead of "sudo" "gksu"

Example: "gksu gedit" vs "sudo gedit" vs "su kate"

What does the 'gk' stand for ?
Mint-O-Meal
Level 1
Level 1
 
Posts: 20
Joined: Thu Feb 22, 2007 12:49 pm

Linux Mint is funded by ads and donations.
 

Postby Boo on Wed Mar 28, 2007 1:33 am

It is a Gtk sudo, good for using with Gtk written GUI apps.
sudo uses a sodoers list and you use your own password to be root.
su needs a root or the particular users password to use unless you are already root.
:D
Image
Now where was i going? Oh yes, crazy!
User avatar
Boo
Level 8
Level 8
 
Posts: 2364
Joined: Mon Mar 26, 2007 7:48 am

Postby scorp123 on Wed Mar 28, 2007 4:56 am

su = Switch user. "su -" switches to root.
sudo = SuperUser do. Do something as the superuser "root".

Combinations are also possible: sudo su - ... gives you a root shell.
User avatar
scorp123
Level 8
Level 8
 
Posts: 2287
Joined: Sat Dec 02, 2006 4:19 pm
Location: Switzerland

Postby clem on Wed Mar 28, 2007 7:42 am

Very good question...

"sudo gedit" and "gksu gedit" are pretty much the same... with sudo you'll have to write the password in the console before gedit opens.. with gksu it might come up as a dialog box before gedit opens... so it's more or less the same stuff.

The REAL advantage of gksu is when you want to get your console back...

If you type "sudo gedit &" the "&" bit gives you the console back.. and you don't get the opportunity to type the password for sudo.. so gedit simply doesn't open :)

To solve this problem you replace it with "gksu gedit &". This way your console is freed, and the password dialog box is there as well.

Same goes for kdesu.

Clem
User avatar
clem
Level 15
Level 15
 
Posts: 5545
Joined: Wed Nov 15, 2006 8:34 am

Postby Mint-O-Meal on Wed Mar 28, 2007 8:14 am

Thanks to all of you, now I understand 8)

The REAL advantage of gksu is when you want to get your console back


Nice :D
Mint-O-Meal
Level 1
Level 1
 
Posts: 20
Joined: Thu Feb 22, 2007 12:49 pm


Return to Other topics

Who is online

Users browsing this forum: Resistor and 3 guests