I presume this applies to any Gnome desktop. What is the difference between these two commands? According to the Ubuntu documentation and questions that reference it, the former also sets the $HOME
environment variable and copy the .Xauthority variable to temporary location, but are those the only differences for all systems running Gnome, or do they only apply to Ubuntu?
After searching at greater length and finding a few other sources, I think it's safe to say that gksu
is nothing more than a wrapper
around sudo
in most cases. This source states that since gksu
displays a password dialog, it's used for graphical applications (as we already know) because it can be used outside a terminal emulator. Otherwise, running sudo <cmd>
from a launcher wouldn't work because the user wouldn't be prompted for a password.
I remember I couldn't run some X applications with sudo
, but was able to run them with gksudo
or kdesudo
.
gksudo
just linked togksu
, at least on Ubuntu. – Ricardo Altamirano Feb 28 '13 at 22:49gksudo
function differently on a system (like Ubuntu) where it's nothing more than symlink togksu
? (It's a serious question. I don't know enough about Linux to know if it makes a difference). – Ricardo Altamirano Mar 5 '13 at 14:59gksudo
, act like gksudo; if it'sgksu
act likegksu
– daisy Mar 5 '13 at 15:10