Jump to Navigation

141- How to set up VNC

Virtual Network Computing (VNC) is a graphical desktop sharing system that uses the RFB protocol to remotely control another computer.
It transmits the keyboard and mouse events from one computer to another, relaying the graphical screen updates back in the other direction,
over a network.

1. Edit /etc/sysconfig/vncservers as root

   Uncomment the line:

2. chkconfig vncserver on

3. su to the user that you will be logging in as

4. Run vncpasswd and set the password

# vncpasswd

5. Now run vncserver. This will create the needed initialization files

# service vncserver start
(service vncserver stop)

   New 'X' desktop is localhost.localdomain:1  <---- Display 1

6. Edit /home/user/.vnc/xstartup and uncomment the two lines there to get a normal desktop when you log in

7. Kill the Xvnc task and delete the lock files in the .vnc directory

# vncserver -kill :1

If you have a problem, you can delete display 1.

8. VNC Files

Several VNC-related files are found in the directory $HOME/.vnc:

    A shell script specifying X applications to be run when a VNC desktop is started. If it doesn't exist,
    vncserver will create a new one which runs a couple of basic applications.
    The VNC password file.
    The log file for Xvnc and applications started in xstartup.
    Identifies the Xvnc process ID, used by the -kill option.

9. Connect from the remote machine using servername:1

* Download
* Install
* IP:<display #>
   Enter Password

Main menu 2

Story | by Dr. Radut