Summary: These instructions show you how to install tightvncserver on your Raspberry Pi. Next, you’ll learn how to configure a remote.it Service that is compatible with tightvncserver so that you can easily connect to your Pi from outside of your local network using the OS X Safari browser.
- Devices: Raspberry Pi running the Raspbian operating system.
- Clients: Mac OS/X running the Safari browser.
Installing the tightvncserver Virtual Network Console service on your Raspberry Pi
In a terminal window on your Raspberry Pi, run the following commands:
sudo apt-get update
sudo apt-get install tightvncserver
Next, launch tightvncserver with the command:
tightvncserver will launch and ask you for a password, which you will use later for connection. You may also enter a different read-only password which will let you view the Raspberry Pi’s graphical desktop but not interact with it.
Next, confirm that tightvncserver is in fact running with the command:
ps ax | grep tightvnc
Next, check which port tightvncserver is listening on with the command:
sudo netstat -apn | grep tcp | grep LISTEN
This command will show all currently active tcp listeners (servers) running on your Raspberry Pi. Look for Xtightvnc in the list. There may be more than one entry. If so, choose the one with the lowest port number. Make note of this port number as you will need it in the next section where you will be adding the remote.it Service Attachment.
Adding a remote.it Service Attachment for tightvncserver
Run the remote.it configuration script:
At the Main Menu, install a new Weaved Service Attachment for VNC using the default port of 5901. Even if the port is not 5901, you will have the opportunity to change this during the installation.
When you’ve successfully installed tightvncserver and the remote.it tightvncserver Service Attachment, the Main Menu will include an entry for Xtightvnc as shown above.
Using OS/X Safari for VNC connections with remote.it
To connect, sign in to your remote.it account using your OS/X Safari browser and locate the Service you just installed in the Devices Page. My Device is called remoteit noob pi zero.
Click Connect, then click on the service name to initiate the connection. In a few seconds you’ll see a dialog box similar to this:
Copy the link which begins with “vnc://”. In a new tab, paste the link into the search bar. In a few moments you’ll see the Screen Sharing dialog. Click Allow.
When you see the password dialog, enter your VNC password and click on “Connect” to continue.
Now you are controlling your Raspberry Pi’s GUI!