Posts: 9
Joined: Tue Jun 12, 2012 10:24 pm

Remote Windows

Fri Jul 20, 2012 12:59 am

Could someone post the commands necessary to make the Raspberry Pi under Raspbian to display X remotely? Under the original Debian image you could submit:

sudo service gdm start (on the Raspberry Pi)
X :1 -query [RPi IP address] (on the remote system)

But I now get (under Raspbian):
gdm: unrecognized service

Any help greatly appreciated!

User avatar
Posts: 620
Joined: Fri Feb 03, 2012 7:18 pm
Location: San Carlos, CA
Contact: Website

Re: Remote Windows

Fri Jul 20, 2012 5:44 am

Looks like the original Debian Squeeze image may have included the Gnome Display Manager (gdm). The Foundation Raspbian image instead uses lightdm which, as its name implies, is a lightweight display manager which may not have the same capabilities as gdm. You should be able to uninstall lightdm and then install gdm, but off the top of my head I can't give you the specific sequence of commands that will make that happen for certain. If you can't figure it out, hopefully someone else has already done it and can tell you what you need to do.

User avatar
Posts: 147
Joined: Fri Jan 13, 2012 4:27 pm
Location: Haute-Vienne, France

Re: Remote Windows

Fri Jul 20, 2012 4:46 pm

According to Wikipedia, "LightDM offers at least the same functionality as GDM but it has a simpler code base and does not load any GNOME libraries to work"
So it might just work for you.

Posts: 106
Joined: Sat Apr 07, 2012 11:22 am
Location: Manchester, UK

Re: Remote Windows

Fri Jul 20, 2012 6:27 pm

Not sure what your exact requirement is but two possible solutions:

1) If you want to run individual X applications on the RPI with display & kbd & mouse on a remote linux desktop (where rpi = RPI ip address or hostname)
in a terminal:
chris@remote:~$ ssh -X rpi
(you will be prompted to login to the RPI, then for example to run an X file manager)
chris@rpi:~$ xfe
(the xfe file manager will be running on your remote desktop)

This is the method I use mostly. xfe is nice because it easily allows you to run further X applications on the RPI (beware: it is quite easy to forget which machine the applications are running on!). It also has the advantage of a secure connection.

2) If you want a X based login to the RPI with display of the RPI desktop on the remote then run a display manager on the RPI that allows XDMCP (I use xdm, as it is less bloated than gdm) and install an xserver like xserver-xephyr on the remote system. Then in a terminal:
chris@remote:~$ Xephyr :1 -fullscreen -once -query rpi

Note: i. this method will not give you a secure connection, but IMO is fine if just used within a wired home network
ii. on the RPI you will need to configure xdm to allow XDMCP (see: )

Posts: 271
Joined: Sun Feb 08, 2015 1:13 pm

Re: Remote Windows

Sat Mar 28, 2015 9:47 am

Although this a very old thread, so is X, so here goes....It might HELP someone. There is a lot of confusion about how to use X-windows (rdp, vnc, putty, xming, etc,etc) BUT if you are using Unix like systems it is not so complex. (the X-server is already running on your standard desktop, the x-client software is already in your pi, (even if you don't run startx)

I now use linux on all my pc's (Ubuntu Mint xfce) and the Pi's (Raspbian (Wheezy)). No Windows (and it isn't dark in here).

I have added the Avahi daemon to simplify addressing (ref: Bonjour) (the dot local bit) (I don't use fixed addresses and host tables any more.).

I use ssh to connect to my PI's (and other remote Linux's). so in a standard (Linux) terminal window
ssh -X -l pi pi-00.local
The -X is the important option... (must be uppercase (lowercase DISABLES the option)
- (you can also use -Y) - read the man page for ssh)

The filemanager is pcmanfm pcmanfm & the terminal fine. You can run most things directly from that. (the & spawns off the process so you can still use the terminal window) - a file manager window from my PI magically pops up on my Linux screen. I can move it about, resize it, etc.
When you exit, the window closes and the process in the pi finishes (usually cleanly - you might need an extra enter or ctrl-C sometimes)

NBBB Don't close the terminal window - everything goes through that... Oh! and I would certainly agree that it is easy to confuse which system each app window comes from!!

p.s. You do get some warning messages - I just ignore them if it works.
p.p.s. I edited the post to simplify how to do it.
p.p.p.s Sometimes you have to run pcmanfm& twice - I think it fails the first time because a file is missing - but it is created, so then subsequent attempts are ok. (I suspect this problem goes away in Jessie.)
ScreenshotLinux.png (53.41 KiB) Viewed 2293 times

Return to “Raspberry Pi OS”