// pragmatic engineering

Setup and use VNC server

Article consists of two part: first part describes how to setup server and second is about client. In both cases TigerVNC will be used.

VNC server

Server is running on Linux (Ubuntu). First install required packages (JWM will be used as desktop environment):

$ sudo apt install tigervnc-standalone-server jwm

Then set password which client will use later to connect:

$ vncpasswd

On start TigerVNC will read configuration from the /etc/vnc.conf and then run script /etc/X11/Xvnc-session. Both files can be overridden with the corresponding files in the directory $HOME/.vnc. Possible content of those file is below (system files can be used as reference).

$HOME/.vnc/vnc.conf

$SecurityTypes = "VncAuth,TLSVnc";
$geometry ="800x600";

$HOME/.vnc/Xvnc-session (must be executable)

#!/bin/sh
vncconfig -nowin &
exec jwm

After configuration is in place server can be started with:

$ vncserver

VNC client

Under OS X client can be installed with brew:

$ brew cask install tigervnc-viewer

Interface is self-explanatory.

References