X11Forwarding Fails on Opensuse 12.1 with IPv6 Disabled

I’m one of those people that still disables IPv6 on all my Linux boxes. And, I guess I’m being punished for it, since if you disable IPv6 on Opensuse, then X11Forwarding will no longer function in its default form.

The good news is that it’s an easy fix.  All you have to do is to force sshd to listen purely on IPV4.  So, just do the following:

vi /etc/ssh/sshd_config

(or gedit /etc/ssh/sshd_config, or kedit /etc/ssh/sshd_config)

…and change this block from:

#Port 22
#AddressFamily any
#ListenAddress ::


Port 22
AddressFamily inet
#ListenAddress ::

With this change, the inet statement causes it to use IPv4 only, the means listen on any valid IPv4 address (change to suit), and the Port command specifies the IPv4 port, usually changed to taste.


Leave a Comment

Your email address will not be published.