In this Linux tutorial, you will learn, how to configure X11 Forwarding over SSH. #centlinux #linux #ssh
Table of Contents
Usually, Graphical mode is turned off in Linux servers due to Security and Resource optimization. In such environments running a GUI application is not a trivial task. However, we can use PuTTY and XMing to forward X11 display to a windows client over SSH protocol.
In this article, we will first install required packages on our Linux Server, then we will configure X11 forwarding over SSH on windows by using PuTTY and XMing.
One Microsoft Windows client and a Linux server.
Download and Install following two software on Windows client.
Install required packages on Linux server:
Connect to Linux machine and install necessary packages for X11 forwarding.
# yum install -y xauth
We will require a Linux GUI application to test X11 forwarding configurations. Therefore, we are installing xclock to test the configuration.
# yum install -y xclock
After installing Xming on Windows run xlaunch application.
Default configuration will work for us. Therefore, click on Next.
Click on Next.
Click on Next.
Click on Finish.
XMing application has been started and it is placed in System Tray of Windows.
Once installed, run PuTTY application.
Add a session of our Linux machine therein.
Besides other configuration, we are also required to configure X11 forwarding as follows:
Save and open the session.
login as: root Authenticating with public key "rsa-key-20190101" Last login: Tue Jan 1 21:16:23 2019 from 192.168.116.1 /usr/bin/xauth: file /root/.Xauthority does not exist # xclock
Xming will capture the Display open a window to run xclock application.
Conclusion – Configure X11 Forwarding over SSH:
In this Linux tutorial, you have learned, how to configure X11 forwarding over SSH by using PuTTY and XMing.