Use xming, xshell to display linux gui to windows desktop (x11 forwarding)
Firstly, download xming, install it on your windows pc system.
You can go to http://sourceforge.net/projects/xming/files/ to download.
After installation xming on your windows, log in linux/solaris server 192.168.0.3. Set environment variable DISPLAY to the ip address of your windows, and append a :0 to it:
Then you must allow X11 forwarding in sshd configuration file. That is, set X11Forwarding to yes in /etc/ssh/sshd_config and restart your sshd daemon.
After this, you need set 192.168.0.3(linux/solaris) to the allowed server list on your windows. Edit X0.hosts which locates at the installation directory of xming(For example, C:\Program Files\Xming\X0.hosts), add a new entry in it:192.168.0.3, the ip address of linux/solaris that you want to run x11 utility from.
Then, restart xming on your windows. And on solaris/linux server(192.168.0.3), run a X11 programe, like
You will then see a clock gui pop up in your windows pc.
Amazing, isn’t that?
You may need install xorg-x11-xauth on X11 client side also(on which x11 should be executed). To enable X11 in putty, you can refer to the following: http://www.math.umn.edu/systems_guide/putty_xwin32.html
PS: Something from xshell x11 faq:(Actually, this step is not necessary to our goal)
X11 forwarding is a bit different from other TCP/IP port forwarding.
Please, go through the following steps.
- To enable X11 forwarding service in Xshell: On the Tunneling tab of Advanced SSH Options dialog box, check Forward X11 Connections To. and select Xmanager if Xmanager is installed in your PC. If you use another PC X server, select X Display Location and enter the proper display name.
- To enable X11 forwarding service in the SSH server: Setup the configuration file in the following table.
SSH server Config file Setup OpenSSH /etc/ssh/sshd_config X11Forwarding yes SSH.COM /etc/ssh2/sshd2_config AllowX11Forwarding yes
- To run X11 applications from the Xshell terminal:
- If Xmanager is installed on your PC, just go to the next step. Otherwise, run the PC X server installed on your PC first.
- Start the SSH connection with the session enabling X11 Forwarding.
- At the shell prompt of Xshell, execute the X11 applications like the following examples:[nathaniel@intranet ~]$ xterm &
[nathaniel@intranet ~]$ startkde &
[nathaniel@intranet ~]$ gnome-session &