SSH X forwarding too slow

I have the following setup:

                           internet
host_1  -->  router_1    <---------->    router_2  <-- host_2

Both host_1 and host_2 run Ubuntu 18.04. From host_2, I would like to access the GUI applications in host_1 through ssh X forwarding. So, I tried with option -C in addition to -X:

<host_2_prompt>$ ssh -CX <router_1_public_IP>

This actually works, but any movement/update in the GUI windows is unacceptably slow. Both routers use an ADSL connection: in particular, router_1 available upload band is 1.0 Mbps.

Is there a way to improve this performance? For example, to further compress the exchanged data?


Note: using the same connection, I am able to access Remote Desktop in Windows Server 2008 with almost no delay, as if the machine was local. So, I guess the available bandwidth should be enough also for ssh.

Asked By: BowPark

||

You don’t want the -C option in the ssh connection. Compression is great when you are moving lots of data, but here you want responsiveness, and your ADSL is fast enough.

Switching to x2go should make you very happy. It implements an X11 specific compression. Both ends know when the end of an X11 message is reached and can force the data to be transmitted, rather than a general compressor which waits a while in case more data is about to be sent and could therefore be compressed and added to the current packet.

Answered By: icarus