X Window System/remote session

from HTYP, the free directory anyone can edit if they can prove to me that they're not a spambot
< X Window System
Revision as of 15:14, 22 January 2006 by Woozle (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Computing: Linux: Running a remote X session

Explanation

The X Windows system, unlike many other more popular windowing systems, carefully separates the client (i.e. the part which the user sees and interacts with) from the server (i.e. the part which does all the work behind the scenes). This means that the client does not actually have to be running on the same machine as the server. It is possible to set up a window on one machine which is actually a session running on another machine – similar to VNC, but designed into the system rather than being a kluge on top of it. (However, see #Bugs.)

In order to do this, you will need Xnest running on the "client" machine. This is available in standard repositories for most Linux distributions (including Ubuntu and SuSE).

How

  • On the local (client) machine (note the space before the ":"):
Xnest -ac :1
  • On the remote machine (via ssh or equivalent):
export DISPLAY=yourmachine:1

...where yourmachine is the name or IP address of your local machine. If you get messages indicating that it's having trouble connecting to yourmachine, try using an IP address instead. If you are using a Windows (Samba) network and machine names do not automatically resolve to IP addresses, use "nmblookup yourmachine" to get the address.

  • You will then need to run the command to start a GUI session; startkde starts KDE. Not sure what other commands might be available.

Bugs

  • Resized windows often don't display properly; the controls within the window resize, but the window itself won't grow past its original size. Controls which move outside the visible area become inaccessible, including the window-frame controls (max/min/close).
  • New windows often don't display at all (except in the taskbar, if they would normally show up there), but you can make them appear by clicking on the K menu in the taskbar.