1. 安裝gonme核心包(若是字符界面)
apt-get install x-window-system-core
apt-get install gnome-core
apt-get install metacity
apt-get install gnome-desktop-environment (optional)
2. 安裝 vnc4server
apt-get install vnc4server
3. 設(shè)置vncserver密碼
vncpasswd
4. 啟動VNC server
vncserver
5. 關(guān)閉 (:1表示5901端口)
vncserver -kill :1
6. 修改~/.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 &
7. 在服務(wù)器端退出gnome,否則客戶端登錄會出現(xiàn)字符界面。
sudo /etc/init.d/gdm stop
?著作權(quán)歸作者所有,轉(zhuǎn)載或內(nèi)容合作請聯(lián)系作者
【社區(qū)內(nèi)容提示】社區(qū)部分內(nèi)容疑似由AI輔助生成,瀏覽時請結(jié)合常識與多方信息審慎甄別。
平臺聲明:文章內(nèi)容(如有圖片或視頻亦包括在內(nèi))由作者上傳并發(fā)布,文章內(nèi)容僅代表作者本人觀點(diǎn),簡書系信息發(fā)布平臺,僅提供信息存儲服務(wù)。