I've googled alot about this and can't find a way to do this (or if it's even possible) I want to log a user on a remote machine in his X session (Gnome) from a ssh in a windows machine with PuTTY.

Note: I do not want to view in windows the remote desktop, just pass the login screen in the remote computer so i can open things there like XBMC and so on. Auto-login is not an option.

Thanks in advance.

Edit: Ok, let's meet the scenario. It isn't exactly like that but may help understanding the thing. Let's say i have a computer on the lower floor, wired to a TV on the upper floor, and also have a infrared reveiver there with his controller. How can i start let's say a XBMC, w/o go to the lower floor. Just with a laptop (or smartphone maybe) in the upper floor. The computer is such a multipurpose (and has many users) so autologin is not a choice.

  • You mean you want the application to launch on the monitor of the remote machine?
    – ewanm89
    Apr 16, 2012 at 14:10
  • yes that is, but before run anything there, i must log in the desktop, or the monitor just show the login screen Apr 16, 2012 at 14:17
  • @jack-all-trades And once you launch how would you interact with that window?
    – Karlson
    Apr 16, 2012 at 14:26
  • With my phone, with a IR Remote controller... or i can start a vnc Apr 16, 2012 at 14:33
  • I edited the question. Apr 16, 2012 at 15:00

2 Answers 2


If you log in with ssh, it seems hard to re-log in with Gnome, and more harder to display the entire desktop from a Windows computer.

That's why similar questions on askubuntu or superuser advices to use others and more appropriate protocols like VNC, XDMCP or FreeNX.

  • If you have sufficient bandwidth, you can encapsulate vnc protocol in a ssh tunnel.
  • If you don't, you can encapsulate freeNX protocol in a ssh tunnel.

IF you really need to take the hard path, you'll need to install a local X server on your windows computer and find a way to launch gdm remotely within this X server.

  • VNC may do it, but i dont know hot to start the service before logging in. Encapsulate it will be better, the bandwidth i hope is ok becouse is in LAN :) So how can be done that? any graphic thing seems to fail becouse it says that cant found the display Apr 16, 2012 at 14:39
  • Just do an ssh port forward.
    – ewanm89
    Apr 16, 2012 at 16:46

I'm using this script at the momment

    export DISPLAY=:0.0
    sudo xhost +
    /usr/lib/vino/vino-server #here i can manually login in the dektop with vnc
    sudo xhost -
    /usr/lib/vino/vino-server &

Seems to be an ugly solution, but is the only thing i found to log in the desktop remotely. I still thinking that must be another way, but i post this and hope someone find it usefull.

Any improvement would be appreciated.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .