0

I'm trying to open GUI installation from shell without success so I tried first to open just xclock but was unable as well. usually export to DISPLAY solved the problem. I have a haunch that it security related but I lack the right knowledge to debug it.

[grid@localhost grid122]$ export DISPLAY=:0
[grid@localhost grid122]$ xclock 
No protocol specified
Error: Can't open display: :0
[grid@localhost grid122]$ export DISPLAY=localhost:0
[grid@localhost grid122]$ xclock 
Error: Can't open display: localhost:0

Tried different addresses as well:

localhost:0.0
127.0.0.1:0
127.0.0.1:0.0

Also modify /etc/hosts.allow didn't work.

I am using CentOS 7 with GNOME

fpmurphy
  • 4,636
Nir
  • 1,335

1 Answers1

-1

Answer found here once I understand the problem - I can start xclock from the user I logged in but not from other users. Solution was running xhost + from the user I logged into.

Funny thing is I did xhost + numerous times before.

Nir
  • 1,335
  • That's a terrible solution unless you are absolutely totally sure your X Server can't be accessed remotely (directly on port 6000 or indirectly by someone logging in to your machine remotely). – Chris Davies Jan 11 '19 at 08:12