From Outrun Wiki
Jump to: navigation, search


LightVNC is a service for Red Hat (and compatible) Linux (version 6) that provides a minimal vnc service based on openmotif, xdm, xinetd and tigervnc-server.

An introduction can be found here: Dirty Cache - Featherweight Linux VNC services


How to install:

  1. Set up the Outrun Extras YUM repository (if you haven't already done this)
  2. Install the "lightvnc" package:
    yum install lightvnc
  3. If you run firewall (iptables) then open port 5900 and optionally 5901 and 5902
  4. Connect using a VNC client to <hostname|ip>
  5. Login as any non-root user


# Man page:
man lightvnc

# Info:
cat /usr/share/doc/lightvnc/README

Persistent Desktop

A persistent desktop is a desktop that keeps your session alive if you disconnect.

# Setting the password for persistent desktops to 'secret':
vnc-setpass topsecret

# Check which vnc services are enabled
chkconfig |grep vnc

# enable lvnc-1 (this by default is the persistent desktop)
chkconfig enable lvnc-1

Now connect on <hostname|ip>:1 or <hostname|ip>::5901

Enabling or disabling desktops

Enabling/disabling persistent and/or nonpersistent VNC services:

# List vnc services
chkconfig --list --type xinetd | grep vnc

# Enable/disable vnc-0 on port 5900
chkconfig lvnc-0 off
chkconfig lvnc-0 on

# Same for (persistent) vnc-1 on port 5901
chkconfig lvnc-1 off
chkconfig lvnc-1 on

Changing the resolution

Changing the default LightVNC resolution:

Edit the file /etc/sysconfig/lightvnc

Default contents:

# LIGHTVNC[0]="-geometry 1280x1024"
# LIGHTVNC[1]="-geometry 1024x768"

Uncomment the VNC console you want to change and set the resolution to what you prefer. For Console 0:

LIGHTVNC[0]="-geometry 1280x1024"

For the static console you must kill any existing session to make the new settings active:

chkconfig lvnc-1 off
chkconfig lvnc-1 on