RHL配置VNC Server
RHL配置VNC Server
0. 啟動vncserver服務
[root@localhost ~]# service vncserver status
Xvnc 已停
[root@localhost ~]# service vncserver start
啟動 VNC 伺服器:no displays configured [確定]
1. 開啟vncserver服務端
[root@localhost ~]# vncserver :1
You will require a password to access your desktops.
Password:
Verify:
New 'localhost.localdomain:1 (root)' desktop is localhost.localdomain:1
Creating default startup script /root/.vnc/xstartup
Starting applications specified in /root/.vnc/xstartup
Log file is /root/.vnc/localhost.localdomain:1.log
2. 修改vnc顯示方式
預設情況下是shell,下面設定使用xwindows方式登入到遠端linux,將預設的twm &註釋掉,增加一行gnome-session &,使用的是GNOME桌面,還有KED方式:startkde&。
[root@localhost ~]# vi /root/.vnc/xstartup
[root@localhost ~]# cat /root/.vnc/xstartup
#!/bin/sh
# Uncomment the following two lines for normal desktop:
# unset SESSION_MANAGER
# exec /etc/X11/xinit/xinitrc
[ -x /etc/vnc/xstartup ] && exec /etc/vnc/xstartup
[ -r $HOME/.Xresources ] && xrdb $HOME/.Xresources
xsetroot -solid grey
vncconfig -iconic &
xterm -geometry 80x24+10+10 -ls -title "$VNCDESKTOP Desktop" &
# twm &
gnome-session &
如果要立即生效連線桌面方式,需要重啟服務:
[root@localhost ~]# vncserver -kill :1
Killing Xvnc process ID 8135
[root@localhost ~]# vncserver :1
檢視下監聽狀態:
[root@localhost ~]# netstat -tulnp
3. 在客戶端連線
192.168.2.203:5901 http://192.168.2.203:5801
4. 配置vncserver自啟動
[root@localhost ~]# chkconfig --list vncserver
vncserver 0:關閉 1:關閉 2:關閉 3:關閉 4:關閉 5:關閉 6:關閉
[root@localhost ~]# chkconfig --level 2345 vncserver on
[root@localhost ~]# chkconfig --list vncserver
vncserver 0:關閉 1:關閉 2:啟用 3:啟用 4:啟用 5:啟用 6:關閉
修改開機啟動服務程式
[root@localhost ~]# vi /etc/sysconfig/vncservers
[root@localhost ~]# cat /etc/sysconfig/vncservers
# The VNCSERVERS variable is a list of display:user pairs.
#
# Uncomment the lines below to start a VNC server on display :2
# as my 'myusername' (adjust this to your own). You will also
# need to set a VNC password; run 'man vncpasswd' to see how
# to do that.
#
# DO NOT RUN THIS SERVICE if your local area network is
# untrusted! For a secure way of using VNC, see
# <URL:http://www.uk.research.att.com/archive/vnc/sshvnc.html>.
# Use "-nolisten tcp" to prevent X connections to your VNC server via TCP.
# Use "-nohttpd" to prevent web-based VNC clients connecting.
# Use "-localhost" to prevent remote VNC clients connecting except when
# doing so through a secure tunnel. See the "-via" option in the
# `man vncviewer' manual page.
VNCSERVERS="1:root"
VNCSERVERARGS[1]="-geometry 1024x768"
-The End-
0. 啟動vncserver服務
[root@localhost ~]# service vncserver status
Xvnc 已停
[root@localhost ~]# service vncserver start
啟動 VNC 伺服器:no displays configured [確定]
1. 開啟vncserver服務端
[root@localhost ~]# vncserver :1
You will require a password to access your desktops.
Password:
Verify:
New 'localhost.localdomain:1 (root)' desktop is localhost.localdomain:1
Creating default startup script /root/.vnc/xstartup
Starting applications specified in /root/.vnc/xstartup
Log file is /root/.vnc/localhost.localdomain:1.log
2. 修改vnc顯示方式
預設情況下是shell,下面設定使用xwindows方式登入到遠端linux,將預設的twm &註釋掉,增加一行gnome-session &,使用的是GNOME桌面,還有KED方式:startkde&。
[root@localhost ~]# vi /root/.vnc/xstartup
[root@localhost ~]# cat /root/.vnc/xstartup
#!/bin/sh
# Uncomment the following two lines for normal desktop:
# unset SESSION_MANAGER
# exec /etc/X11/xinit/xinitrc
[ -x /etc/vnc/xstartup ] && exec /etc/vnc/xstartup
[ -r $HOME/.Xresources ] && xrdb $HOME/.Xresources
xsetroot -solid grey
vncconfig -iconic &
xterm -geometry 80x24+10+10 -ls -title "$VNCDESKTOP Desktop" &
# twm &
gnome-session &
如果要立即生效連線桌面方式,需要重啟服務:
[root@localhost ~]# vncserver -kill :1
Killing Xvnc process ID 8135
[root@localhost ~]# vncserver :1
檢視下監聽狀態:
[root@localhost ~]# netstat -tulnp
3. 在客戶端連線
192.168.2.203:5901 http://192.168.2.203:5801
4. 配置vncserver自啟動
[root@localhost ~]# chkconfig --list vncserver
vncserver 0:關閉 1:關閉 2:關閉 3:關閉 4:關閉 5:關閉 6:關閉
[root@localhost ~]# chkconfig --level 2345 vncserver on
[root@localhost ~]# chkconfig --list vncserver
vncserver 0:關閉 1:關閉 2:啟用 3:啟用 4:啟用 5:啟用 6:關閉
修改開機啟動服務程式
[root@localhost ~]# vi /etc/sysconfig/vncservers
[root@localhost ~]# cat /etc/sysconfig/vncservers
# The VNCSERVERS variable is a list of display:user pairs.
#
# Uncomment the lines below to start a VNC server on display :2
# as my 'myusername' (adjust this to your own). You will also
# need to set a VNC password; run 'man vncpasswd' to see how
# to do that.
#
# DO NOT RUN THIS SERVICE if your local area network is
# untrusted! For a secure way of using VNC, see
# <URL:http://www.uk.research.att.com/archive/vnc/sshvnc.html>.
# Use "-nolisten tcp" to prevent X connections to your VNC server via TCP.
# Use "-nohttpd" to prevent web-based VNC clients connecting.
# Use "-localhost" to prevent remote VNC clients connecting except when
# doing so through a secure tunnel. See the "-via" option in the
# `man vncviewer' manual page.
VNCSERVERS="1:root"
VNCSERVERARGS[1]="-geometry 1024x768"
-The End-
相關文章
- openEuler 配置VNC ServerVNCServer
- Centos搭建VNC serverCentOSVNCServer
- VNC遠端控制軟體:VNC Server for MacVNCServerMac
- VNC Server for Mac(VNC遠端控制軟體)VNCServerMac
- VNC安裝配置VNC
- How to Install and Configure VNC Server in CentOS 7VNCServerCentOS
- Ubuntu 20.04 安裝VNC Server的教程。UbuntuVNCServer
- vnc遠端控制軟體,vnc遠端控制軟體怎麼使用,vnc server如何安裝?VNCServer
- vnc管理工具,vnc管理工具安裝使用教程,linux如何安裝vnc server?VNCLinuxServer
- VNC Server for Mac(VNC遠端控制軟體) v6.11.0啟用版VNCServerMac
- Ubuntu Server安裝介面並VNC連線UbuntuServerVNC
- VNC安裝配置詳細說明VNC
- CentOS 8.2下VNC安裝與配置CentOSVNC
- CentOS使用配置VNC遠端連線CentOSVNC
- CentOS 7 配置 VNC 遠端桌面連線CentOSVNC
- AIX6.1下安裝及配置VNCAIVNC
- 樹莓派安裝vnc server並設定自啟動樹莓派VNCServer
- RedHat Linux 6企業版開啟VNC Server遠端桌面RedhatLinuxVNCServer
- VNC,什麼是VNC,如何使用VNC?VNC
- Windows Server安全配置WindowsServer
- VNC,VNC連線操作!VNC
- Windows server 2012 R2配置NTP ServerWindowsServer
- VNC,VNC軟體下載!VNC
- VNC, VNC viewer使用方法!VNCView
- centOS5.5配置vnc,開啟linux遠端桌面CentOSVNCLinux
- SQL SERVER 2008安全配置SQLServer
- Swoole server配置選項Server
- VNC連線,VNC如何連線WindowsVNCWindows
- VNC,VNC遠端不了如何解決?VNC
- Windows Server 2012配置MySQL 8.0.20 MGRWindowsServerMySql
- Docker安裝配置Seata-ServerDockerServer
- VNC,Linux遠端VNC連線伺服器!VNCLinux伺服器
- vnc viewer西西軟體,vnc viewer西西軟體推薦,vnc客戶端使用教程VNCView客戶端
- 安裝vncVNC
- VNC遠端控制,VNC遠端控制連線WindowsVNCWindows
- vnc登入,4個vnc登陸的軟體VNC
- vnc使用教程,vnc使用教程的7個步驟VNC
- VNC viewer 西西軟體,除了VNC viewer 西西軟體,其他好用的VNC軟體下載!VNCView
- 如何在 Centos 8 / RHEL 8 上安裝和配置 VNC 伺服器CentOSVNC伺服器