How to enable remote access via TCP connection (X Server)

Renan
  11 years ago
  8

There are two ways to enable the remote access via TCP connection in Linux Mint 14 Nadia.

Changing the mdm.config

It is possible directly change the mdm.config localized in /etc/mdm/mdm.config.

$ cd /etc/mdm/

In order to modificate the mdm.config, first it is necessary to open it as superuser:

$ sudo vi mdm.config

or

$ sudo pluma mdm.config

After that, the following instruction should to be added bellow the tag [security]:

DisallowTCP=false

Then, save the modificated file and restart the session.

Running the mdmsetup

It is also possible change the mdm.config running the mdmsetup. For that, run the command as superuser

$ sudo mdmsetup

In the security tab, disable the field Deny TCP connections to the X server and close the window.

The mdm.config will be automatically modificated.

Exporting display

In the local machine enable the server as xhost:

$ xhost server_ip (or xhost servername)

Access the server via ssh:

$ ssh username@server_ip (or ssh username@servername)

Export display to the local machine:

$ export DISPLAY=local_ip:0.0

Testing:

$ xclock

or

$ xterm

Security

Be aware about the security of your system by enabling TCP connections.

Comments
jahid_0903014 10 years ago

nice


Hammer459 11 years ago

Very good.


sujitnag 11 years ago

good