![]() |
forwarding X apps from N800 to desktop
Let me preface this post by saying that I know about vncserver on the n800, vncserver on the desktop and RDP. All work fine to and from n800 and desktop, but I'd like a single app to be remotely displayed
I'd like to forward an X11 app on the n800 to my local X server on my desktop. I've set up OpenSSH, made sure that X forwarding is on in /etc/ssh/sshd_config, and that an XDisplayOffset of 10 is set, and restarted the ssh server. I then ssh -X user@n800, but my $DISPLAY variable on the n800 is still 0.0, rather than 10.0, as it should be. Manually doing an export DISPLAY=':10.0' doesn't work either, nothing displays on my local X server. The other way around (ssh -X from n800 to desktop) and then running an app works fine. The DISPLAY variable (on desktop at that point) is properly set to 10.0, and I've compared the sshd_config files from n800 and desktop line-by-line, and they're identical for everything that should affect TCP and X forwarding. Is this a limitation with Matchbox and Hildon, or am I doing something stupid here? As I say, I know how to forward X connections over SSH normally, but this isn't working. |
Re: forwarding X apps from N800 to desktop
I can't even do "normal" (=non-SSH'ed) forwarding from the 770 to my desktop. It seems the applications on the 770 just ignore $DISPLAY
|
Re: forwarding X apps from N800 to desktop
Yeah, that's my take on it, too. Even if $DISPLAY is set, nothing happens - the app never loads, and I never get a prompt back w/o Ctrl+C
|
Re: forwarding X apps from N800 to desktop
mhm.... here the application does load/run, only it shows up on the 770 and not on the PC specified via DISPLAY. strange thing is I dont even get errors about not being able to connect to the display etc. ...
|
Re: forwarding X apps from N800 to desktop
Little more testing.... It seems to depend which app it is. If I run vncviewer, gpe-calendar, pwsafe, fmradio, and most others, they launch and display on the n800 (this is with ssh -X, and DISPLAY still as 0.0).
browser and mediaplayer-ui, on the other hand, don't launch, and just drop back to a shell. Now, after manually setting $DISPLAY to 10.0 (export DISPLAY=':10.0') during the same SSH session, fmradio fails with Gtk - cannot open display:, as do pwsafe and gpe-calendar. Vncviewer just returns to a prompt, no error. The browser and mediaplayer-ui just return to a prompt also, no error. So, it appears that $DISPLAY is honored, at least by most apps, but something else is going on to prevent them from using it. Edit: This is all as user, no "sudo su" or ssh -X root@n800 that could be confounding. |
Re: forwarding X apps from N800 to desktop
I'm not sure... Try the following:
On your GNU/Linux desktop PC, type DISPLAY=10.0.0.126:0; xterm; echo $DISPLAY (with 10.0.0.126 being a non-existent IP-address) The output will be something like: xterm Xt error: Can't open display: 10.0.0.126:0 10.0.0.126:0 Which tells me that xterm tries to open the display. Now, on a N800 or 770, do the same (do it on the device itself, dont ssh into the tablet): DISPLAY=10.0.0.126:0; /usr/bin/osso-xterm; echo $DISPLAY Again, 10.0.0.126 doesn't exist. What happens is that the application starts, without any error. After you close it again, you'll find that "echo" still prints the expected line 10.0.0.126:0 so we know $DISPLAY contains what we said it should and didn't magically return to :0.0 I don't have the applications installed you tried, but I used xchat, the calculator etc., and they all never throw an error. they just start up as if nothing had happened - as if they wouldn't read $DISPLAY at all. |
Re: forwarding X apps from N800 to desktop
OK, testing as you said above:
xterm launches, echoes DISPLAY browser (opera) launches, echoes the DISPLAY I set fmradio - doesn't launch, w/GTK+ can't open display <IPADDR> vncviewer - doesn't launch, no GTK error, echoes DISPLAY gpe-calendar - doesn't launch w/GTK+ can't open display <IPADDR> pwsafe - doesn't launch w/GTK+ can't open display <IPADDR> So, some apps do honor $DISPLAY and some don't? Am I interpreting that right? But, even if they honor it, they won't export over SSH. |
Re: forwarding X apps from N800 to desktop
This is getting too technical for me now; I always thought that this X feature is handled be the X framework itself and not by each single application.
Maybe Xomap simply doesn't support this feature at all? I tried to search google for further information about Xomap and remote X displays, but didn't find anything useful except: Quote:
Maybe one of the developers could tell us more. |
Re: forwarding X apps from N800 to desktop
Thanks for the thread pointer. I'll put this on the back burner for now I guess!
|
Re: forwarding X apps from N800 to desktop
I just installed winaxep (http://www.labf.com/winaxeplus/index.html) on a MS Windows XP machine, then used their "telnet_ssh" to ssh to my N800 (with openssh installed). After "export DISPLAY=192.168.xxx.yyy:0" (the windows machine's IP address) and then "leafpad", the leafpad main window opened up on the XP desktop! Same for mirage (picture viewer from garage) and claws-mail. I was really surprised after all those failed trials to forward X-apps from the n800 to my linux desktop!! However, there where no window borders and menus were accessible via alt-f4 only. Nevertheless it's a starting point...
|
Re: forwarding X apps from N800 to desktop
Don't have a windows box available at the moment, but I tried the "export DISPLAY=10.x.x.x:0" on my linux box, and still no joy. $DISPLAY shows that the variable is set right, but it still won't show up.
|
Re: forwarding X apps from N800 to desktop
> The output will be something like:
> xterm Xt error: Can't open display: 10.0.0.126:0 > 10.0.0.126:0 This is easy: Your X client (i.e. the application, like xterm for example) does not have permissions to open the screen on the X server. On the X server, do a "xhost +" (no quotes) This will allow permissions for ANY client to open the display. Still, the DISPLAY variable has to be correctly set like this on the X client side: export DISPLAY=192.168.192.1:0.0 (As a side not, when talking X windows....everything seems "reversed" (aparently), the server is the display and the client are the actual applications, like xterm, xeyes, and others.) Hope this helps. |
Re: forwarding X apps from N800 to desktop
With openSuSE 10.2 I also did "xhost +". No problem from another linux box to the target linux box, but no luck with n800. But with the windows X server it works! There is some deeper problem, but I have neither further ideas nor enough time...
|
Re: forwarding X apps from N800 to desktop
Quote:
The error is expected because 10.0.0.126 doesn't exist on the network. ("xhost +" was done before, also x was started without any xauth-magic that could add additional trouble.) The unexpected and interesting part of the game is that you don't see this error on the 770. Mind you, even if xhost/xauth/... setting were all correct, the IP-address doesnt exist, there's no way to open a display on the remote machine. Still, there's no error and the application runs locally. |
Re: forwarding X apps from N800 to desktop
Quote:
|
Re: forwarding X apps from N800 to desktop
Quote:
Do not log into the N800 via telnet/ssh/whatever from the windows machine but run the "DISPLAY=192.168...." stuff locally in the N800s xterm. From a pure X point of view, this should be the most straightforward way of using a different display. It also corresponds to the setup I tried. The thing when you log in to your N800 remotely is that the remote connection may provide a fake 2nd 'local' display to the N800. "Fake local" means that it looks like a 2nd local display to the N800 but is secretly forwarded to the PC your connection originates via ssh. In this case we're making things more complex which doesn't help finding the cause of the problem. I have reason to believe that the N800 actually ignores whatever IP-address is set in the DISPLAY-variable and only honors the part after the ":". It would be interesting to check this. (It can also be that theres a difference between my 770 and your N800 in this respect after all...) |
Re: forwarding X apps from N800 to desktop
Quote:
|
Re: forwarding X apps from N800 to desktop
Hmmm... I'll try to set $DISPLAY on the n800 xterm, rather than SSH.
But! Remember that xhost+ is a bad idea, except in a controlled environment! Xauth is the way to go, but is a little more complex. The beauty of SSH forwarding is that it is supposed to handle the $DISPLAY variables and "faking" xauth, but in this case it's not working under Xorg's X server, but is working under a Windows X server. Very strange. |
Re: forwarding X apps from N800 to desktop
Quote:
|
Re: forwarding X apps from N800 to desktop
Quote:
BTW: when running suse, did you try to eliminate all sorts of X security stuff such as xauth? it could well be that the two X environments (windows and GNU/linux) are not configured equally... |
Re: forwarding X apps from N800 to desktop
Same problem here. Would't it be beautiful if there was a NXserver for the N900?
|
Re: forwarding X apps from N800 to desktop
forget about X forwarding for the moment. I got it working (on KDE systems you have to edit ServerArgsLocal= in /etc/kde/kdm/kdmrc), but half of the apps don't work and the other half is not very interesting.
YMMV. |
Re: forwarding X apps from N800 to desktop
Quote:
xhost+ on the desktop machine and export of DISPLAY on N900 does not help. |
All times are GMT. The time now is 15:44. |
vBulletin® Version 3.8.8