CentOS7下部署vnc-server與win7安裝vnc-viewer

1、下載
https://www.realvnc.com/en/connect/
下點擊 Downlaod菜單 選擇VNC Server 之後選擇linux 選擇RPMx64(32位的選RPMx86)

下點擊 Downlaod菜單 選擇VNC viewer 之後選擇windows 選擇EXE x86x64


2、centOS7下安裝VNC-Server

#取得root權限
su root

#找到防止VNC-Server安裝包的位置
cd VNC-Server-xxx.RPM

#rpm安裝
[root@localhost vnc]# rpm -ivh VNC-Server-6.7.1-Linux-x64.rpm 
錯誤:依賴檢測失敗:
        xterm 被 realvnc-vnc-server-6.7.1.42348-1.x86_64 需要

#安裝VNC-Server需要xterm,安裝xterm
[root@localhost vnc]# yum -y install xterm
#安裝信息
...
#安裝成功

[root@localhost vnc]# rpm -ivh VNC-Server-6.7.1-Linux-x64.rpm 
#安裝信息
...
#安裝成功

#安裝許可
[root@localhost vnc]# vnclicense -add VKUPN-MTHHC-UDHGS-UWD76-6N36A
#VNC許可安裝成功信息
...

#啓動vncserver
[root@localhost vnc]# vncserver &
#後臺啓動VNC-Server服務相關信息
...

#將vnc-server添加到系統開機自啓服務
[root@localhost vnc]# systemctl start vncserver-x11-serviced.service
[root@localhost vnc]# systemctl enable vncserver-x11-serviced.service
#已添加到系統自啓服務中信息
...

[root@localhost vnc]# service vncserver-x11-serviced restart
Redirecting to /bin/systemctl restart vncserver-x11-serviced.service
[root@localhost vnc]# service vncserver-x11-serviced.service restart
Redirecting to /bin/systemctl restart vncserver-x11-serviced.service


#關閉firewall或添加5900-5905端口號

#方法1:關閉firewall
systemctrl stop firewalld
systemctrl disenable firewalld

#方法2:添加5900-5905端口
firewalll-cmd --permant --zone=public --add-port=5900-5905/tcp
firewall-cmd --reload
firewall-cmd --list-ports

#查看vnc服務
ss -lnp|grep 5900
#5900端口相關信息
...


3、win7安裝vnc-viewer
默認安裝即可

4、啓動vnc-viewer
輸入服務器IP地址
輸入用戶及密碼
...


 

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章