系统环境安装的是centos 5 32位
检测系统XFCE版本
yum grouplist
安装XFCE 4.4版本
yum groupinstall xfce-4.4
在安装过程中会出现两次」Is this ok [y/n]」我们只需要输入y且回车就可以
安装VNC桌面系统
yum install vnc vnc-server
同样的,在过程中有一次我们看到」Is this ok [y/n]」我们只需要输入y且回车就可以
配置VNC系统及分辨率
vi /etc/sysconfig/vncservers
在内容最后添加
VNCSERVERS=」1:root」
VNCSERVERARGS[1]=」-geometry 1024×768″
ESC,:wq,保存退出
设置VNC密码
vncpasswd
输入两次VNC密码
启动VNC系统环境
vncserver
修改xstartup配置文件
vi /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 80×24+10+10 -ls -title 「$VNCDESKTOP Desktop」&
#twm &
startxfce4 &
设置权限以及重启VNC/设置开机启动
chmod +x ~/.vnc/xstartup
service vncserver restart
chkconfig vncserver on
安装FireFox浏览器
yum -y install firefox
支持简体中文设置
yum -y install fonts-chinese
连接VNC,登录测试。