===== gnome ----- /etc/X11/gdm/gdm.conf DisallowTCP=false init 1 init 2 xeyes -display somewhere.mycorp.com:0.0 ===== X windows info xdpyinfo /etc/X11/gdm/Sessions/Default default setup ================================================= zaph.com/Modeline calculate XFree86 Modelines john.snoop.dk//programs/linux/read-edid/read-edid.tar.gz ================================================= import -display :0 -window root snap1.png $ xauth add navel/unix:0 MIT-MAGIC-COOKIE-1 1b3a196c7073742666264b1b0e111f77 $ xauth add localhost:0 MIT-MAGIC-COOKIE-1 1b3a196c7073742666264b1b0e111f77 ...and give the snapshot another try: $ import -display :0 -window root /tmp/wdm.png ================================================= xauth add :0 XDM-AUTHORIZATION-1 [put a whole lot of hex characters here... an even number of them] xauth extract - :0 | ssh -l otherhat@localhost xauth merge - keep ssh alive ================================================= /usr//lib/X11/XKeysymDB xmodmap ===================================== X-windows cal | xmessage -file - -title "Calendar" ctrl-alt-f2 startx -- :1 'startx' automatically runs 'startx -- :0' switch back to your first X sessions by doing a crtl-alt-F7 and back again to your second by ctrl-alt-F8 startx -- -cc StaticGrey - Running X on a specific VC: startx -- :0 vt7 & # Launches display 0 to VC7 (standard) startx -- :2 vt22 & # Launches display 2 to VC22 (nonstd) To get to a specific VC, use the 'chvt' command with the appropriate arg ================================================= X doesn't use inetd at all. It just listens for connections on port 6000, normally. You could block traffic to that port with IP firewalling, or on an external router. Or you could just use stronger authentication within the X server. Unless you're using XDM to run logins, you can just do that with by putting an .xserverrc file in your home directory: exec /usr/X11R6/bin/XF86_Mach64 -auth $HOME/.Xauthority -bpp 16 xrdb -merge $HOME/.Xdefaults xterm....whatever ...other xterm apps... fvwm95-2 & xscreensaver -cycle 1 -timeout 5 -lock -lock-timeout 15 & exec `color_xterm -C -title CONSOLE -name console -geometry 160x25+0+5 -bg DarkBlue -fg Gold -font 6x10` ================================================= Getting Xauthority properly setup is not difficult. The general picture of what's going on is: 1) Some program generates a magic cookie (arbitrary string) and writes this to a file. 2) The name of this file (often ~/.Xauthority) is passed to the X server. 3) The X server writes an entry for the DISPLAY into your ~/.Xauthority file. 4) Xlib reads ~/.Xauthority when you create a window, and passes the cookie value back to the X server. See your X11 init and control scripts (usually down under /etc/X11) for details. This is no hard stuff. To (re)synchronise the session key across hosts: xauth nlist $DISPLAY | rsh other.host xauth nmerge - Or just use SSH's X11 forwarding. ===== Importing a remote desktop session via ssh tunnel At home I have, 2 machines, one running Ubuntu 9.04 (Jaunty) and the other running Ubuntu 8.04 (Hardy). The Hardy machine is used by my family members and I use Jaunty for my experiments. Some times, I would like to test some thing on Hardy also. But most of the times that machine is not free. I use ssh to login to the hardy box and use an ssh tunnel to export the GUI session back to my Jaunty box. The steps I took are detailed below. ----- On Hardy box 1) Install open ssh server $sudo apt-get install openssh-server ----- On Jaunty Box 2) I switch to a text terminal by pressing Control+ALT+ F2. (any thing from F1 to F6 will work) 3) Login to the text terminal 4) Start a new session on Virtual Terminal 8 and launch xterm on it. $ xinit /usr/bin/xterm -- :1 ( :1 above represents the virtual graphical display , you can also use :2 ) 5) A gray screen with xterm will appear on virtual terminal 8. If it is not appearing you can switch to it by $ chvt 8 Or by pressing Control+Alt+f8 6) Now ssh to the Hardy box with tunneling. $ ssh -Y fermi@192.168.0.2 Give your credentials and login (The IP address above is that of my Hardy box, you can replace it with your user name and IP). You are now logged to Hardy. The GUI of any program launched on Hardy ( in this terminal) will be tunneled back to Jaunty via ssh. 7) Start a gnome session on Hardy by typing the following command in the xterm terminal. $ gnome-session You can start other desktop sessions like kde or xfce , if they are installed.