fedora8上安装配置VNC

fedora8上安装配置VNC

1.检查本机是否安装了VNC
>rpm -q vnc vnc-server

[root@cd5 .vnc]# rpm -q vnc vnc-server
package vnc is not installed
package vnc-server is not installed

2.install vnc
>yum -y install vnc-server
Installed:
  vnc-server.x86_64 0:4.1.2-24.fc8                                                                                                 

Dependency Installed:
  vnc-libs.x86_64 0:4.1.2-24.fc8                                                                                                   

Complete!

3.configuration
>cd /etc/sysconfig
>vi vncservers
VNCSERVERS=" 1:root"
VNCSERVERARGS[1]="-geometry 800x600 -nolisten tcp"
set password.
>vncpasswd

4.start and manager the server
>/etc/rc.d/init.d/vncserver start
>/etc/rc.d/init.d/vncserver restart

[root@cd5 sysconfig]# /etc/rc.d/init.d/vncserver start
Starting VNC server: 1:root
New 'xxxx:1 (root)' desktop is xxxxxx:1

Starting applications specified in /root/.vnc/xstartup
Log file is /root/.vnc/xxxxx:1.log

[  OK  ]

>cd /root/.vnc
>vi xstartup
#!/bin/sh

[ -r $HOME/.Xresources ] && xrdb $HOME/.Xresources
xsetroot -solid grey
vncconfig -iconic &
xterm -geometry 80x24+10+10 -ls -title "$VNCDESKTOP Desktop" &
#twm &
exec gnome-session &

>/etc/rc.d/init.d/vncserver restart
[root@cd5 .vnc]# /etc/rc.d/init.d/vncserver restart
Shutting down VNC server: 1:root [  OK  ]
Starting VNC server: 1:root
New 'xxxxx:1 (root)' desktop is xxxxxx:1

Starting applications specified in /root/.vnc/xstartup
Log file is /root/.vnc/xxxxxx:1.log

[  OK  ]

check if the vncserver is running
>netstat -an | grep 01
[root@cd5 .vnc]# netstat -an | grep 01
tcp        0      0 0.0.0.0:5801                0.0.0.0:*                   LISTEN     
tcp        0      0 0.0.0.0:5001                0.0.0.0:*                   LISTEN     
tcp        0      0 0.0.0.0:5901                0.0.0.0:*                   LISTEN  

error report 1:
Couldn't open RGB_DB '/usr/X11R6/lib/X11/rgb'

error opening security policy file /usr/X11R6/lib/X11/xserver/SecurityPolicy


Fri Oct  8 16:20:10 2010
vncext:      VNC extension running!
vncext:      Listening for VNC connections on port 5901
vncext:      Listening for HTTP connections on port 5801
vncext:      created VNC server for screen 0
error opening security policy file /usr/X11R6/lib/X11/xserver/SecurityPolicy
Could not init font path element /usr/X11R6/lib/X11/fonts/misc/, removing from list!
Could not init font path element /usr/X11R6/lib/X11/fonts/Speedo/, removing from list!
Could not init font path element /usr/X11R6/lib/X11/fonts/Type1/, removing from list!
Could not init font path element /usr/X11R6/lib/X11/fonts/CID/, removing from list!
Could not init font path element /usr/X11R6/lib/X11/fonts/75dpi/, removing from list!
Could not init font path element /usr/X11R6/lib/X11/fonts/100dpi/, removing from list!

solution:
>mkdir /usr/X11R6
>mkdir /usr/X11R6/lib
>cd /usr/X11R6/lib
>ln -s /usr/share/X11 X11

references:
http://www.kklinux.com/html/Love-Linux/Fedora/200808/12-272.html
http://bbs.chinaunix.net/thread-368552-1-1.html


你可能感兴趣的:(html,linux,Security,防火墙,bbs)