You are not logged in.

#1 2010-12-11 15:25:16

jdn06
Member
Registered: 2010-02-01
Posts: 67

No protocol specified - cannot open display: :0.0

No protocol specified

(gedit:7297): Gtk-WARNING **: cannot open display: :0.0

or

No protocol specified
Error: cannot open display: :0.0

Since a week, I have this message every time I launch a graphical application from gnome-terminal. I read a few topics about this on the forum, but the problem doesn't seem to be the same. To be more precise:
- Everything works correctly when I am connected locally with another account (I use GNOME and gdm from inittab)
- Everything works fine too when I launch a graphical application from another computer with ssh in a terminal with the account which makes problem locally Curious, isn't it ?

Finally, I tried to move ICEauthority and Xauthority. New ones were created, but the problem is still here.

Any idea ?

Offline

#2 2010-12-12 19:37:21

jdn06
Member
Registered: 2010-02-01
Posts: 67

Re: No protocol specified - cannot open display: :0.0

The solutions I found on the forums were all about a "xhost + localhost" command, but every xhost command on this session gives me a "No protocol specified error". When I type this xhost command from the other session which is ok, it works but doesn't change anything.
I tried to copy .Xauthority and .ICEauthority from a session to the other. No change.

Offline

#3 2010-12-21 20:51:40

bdjnk
Member
Registered: 2009-08-24
Posts: 78

Re: No protocol specified - cannot open display: :0.0

I've got pretty much the same issue. I'm going to be downgrading various packages until I find the culprit. Still, any thoughts on a real solution are greatly appreciated.

Offline

#4 2010-12-24 06:22:36

meop
Member
Registered: 2010-11-01
Posts: 31

Re: No protocol specified - cannot open display: :0.0

This can happen when X is started with the argument to ignore tcp requests, and you're not forwarding through ssh. It is usually default behavior. I can fix it when using KDM, by removing `nolisten -tcp` from /usr/share/config/kdm/kdmrc. After this, `xhost + whatever` will work.

Others have disabled this behavior with GDM using these tricks : https://bbs.archlinux.org/viewtopic.php?id=105546 .. they don't work for me though.

I also wonder what causes some X programs to fail to open a display on what should be a local X session that shouldn't need tcp.

Last edited by meop (2010-12-24 06:23:12)

Offline

#5 2011-01-30 08:43:17

jdn06
Member
Registered: 2010-02-01
Posts: 67

Re: No protocol specified - cannot open display: :0.0

The problem is still here and I found no solution. I repeat that I don't try to connect X through ssh; it works and I don't use it a lot. I just want to launch a graphical application locally from gnome-terminal and it doesn't work anymore for one user only.

Offline

#6 2011-01-30 09:23:53

sirocco
Member
Registered: 2008-03-10
Posts: 149

Re: No protocol specified - cannot open display: :0.0

Offline

#7 2011-01-30 10:02:44

jdn06
Member
Registered: 2010-02-01
Posts: 67

Re: No protocol specified - cannot open display: :0.0

Thanks for the link. I checked, but:
- everything seems OK for the export in .bashrc:

export XAUTHORITY=/home/myusername/.Xauthority

- The xhost command doesn't work

$ xhost + localhost
No protocol specified
xhost:  unable to open display ":0.0"

Offline

#8 2011-01-30 10:25:49

jdn06
Member
Registered: 2010-02-01
Posts: 67

Re: No protocol specified - cannot open display: :0.0

I tried something from this page (I know, it's not Linux...). Resulting this:

$ mv .Xauthority .Xauthority.old
$ xauth generate :0 . trusted 
xauth:  file /home/myusername/.Xauthority does not exist
No protocol specified
xauth: (argv):1:  unable to open display ":0".

Does anyone know how to rebuild correctly .Xauthority?

Offline

#9 2011-02-14 07:02:13

ffjia
Member
Registered: 2009-08-26
Posts: 94

Re: No protocol specified - cannot open display: :0.0

jdn06 wrote:

I tried something from this page (I know, it's not Linux...). Resulting this:

$ mv .Xauthority .Xauthority.old
$ xauth generate :0 . trusted
xauth:  file /home/myusername/.Xauthority does not exist
No protocol specified
xauth: (argv):1:  unable to open display ":0".

Does anyone know how to rebuild correctly .Xauthority?

Since you can solve this issue by "export XAUTHORITY", why did you rebuild
.Xauthority?

Offline

Board footer

Powered by FluxBB