gksudo does not run in terminal - display can not be opoend

Asked by BlauesEi

ubuntu 12.4 with gnome3 desktop

Hi,

I can not start applications like gedit or nautilus with admin rights in the
gnome-terminal.

gksudo nautilus

After the password entry I get the follwoing error:

Could not parse arguments: Display can not be opend

When I repeat this command in the same terminal window
gksudo nautilus
I get the following error:

** (nautilus:971): WARNING **: command line »dbus-launch
--autolaunch=969937dd922ac0603700cc724bee97a8 --binary-syntax --close-stderr«
has been canceled with Null unequal exit state 1: Autolaunch error: X11
initialization failed.\n
Could not parse arguments: Display can not be opend:

It's the same with
gksu and
DISPLAY=:0 gksudo nautilus

Its the same when I change user to root.

When I try to run it via the alt+F2 command entry window nothing happens.

Could you please help me solving this problem?

Question information

Language:
English Edit question
Status:
Solved
For:
Ubuntu sudo Edit question
Assignee:
No assignee Edit question
Solved by:
BlauesEi
Solved:
Last query:
Last reply:
Revision history for this message
actionparsnip (andrew-woodhead666) said :
#1

If you install pcmanfm then run:

gksudo pcmanfm

Is it ok?

Can you also give the output of:

lsb_release -a; uname -a; apt-cache policy nautilus

Thanks

Revision history for this message
BlauesEi (dieente) said :
#2

Here are the results:

gksudo pcmanfm
Display can not be opend

-------------------------------------------------------

lsb_release -a

No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 12.04 LTS
Release: 12.04
Codename: precise

---------------------------------------

uname -a
Linux ich-pc 3.2.0-23-generic #36-Ubuntu SMP Tue Apr 10 20:41:14 UTC 2012 i686 i686 i386 GNU/Linux

--------------------------------------------

apt-cache policy nautilus

nautilus:
  installed: 1:3.4.1-0ubuntu1
  Candidat: 1:3.4.1-0ubuntu1
  Versionstabelle:
 *** 1:3.4.1-0ubuntu1 0
        500 http://de.archive.ubuntu.com/ubuntu/ precise/main i386 Packages
        100 /var/lib/dpkg/status

-------------------------------------------------------

Please notice, that the problem does not only occure wit nautilus but with any gui program I need admin rights.

Also with gedit, synaptic and gparted occure the the same error..

Revision history for this message
actionparsnip (andrew-woodhead666) said :
#3

Try:

sudo apt-get --reinstall install gksudo

Revision history for this message
BlauesEi (dieente) said :
#4

sudo apt-get --reinstall install gksudo

Package gksudo is not available, but is referred to by another package. This may mean that the package is missing, has been obsoleted, or is only available from another source

E: Package 'gksudo' has no installation candidat

Revision history for this message
actionparsnip (andrew-woodhead666) said :
#5

sudo apt-get --reinstall install gksu

Sorry

Revision history for this message
BlauesEi (dieente) said :
#6

I have already the latest version of gksu

sudo apt-get --reinstall install gksu

Preparing to replace gksu 2.0.2-6ubuntu1 (using .../gksu_2.0.2-6ubuntu1_i386.deb) ...
Unpacking replacement gksu ...
Replaced by files in installed package vinuxscripts ...

------------------------------------

After this nothing has been changed.

Revision history for this message
BlauesEi (dieente) said :
#7

Hi,

thank you for all your answers.

I found the solution:
I have had after successive upgrading to ubuntu 12.04 still an old package vinuxscripts (http://vinuxproject.org/) from ubuntu 10.04 on my system.

this package is at the moment only for ubuntu 10.04 valid.

It replced the gksu package.

After removing the package vinuxscripts and installing package gksu, gksudo and gksu are working.

Certainly I have to use gksudo with DISPLAY=:0 gksudo.

if you know how I can use gksudo withoud DISPLAY, please feel free to tell me that.

have a wonderful day