Tuesday, 20 May 2014

How to enable X11 forwarding in ssh session,how to do it in putty and why EXPLAINED!

What is X11? This is X Server for Linux. In simple words, it is graphical enviroment.

What is X11 forwarding? This means that you can connect on remote server trough ssh session and run services with graphical enviroment that are running on that remote server.

How to acomplish this through ssh session?

server1#ssh -X server1

Now that you are connected, easiest way to test if X11 forwarding is enable is to start xclock.
xclock is graphical clock.


xclock window should appear.

Of course this means that you have graphical enviroment on server1 and server2.

Now for connection through putty...
Putty is client for ssh and telnet connection. It is used for ssh connection from windows machine to Linux servers.
To enable X11 forwarding, you have to install Xming. Xming is X Server for Window.
Step are:
1. Install Xming
2.Start Xming
3.Start putty
   After entering IP address or hostname of server that you want to connect, you have to enable X11   forwarding.

And that is it.

Test X11 forwarding by starting xclock.

Why do we need X11 forwarding? Some applications need graphical enviroment for installation, sometimes you need it to troubleshot something.

I hope this will help you!

No comments: