Tuesday, November 6, 2012

Enabling VNC server on Linux

Enabling VNC server on Linux as 1,2,3

Enabling VNC server on Linux as 1,2,3 ( quick and dirty way)  for oracle user on RHEL/Fedora:
In this example i am only enabling oracle user
yum install tigervnc-server.x86_64 -y
Loaded plugins: refresh-packagekit, rhnplugin
Setting up Install Process
Resolving Dependencies
–> Running transaction check
—> Package tigervnc-server.x86_64 0:1.0.90-0.17.20110314svn4359.el6 will be installed
–> Finished Dependency Resolution
Dependencies Resolved
Package Arch Version Repository Size
tigervnc-server x86_64 1.0.90-0.17.20110314svn4359.el6 rhel-x86_64-server-6 1.1 M
Transaction Summary
Install 1 Package(s)
Total download size: 1.1 M
Installed size: 0
Downloading Packages:
tigervnc-server-1.0.90-0.17.20110314svn4359.el6.x86_64.rpm | 1.1 MB 00:00
Running rpm_check_debug
Running Transaction Test
Transaction Test Succeeded
Running Transaction
Installing : tigervnc-server-1.0.90-0.17.20110314svn4359.el6.x86_64 1/1
tigervnc-server.x86_64 0:1.0.90-0.17.20110314svn4359.el6
vi /etc/sysconfig/vncservers
remove everything and add:
# 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
# <URL:http://www.uk.research.att.com/archive/vnc/sshvnc.html>.
# Use “-nolisten tcp” to prevent X connections to your VNC server via TCP.
# Use “-nohttpd” to prevent web-based VNC clients connecting.
# Use “-localhost” to prevent remote VNC clients connecting except when
# doing so through a secure tunnel. See the “-via” option in the
# `man vncviewer’ manual page.
# VNCSERVERS=”2:myusername”
# VNCSERVERARGS[2]=”-geometry 800×600 -nolisten tcp -nohttpd -localhost”
VNCSERVERARGS[3]=”-geometry 1024×768 -depth 16″
save the file
VNCSERVERS=”3:oracle” – means vncsession for user oracle and port 5903
so in vncviewer you would connect as:
su – oracle
crate vncpasswd file:
service vncserver start ( as root)
Now you can connect via vncviewer using: my.host.com:5903 and user oracle


  1. I want to set up a vncserver on a generic/clean Centos or RH type Linux. I am working within the AWS EC2 infrastructure but that should not matter I believe.To make this effort succeed there are some prerequisites we need to help us run the vnc session i.e., X Windows.I've installed all the usual packages, facilitated by yum, and followed every bit of advice I can find on the internet. I have tried all the advices and tips on the internet about installing fonts, creating links, renaming x,y and z to no avail. How can I get it to work? what if i want to sync servers with tiger vpn? http://www.bestvpnservice.com/tigervpn/

  2. Very helpful suggestions that help in the optimizing website. Thank you for valuable suggestions.RealVNC Enterprise 6.1.1

  3. Very helpful suggestions that help in the optimizing website. Thank you for valuable suggestions.RealVNC Enterprise 6.1.1

  4. That is really appreciated! I am women and travel blogger also adventure-seeker, I Know how to travel the world safely - and I'm here to help you have the best trip ever with Indigo Travel diary. Go Get Connect.