Installation and simple configuration of Linux VNC server
Abstract: installation, simple configuration, and use of Linux vnc server. This article is only applicable to common users (for example, users who have installed Linux in virtual machines), but does not care about network security. If you need to use it on the internet, you 'd better use VPN or SSL or wrap the vnc communication. Enable the firewall and configure related conditions. These tutorials will be issued later.
Demo environment:
Virtual Machine: VMware 10
System: rhel-server-6.3
Yum Source: Local CD image
Note: This article only meets the vnc server needs of common users and does not focus on network security. Therefore, first disable the firewall to avoid network errors (unable to connect ). Also, make sure that the yum source has been configured.
1. Open the terminal and run the yum command to install vnc sever.
Command: yum install tigervnc-server-y
2. Set vncserver to start with the system.
Command: chkconfig vncserver on
Or: chkconfig vncserver -- level 5 on
3. modify the configuration file of the vncserver.
Command: vim/etc/sysconfig/vncservers
4. configuration file. Figure marked yellow
": Wq" is to save and exit, not the content in the configuration file.
5. Set the vncserver password (used to log on to the vnc client ).
Note: Before setting the password, su to the user you want to set. This demonstration uses the root user.
Command: vncpasswd
6. Restart the vncserver service.
Command: service vncserver restart
7. If FAILED occurs, it is generally because the configuration file is wrong. If the problem persists after the check and the error prompt is similar, the cause is the version. Install or update x11.
Command: yum install pixman-devel libXfont-y
Note that X in libXfont is in uppercase.
8. Restart the vncserver service again after the installation is complete.
Command: service vncserver restart
This time there should be no unexpected green OK.
(In this step, if an error prompt is displayed, there is no need to exist, and I do not like the error ..)
9. Connect to the vnc in Windows. There is no suspense in the installation of vnc.
After installation is complete.
Enter the Linux ip address and the colon desktop number in the Vnc service, and the number indicated by the arrow.
Click connect for next step
10. Do not explain. Next step.
11. OK. It should be connected without any accident. Then you can perform various operations like on the local machine. Of course, if you restart the vncserver service, you still need to reconnect.
After writing it, let's look back. Aha, it feels a little cool.
In the beginning, this article is only applicable to common users (for example, Linux users installed in virtual machines), and does not care about network security. If you need to use it on the internet, you 'd better use VPN or SSL to log in or package vnc communication. Enable the firewall and configure related conditions.