1748275 Members
3786 Online
108761 Solutions
New Discussion юеВ

X11 forwarding

 
SOLVED
Go to solution
Kwahae_1
Regular Advisor

X11 forwarding

Hi all,

Has anyone used the X11 forwarding of PuTTY to connect to a Linux X-server? I would like to use the graphics options of CENTOS Linux from a PuTTy connection. What special configurations do I have to carry out on the PuTTy menu and host Linux box?

Thanks
7 REPLIES 7
Steven E. Protter
Exalted Contributor

Re: X11 forwarding

Shalom,

ssh -X hostname gnome-terminal

Might do the job.

The last part is optional but gets me X windows based programs via an encrypted tunnel.

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
Rob Leadbeater
Honored Contributor

Re: X11 forwarding

Hi,

I've never used this, but the section on X11 forwarding in the PuTTY manual looks to be self explanatory...

Have you tried to do it ?

Cheers,

Rob
roth_4
New Member

Re: X11 forwarding

Hi,

PuTTY does only do half of the job. It only forwards the X11-packets trough a ssh-'tunnel'. For displaying any X11-applications on your Microsoft Windows-box, you need a X-server-software for Microsoft Windows, e.g. the XLiveCD ( http://xlivecd.indiana.edu ) do the job, with the purpose of not needing to install anything on your Windows-box, just use X from CD-ROM.

Regards
Sven
roth_4
New Member

Re: X11 forwarding

... I forgot:
perhaps cygwin ( http://www.cygwin.com ) will be an alternative solution, but you have to install cygwin on your Microsoft Windows-box.
(XLive CD comes with cygwin running from CD-ROM.)

Regards
Sven
Matti_Kurkela
Honored Contributor
Solution

Re: X11 forwarding

If you're running PuTTY on a Windows workstation, you need an X server software running on your Windows machine first.

(X11 terminology is slightly confusing:
"X server" = the software that actually draws things on the screen and gets keyboard and mouse actions from the user.
"X client" = an application that wants to present a GUI interface using X11 technology.)

ReflectionX is a good commercial X server software for Windows, but if you need a free alternative, you could use Cygwin-X:
http://x.cygwin.com/

The procedure is generally as follows:
1.) Start X server software on the local host, if it isn't running yet. If it presents a connection dialog, *ignore* it.

2.) Start PuTTY, enable X11 forwarding option and connect to your Linux host. On the first time, you may see a message like:
/usr/bin/X11/xauth: creating new authority file /home//.Xauthority
This is normal.

3.) Now you can start any graphical program from the PuTTY prompt. Use a simple and easily identifiable X11 program, e.g. xclock, to test. The window should appear on your screen.

If you need the entire desktop environment (not just a single GUI program), you'll need to know the command that starts the main process of the desktop in question. For the Gnome-style desktop, the command is usually "gnome-session"; for KDE, it's "startkde".

MK
MK
Yogeeraj_1
Honored Contributor

Re: X11 forwarding

hi,

You can simply do:

ssh -Y user@servername


for XDMCP, you will need to run the gdmsetup and enable the XDMCP box in the XDMCP tab.

Also, don't forget to open TCP port 6000-6005 and UDP port 177 to accept incoming connections from any host. For Gnome, you should open TCP ports 16001 and 35091 in both directions.


hope this helps too!
kind regards
yogeeraj
No person was ever honoured for what he received. Honour has been the reward for what he gave (clavin coolidge)
Kwahae_1
Regular Advisor

Re: X11 forwarding

Thanks all.

Started X-server and then enabled PuTTy's X11 forwarding. All is well now.