Friday, February 5, 2010

How to install VNC server on Fedora

to install it:
yum install vnc-server

as root edit /etc/sysconfig/vncservers
VNCSERVERARGS[3]="-geometry 1024x768 -depth 16"

with this configuration, vnc server will listen on port 5903 for user yourusername
to setup a multiple vnc server:
VNCSERVERS="1:username1 2:username2 3:username3"
VNCSERVERARGS[1]="-geometry 1024x768 -depth 16"
VNCSERVERARGS[2]="-geometry 800x600 -depth 8"
VNCSERVERARGS[3]="-geometry 800x600 -depth 16"

in this case vncserver ill listen on ports 5901 (for username1), 5902 (for username2) and 5903 (for username3).

to set the password, login as user, then:

start the service as root with /etc/init.d/vncserver start

as user edit /home/yourusername/.vnc/xstartup
and uncomment the following lines:
exec /etc/X11/xinit/xinitrc

and restart the service as root: /etc/init.d/vncserver restart

now you'll be able to connect from a vnc client at your_vnc_server_hostname:590x

No comments: