Vnc Server configuration on Red Hat Enterprise Linux

Posted in RED HAT LINUX, SERVERS by edeguzman on April 6, 2009

I just installed and configure the VNC server on my Red Hat Enterprise Linux.  I had read alot of tutorials on the configuration of VNC server on a Red Hat Enterprise and based on the different tutorials that I read I come up with the more precise and short tutorial.

By default the vnc-server is already installed but still it depends on how you install your Red Hat Enterprise.  On my installation of RHEL, I did the standard installation.

The first thing you do is to verify the vnc-server on the system whether its already installed or not.  Below is one way to verify. This will query for any vnc-server package installed on the system.

rpm -q vnc-server

If no package is found on your system, then install it through RHEL cd packages.

On your home directory .vnc folder can be found and a file xstartup inside the .vnc folder. Edit the xstartup file and uncomment the below statements.

exec /etc/X11/xinit/xinitrc

Issue the command ;            vncserver :1

The above command will create an instance of vncserver and you can access that instance through a vnc client.  ( e.g vncviewer )

To verify if the vncserver is already issue the command :

netstart -tulpan | grep vnc


service vncserver status

To close the instance of vncserver use the below command :

vncserver -kill :1

If you want to run the vncserver on boot up. Edit the file /etc/sysconfig/vncservers and specified socket number with the username under VNCSERVERS.

VNCSERVERS = “1:myusername_1 2:myusername_2”

Then use the command below :

chkconfig –level 5 vncserver on

That would be all guys. This works on me and hopefully this will word for you too. Cheers =)


Leave a Reply

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

You are commenting using your account. Log Out /  Change )

Google+ photo

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

Twitter picture

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

Facebook photo

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

Connecting to %s

%d bloggers like this: