So I tried to do 'xhost +' on his machine and then ran xeyes from my machine giving his machine's IP address in the -display option, but it didn't work! Trawling the web, I found that Ubuntu had tightened things up:
http://davesource.com/Solutions/20070912.Ubuntu-xhost.html
This solution works for gdm users, but my colleague and I both run kdm (kde4) to control acces to X. So here's the expanded instructions:
- Edit /etc/X11/xinit/xserverrc:
Remove (or comment out) the "-nolisten tcp" - Edit /etc/X11/kde4/kdm/kdmrc:
Find the line 'ServerArgsLocal = -br -nolisten tcp and comment out the '-nolisten tcp' bit. - Log out of X (GNOME or KDE) and log back in again (this should restart the kdm or gdm process).
My machine's IP is 192.168.0.10 and my colleagues is 192.168.0.20. On my colleague's machine, having done the above he opens a command line and issues:
% xhost +
On my machine, I open a command line and issue:
% xeyes -display 192.168.0.20:0.0
And xeyes appears on his screen!