Run GUI programs over SSH without an X server
Run GUI programs over SSH without an X server
There are several methods; here are a few of them.
- SSH X forwarding.
Make sure these parameters are enabled in
/etc/ssh/sshd_configon the server:# Specifies whether TCP forwarding is permitted AllowTcpForwarding yes X11Forwarding yes # The first display number available for sshd's X11 forwarding X11DisplayOffset 10 # Bind the X11 forwarding server to the loopback address (yes) or to the wildcard address (no) X11UseLocalhost yesTurn on X forwarding when connecting:
ssh -X user@hostIf you get errors with
-X, treat the remote machine as a trusted client:ssh -Y user@host
- Use the remote display. Run the program with
-display :0.0after its name. Running it insidescreenis handy here. - Export the display variable:
export DISPLAY=":0.0", then start the program.
Last updated on