Linux開機啟動VNCserver Debian開機啟動VNC: www.2cto.com 啟動VNC並設定:startjwm & firefox --display=:1 設定VNC開機啟動vim /etc/init.d/vncserver Sehll代碼 ### BEGIN INIT INFO # Provides: vncserver # Required-Start: $remote_fs $syslog # Required-Stop: $remote_fs $syslog # Default-Start: 2 3 4 5 # Default-Stop: 0 1 6 # Short-Description: Start daemon at boot time # Description: Enable service provided by daemon. ### END INIT INFO PATH="$PATH:/usr/X11R6/bin/" # The Username:Group that will run VNC export USER="root" #${RUNAS} # The display that VNC will use DISPLAY="1" # Color depth (between 8 and 32) DEPTH="16" # The Desktop geometry to use. #GEOMETRY="x" GEOMETRY="800x600" #You Can Choice GEOMETRY="1024x768" && GEOMETRY="1280x1024" # The name that the VNC Desktop will have. NAME="Vncserver" OPTIONS="-name ${NAME} -depth ${DEPTH} -geometry ${GEOMETRY} :${DISPLAY}" . /lib/lsb/init-functions case "$1" in start) su ${USER} -c "/usr/bin/vncserver ${OPTIONS}" ;; stop) su ${USER} -c "/usr/bin/vncserver -kill :${DISPLAY}" ;; restart) $0 stop $0 start ;; esac exit 0 添加許可權chmod +x /etc/init.d/vncserver使配置生效update-rc.d vncserver defaults添加計劃任務,定時重啟vnc或者系統,以防止firefox假死不出分crontab -e CentOS開機啟動VNC: 1.配置vnc /etc/sysconfig/vncservers 2.shift+g 移到最後插入下面的代碼 [code="SHELL"]VNCSERVERS="1:root"VNCSERVERARGS[1]="-geometry 800x600"3.設定vnc自動啟動 chkconfig vncserver on 4.安裝flash外掛程式 wget http://blog.firetry.com/soft/libflashplayer.so mkdir -p ~/.mozilla/plugins cp libflashplayer.so ~/.mozilla/plugins/ 5.下載vagex 外掛程式,youtube最佳化外掛程式 wget http://vagex-debian.googlecode.com/files/youtube_video_quality_manager-1.2-fx.xpi