export X traffic back to laptop
I have checked and double checked that 'xhost' is set properly on my laptop and that I am exporting my remote display back to my laptop (mobile-1). No can do. This is an entry level process I know, but it doesn't work. I checked my firewall settings and in fact turned it off.
When issuing 'echo $DISPLAY' on mobile-1, I receive ":0.0
When issuing 'who' on the remote server after logging in, I don't see mobile-1. I see mobile-1.local?
I cannot even 'su -' to root on mobile-1 and export my display.
A quick reply would be greatly appreciated.
Thx!,
Brian
[713 byte] By [
t8knit2al] at [2007-11-25 22:33:36]

# 1
Assuming that your laptop and the server can communicate via IP and the names can be resolved.
On the laptop, run "xhost +".
On the server, run "export DISPLAY=[IP of laptop]:0". That is a colon in front of the letter zero.
Run the Xapp on the server and it should start on the laptop.
I am doing this successfully on SJDS on a gateway PC and running Xapps on my Sun servers.
# 3
LOCAL = computer where you want to view the display (e.g. laptop)
REMOTE = computer where you run the program (e.g. server)
- substitute LOCAL & REMOTE for the host names or IP addreses of your computers.
1) Make sure the LOCAL and REMOTE computers can see each other
e.g.
on LOCAL computer ping REMOTE computer. Make sure you get a response.
on REMOTE computer ping LOCAL computer. Make sure you get a response.
Unless pings are blocked on your network :)
2) Allow remote displays on your LOCAL computer
xhost +REMOTE
e.g.
xhost +<servername> or xhost +<ip address>
3) Find the current display on your LOCAL computer
echo $DISPLAY
e.g. you should get a display number like :0.0
4) Set the Display on the REMOTE server.
Login to the REMOTE server
Before you run the application export your display
The exact command will depend on the shell you are using (echo $SHELL to check).
e.g.
for tcsh
setenv DISPLAY LOCAL:0.0
for ksh or sh
export DISPLAY=LOCAL:0.0
5) Run your application in the same shell as you just expored the display
--
Alternatives
- If you can't get this working then use SSH to connect to your REMOTE server from your LOCAL laptop.
Make sure that on the REMOTE server in the sshd_config:
X11Forwarding yes
X11DisplayOffset 10
Make sure that on the LOCAL client in the ssh_config:
ForwardX11 yes
Then it should be automatic.
Hope you find this info useful.