1. Yum Install–y tigervnc-server
2. Turn off SELinux
View status: Sestatus;
Temporary closure: Setenforce 0
Permanently closed: Vi/etc/sysconfig/selinux, modified to: selinux=disabled
After modification, reboot
3. Open the VNC SERVER in the firewall
4, the switch needs to Telnet users, set VNCPASSWD, this password is remote login password, can be inconsistent with the local password.
Su nctest
vncpasswd
5. Start Vncserver
Cd/usr/bin//Directory
Vncserver//Start
Several commands
Vncserver–list//View Links list
Vncserver–kill:1//Close link 1
6. The following steps set up VNC auto-start in CentOS7.
7. Su Root
cp/lib/systemd/system/[email protected] /etc/system/system/[email protected]
8, chmod +x [email protected]
9, vi/etc/system/system/[email protected]
10, modify the User name and window number, red circle position finally modified results.
If it is root, modify it to Pidfile=/root/.vnc/%h:1.pid
11. Set Boot Start
Systemctl enable [email protected]
12, reboot
13. Client Link:
Attention:
According to the online tutorial installed many times is the service can not start automatically, need to manually log on to the user, remote to link, or error failed to start Remote Desktop Service (VNC). After the following operation, can automatically start, the reason is unknown.
1, after installation, set VNCPASSWD, first start the next vncserver, will be in the user./vnc automatically generate several files
2, modify the file, a few red dots must be modified to.
3, CP [email protected] , chmod +x [email protected]
CentOS7.2 installation Tigervnc-server