Connect to VNC server

You can now use any VNC client to connect to your new Ubuntu VNC server. This guide will use the xvnc4viewer client.

To install xvnc4viewer on your Ubuntu client system run:

$ sudo apt install xvnc4viewer

Once you have your VNC client installed you can establish a new connection to your VNC server with a host name eg. ubuntu-vnc-server using the following linux command:

$ vncviewer ubuntu-vnc-server:1

Enter your password created previously as part of the above "Ubuntu VNC server setup" section.

If all went well, you will be presented with a Xfce4 desktop session running on the remote VNC server Ubuntu system:

Established VNC connection to Ubuntu 18.04 VNC server.

Note, it is also possible to run a secure VNC client/server connection via the SSH tunnel. Given that you have the SSH user access (in this case username linuxconfig is used) to your VNC server eg. ubuntu-vnc-server.

First, create an SSH tunnel on a local port 5901 leading to a remote port 5901 on your VNC server.

Example:

$ ssh -L 5901:127.0.0.1:5901 -N -f -l linuxconfig ubuntu-vnc-server

The above command will open a local port 5901 on a localhost loop-back network interface 127.0.0.1:

Once you have the file opened insert the following lines while replacing the linuxconfig username with username of your VNC user on Line 7 and Line 10. Optionally, change screen resolution settings and apply other vncserver options or arguments:

You may also be interested in:

Comments and Discussions

SUPPORT US

LinuxConfig.org team is determined to provide you with simple to follow Linux tutorials, various tips, tricks and programming guides as well as with GNU/Linux system administration tutorials in general to help you to learn Linux faster and use it with ease.

Donations

Bitcoin (BTC) Address:1PyYJEVtxkokkYtLkRw9BA7Fr4xEAXJn3U

Litecoin (LTC) Address:LXvDNUcdKuh3Svge358rNanXfXMKcPkxCo

Thank You

Write For Us

LinuxConfig is looking for a technical writer(s) geared towards GNU/Linux and FLOSS technologies. Your articles will feature various GNU/Linux configuration tutorials and FLOSS technologies used in combination with GNU/Linux operating system.

When writing your articles you will be expected to be able to keep up with a technological advancement regarding the above mentioned technical area of expertise. You will work independently and be able to produce at minimum 2 technical articles a month.