1

I have a desktop and a server both running CentOS 7.5 and I run ssh -X from desktop to the server. After connection is made ~/.Xauthority file is written and I have

$ echo $DISPLAY
localhost:10.0
$ xauth list
host.example.com/unix:10  MIT-MAGIC-COOKIE-1  xxxxxxxxxxxxxxx
host.example.com:10  MIT-MAGIC-COOKIE-1  yyyyyyyyyyyyyyyy

but running xclock gives Error: Can't open display in two minutes. Using ssh -Y makes no difference. In sshd_config I have

X11Forwarding yes
X11DisplayOffset 10
X11UseLocalhost yes

Setting X11UseLocalhost no does not fix the problem. ss -l | grep 6010 has an empty output.

I also have a different server where forwarding X from the same desktop works as it should. Any ideas how to fix the problem?

  • Have you tried to access the root user first? – Edmhar Oct 16 '18 at 19:05
  • Yes, I have tried it. With the same result. – mike_934 Oct 16 '18 at 19:26
  • Does ssh -vvX user@host provide any useful error messages? – RubberStamp Oct 16 '18 at 19:59
  • @RubberStamp: No. It could provide if the problem was on the desktop side, but it is on the server one. There are 2 important messages there: Authentication succeeded (publickey). and Requesting X11 forwarding with authentication spoofing – mike_934 Oct 16 '18 at 20:23

Your Answer

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

Browse other questions tagged or ask your own question.