Linux Remote Desktop (Remote Desktop) Control

Source: Internet
Author: User
Tags pcanywhere

What I want to talk about here is not remote control tools such as telnet and RSH, but remote control of desktop applications.

X Window is more advanced than MS Windows. X Window is a network-based graphical Windows System with powerful remote control functions. log on to the remote system and run the X application. Then, the xclients execution result is returned to the local host. this is the remote X

I. remote X

Assume that the local host IP address is 172.16.1.1 and the remote host IP address is 172.16.1.2.

Step 1: Execute xhost in any xterm on the local host to allow remote hosts to connect to the X server on the local host:

Xhost + 172.16.1.2

If you do not specify any IP address, it means that the permission is completely open, which may cause security problems. Be careful!

Step 2: Check whether the XFS of the local host is running. Use PS to check the process.

Step 3: log on to the remote host 172.16.1.2 through the network on the local host (172.16.1.1). You can use Telnet, ssh, or rsh to set the DISPLAY variable.

Export display = 172.16.1.1: 0

Step 4: Now you can use the X application on the remote host.

This is convenient, but you still have no control over the entire desktop environment. You can leave this job to VNC! Remote X works very well on the LAN. You don't need to try dialing a common phone. The speed is too slow.
  
Ii. VNC

I believe many people have used pcAnywhere in windows, but do not want to use a free pcAnywhere which can be used in Linux, Win9x/NT. This is VNC.

VNC is short for vitual network computing. It supports many operating platforms and can even be operated in browsers.

I will introduce the usage of vncviewer and use Linux to remotely control Linux or NT.

The VNC client communicates with the VNC server through the VNC protocol in the TCP/IP architecture. After authentication, the desktop environment, input devices, and X resources of the X server are handed over to the vncserver for control, the VNC server sends the desktop environment to the VNC client through the VNC protocol. allows the VNC client to manipulate the VNC Server desktop environment and input devices.

First download to the Linux and Windows versions of VNC.

The current Linux version is vnc-3.3.3r1_x86_linux_2.0.tgz

The current Windows environment is vnc-3.3.3r7_x86_win32.zip.

1. Install VNC for Linux
(1) Installation

Tar zxvf vnc-3.3.3r1_x86_linux_2.0.tgz
CD vnc_x86_linux_2.0
Cp * VNC */usr/local/bin/
Mkdir/usr/local/VNC
CP-r classes // usr/local/VNC/

(2) set the VNC server access password

Vncpasswd

(3) Start the VNC Server

Vncserver

Note the information displayed after running, and write down the port number, generally starting from 1, because 0 is occupied by X server. now you can provide the VNC service. VNC client usage will be introduced.

2. Install VNC for NT
1) Installation
After the vnc-3.3.3r7_x86_win32.zip package is released, two directories, WinVNC and vncviewer, are generated. the WinVNC directory contains the installation program of the VNC Server, and the vncviewer directory contains the installation sequence of the VNC client. I only care about the VNC server. simply execute setup in the WinVNC directory.

2) settings
First Run install default registry settings.
Run WinVNC (APP mode) is to execute VNC Server
At this time, you can see the small icon running WinVNC, right click the icon, set the password in properties/incoming connections. The default configuration is enough.
Now, your NT can provide the VNC service.

3. Use vncviewer

After the VNC Server is started successfully, you can use vncviewer to remotely control the desktop.

Vncviewer XXX. XXX: Display number

For example, vncviewer 172.16.1.2: 1

Enter the password as required to view the Remote Desktop.

Note: viewers must work in 16-bit display mode. If your operating system does not have 16-bit color, adjust the display mode of your computer in time. Otherwise, vncviewer cannot work normally.

4. Improvement of VNC Server for Linux.

The Desktop Management Environment set by the VNC Server on Linux is TWM, which is too simple.
Modify the $ home/. VNC/xstartup file.
Add # To the front of all content rows, and add the following at the end:
Startkde &
Of course, you can replace it with your preferred desktop. I use KDE to replace TWM, and the speed will be slower, but it is much more convenient to use.
Note that you must restart the VNC server.

5. Use VNC in a browser

When using VNC in a browser, pay attention to the changes in the port number.
If the VNC Server is 172.16.1.2: 1, you can access http: // 172.16.1.2: 5801 using a browser.
Port Number = display number + 5800
Well, the heart is better than action, just do it!

Previous Article: installing and configuring DHCP service for Linux/Unix
Next article: three cool Linux skills

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.