I am trying to launch file manager as root in the panel I get a error when I put sudo in front of the command exo-open --launch FileManager it returns a error. However, if I put the same command in a XFCE terminal (not the emulator) I launch file manager as root and it works. I am very confused

  • You really should always post the error message into the question for us to be able to help
    – Rinzwind
    Oct 28 '16 at 19:57
  • Why not make a launcher (.desktop file) running gks... Oct 28 '16 at 20:36

Please note that it can be very dangerous to run your file manager as a root user.

You can use gksu for launching GUI applications as root.

Install gksu from a terminal:

sudo apt install gksu

After it is installed, you can now launch it without a terminal by pressing Alt+F2 and typing in:

gksu thunar

Thunar is the default file manager in Xubuntu.

NOTE: gksu is no longer available for Ubuntu 18.04. However, pkexec is installed by default in 18.04.

You can also use pkexec as well to launch. Same as above and change gksu to pkexec.

pkexec thunar

If you don't want to open a terminal window, press Alt+F2 to bring up a run window and you can type in that command that way you are not leaving any terminal windows open:

enter image description here

enter image description here


Hard-to-use security won't be used. I hope the following answer convincingly demonstrates the imprudence of Debian's failure to replace gksu with a work-alike facility based on PolicyKit.

The following two easy steps will provide with one-click access to thunar (or any other app) with root privileges:

Create an app launcher in which the command line is:

sudo thunar

As root, edit /etc/sudoers.d/ so that it contains:


Afterwards, whoever uses username's X-window session will have root privileges. Since the loss of gksu, however, it's an easy way to have one-click access to a root-privileges app from a non-root GUI.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy