Is it possible to restart an X11/Xwindows session without having to exit the server I've SSH'd to?
I'm currently using iTerm on OSX, and every so often X11 (I guess) times out (giving me the error below)
Vibrant applications require X Windows
and I have to exit the server, restart ITerm and then SSH back in which is frustrating. I've already tried a solution I saw previously by adding an X11 timeout parameter to my config
like so:
host someserver
Hostname 111.222.33.444
User joe
ForwardX11 yes
ServerAliveInterval 300
ForwardX11Timeout 595h
But it's still not totally robust, so to reiterate, can I, in any way, restart X11 without interrupting my connection status with the server?
Or better yet, is there some other method that can prevent it happening in the first place?!
Best Answer
You're probably seeing the xauth timeout that
ForwardX11Trusted no
sets. You can change the length of the timeout withForwardX11Timeout
, but unfortunately you can't set that very long—it will crash the X server (or maybe just error out in newer Xorgs). See the question Disable ForwardX11Timeout without ForwardX11Trusted in OpenSSH Client?You can set
ForwardX11Trusted yes
or usessh -Y
to disable the timeout entirely, though.