Difference between revisions of "How to use X applications remotely"

From Salix OS
Jump to: navigation, search
m

Revision as of 11:43, 13 May 2011

If you have several computers running Salix you can access one from another using seral methods. Some of them are described below:

Contents

X forwarding via SSH

Configure the server

enable X forarding by uncommenting the following line in /etc/ssh/sshd_config:

X11Forwarding yes

make sure ssh daemon is restarted and running:

service restart sshd

if you want sshd to run at boot:

chmod a+x  /etc/rc.d/rc.sshd

Connect to the server

Just login via ssh from any Linux machine able to run X using -X or -Y option (difference among them not clear to me):

ssh -Y user@server application_name

like this:

ssh -Y jack@192.168.1.2 thunar

Thunar will be executed on machine with IP 192.168.1.2 but the display will be forwarded to the client`s X server.

Or just log in, then run the desired application from command line like this:

 ssh -Y jack@192.168.1.2

then type thunar

Via XDMCP

XDMCP states for X Display Manager Control Protocol and uses UDP port 177.

Configure GDM on the server

In order to use XDMPC one has to configure Gnome Display Manager by editing /etc/gdm/custom.conf in [xdmcp] section to have:

[xdmcp]
Enable=true
Port=177

Restarting GDM is required. Root can do this by init 3; init 4 combination:

init 3
init 4

Log in via GDM on the remote server

X -query servername :display

This might look like this:

X -query 192.168.1.2 :1

Option :0 for display is usually already claimed so :1 or higher will be needed to work. One has to realize that XDMCP authenticates unencrypted and if snooping is possible, leaves the system vulnerable to attack. It is more secure to use an ssh tunnel for X traffic.