Install VNC Server on RedHat


默认VNC已经安装在RedHat服务器上了。如果没有安装可以通过下面的命令安装。
# rpm –i vnc-server-4.1.2-14.el5_3.1.i386.rpm

下面开始配置VNC服务,简单几步就可以搞定了。

修改# vim /etc/sysconfig/vncservers
NCSERVERS=”1:用户名”
VNCSERVERARGS[1]=”-geometry 800×600 -alwaysshared”

在vnc用户shell环境中执行vncpasswd设置vnc用户的密码
$ vncpasswd

修改vnc用户目录下的~/.vnc/xstartup文件,使vnc用户远程连接的时候能够看到桌面(Gnome或者KDE)。
# Uncomment the following two lines for normal desktop:(解开下面两行注释)
unset SESSION_MANAGER
exec /etc/X11/xinit/xinitrc

启动VNC服务
# /sbin/service vncserver start

测试一切OK之后使用ntsysv命令配置vncserver为自动启动服务。

Advertisements

发表评论

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / 更改 )

Twitter picture

You are commenting using your Twitter account. Log Out / 更改 )

Facebook photo

You are commenting using your Facebook account. Log Out / 更改 )

Google+ photo

You are commenting using your Google+ account. Log Out / 更改 )

Connecting to %s