Preventing X11 forwarding from timing out

At least on Mac OS-X the X11 forwarding is timing out after a few minutes and the display can't be opened by subsequent windows.

One way to prevent this is to use the following parameters on the command line:

ssh -o TCPKeepAlive=no -o ServerAliveInterval=15 -o ForwardX11Trusted=yes -X -l root 192.168.0.243

 

ssh -o TCPKeepAlive=no -o ServerAliveInterval=15 -o ForwardX11Trusted=yes -XC -i ./instkey opc@a.b.c.d