I have installed Vnc server in debian server.
I want to know how to set a new port for VNC, how to autostart VNC server at the bootup,How to check that the VNC server is running, where error logs are located
how we can set the KDE graphical environment to be started when X server is launched.
Pls reply !!!!!.
There are two ways to change the ports for your vncservers. You can specify the port when you start the server:
This starts a server on 5904.
Or, you can edit the config file: /etc/sysconfig/vncservers. Here is mine:
This allows you do specify the users and ports for any number of vncservers.
# The VNCSERVERS variable is a list of display:user pairs.
# Uncomment the lines below to start a VNC server on display :2
# as my 'myusername' (adjust this to your own). You will also
# need to set a VNC password; run 'man vncpasswd' to see how
# to do that.
# DO NOT RUN THIS SERVICE if your local area network is
# untrusted! For a secure way of using VNC, see
VNCARGS="-geometry 1280x1024 -depth 16 -alwaysshared"
I haven't configured debian startup files, but a little research tells me that adding a link in
Go ahead and look around in there. The startup script for vncserver (at least in redhat) is in /etc/init.d/ .
The answer to your last questions is all in the same directory: ~/.vnc . If you look in there, you should see "xstartup". You can edit this to determine which desktop environment loads for the vncserver. For example:
The "startkde &" will give you a KDE environment. If you comment that, and uncomment /usr/bin/fluxbox, then you get fluxbox. I leave both in there so I can switch easily.
# 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" &
When you start vncserver, it creates two files in your ~/.vnc directory, <hostname><port>.pid and <hostname><port>.log. So, if your hostname is "host" and the vnc port is 5904, you get:
The pid file contains the process information about the server, and the log is, well, a logfile.
Hope that helps.