Configure VNC Server for NAT Forwarding

VNC server typically listens on 5900+ port ranges depending on the number of your display (e.g. :1 is 5901), this is suitable for the dedicated IPv6 addresses but is not suitable for the Shared IPv4 Forwarded addresses.

To be able to have the VNC connectable from the Shared IPv4 address we need to changeĀ /usr/bin/vncserver as root (or sudo) with an updated listening port.

In this example the VPS is assigned, thus the ports allowed are 11400-11420.

Find the line:

$vncPort = 5900 + $displayNumber;

and change to:

$vncPort = 11400 + $displayNumber;

This would then have screen/display :1 on 11401 on the Shared IPv4 Address.
  • 0 Users Found This Useful
Was this answer helpful?

Related Articles

How To: SSH into a IPv4 NAT / IPv6 based VPS

1. Find the Shared IPv4See here for finding the shared/public IPv4. 2. Check your SSH forwarding...

Find your IPv4 NAT Instance Public IPv4 Address

1. Cheat SheetYour Public IPv4 Address on a NAT based instance can be found by checking your...

Install OpenVPN on a NAT Server

In this guide we will cover how to install OpenVPN on a NAT based VPS.Now we have a new NAT VPS,...

Enable FUSE on NAT OpenVZ

FUSE permissions can be enabled from within the management portal, select 'VPS Configuration'...