I have been trying to get X11 port forwarding to work from my laptop. I can\'t figure out why it won\'t work.
I get this message when I try to run xterm:
I got the same issue on a Debian OpenVZ container and the problem seemed to come from my /etc/hosts file where "localhost" was affected to the LAN IP, not 127.0.0.1.
Before :
192.168.0.15 dagi dagi.domain.net localhost localhost.localdomain
After :
192.168.0.15 dagi dagi.domain.net
127.0.0.1 localhost localhost.localdomain
After that, both ssh -X
and ssh -Y
worked like a charm without even restarting sshd.