https://www.digitalocean.com/community/tutorials/how-to-install-and-configure-vnc-on-ubuntu-16-04
Step 1 — Installing the Desktop Environment and VNC Server
By default, an Ubuntu 16.04 Droplet does not come with a graphical desktop environment or a VNC server installed, so we'll begin by installing those. Specifically, we will install packages for the latest Xfce desktop environment and the TightVNC package available in the official Ubuntu repository.
On your server, install the Xfce and TightVNC packages.
- sudo apt install xfce4 xfce4-goodies tightvncserver
To complete the VNC server's initial configuration after installation, use the
vncserver command to set up a secure password.
- vncserver
http://mitchtech.net/vnc-setup-on-raspberry-pi-from-ubuntu/
Getting the IP address of the Raspberry Pi
The first step is to locate the Raspberry Pi on your network. If you have access to a display for your Raspberry Pi, this task is simple, in a terminal simply type:ifconfigAll the network interface configurations will be displayed, including the IP address. However, if you don’t have a display for your Raspberry Pi, this isn’t an option. For this task, we can use the Linux nmap (Network Mapper) utility.sudo apt-get install nmapThen run a scan on your local network. Be change to the specifics of your own network.nmap -sV -p 22 192.168.0.1-255The results will display every machine that could be identified on port 22. The Raspberry Pi (running Debian) looks something like this:Nmap scan report for 192.168.0.112 Host is up (0.033s latency). PORT STATE SERVICE VERSION 22/tcp open ssh OpenSSH 5.5p1 Debian 6+squeeze2 (protocol 2.0) Service Info: OS: LinuxConnecting over SSH
So we know that the Raspberry Pi has IP address: 192.168.0.112. Now we can ssh to it:ssh pi@192.168.0.112And you should receive a message like this:The authenticity of host ‘192.168.0.112 (192.168.0.112)’ can’t be established. RSA key fingerprint is xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx. Are you sure you want to continue connecting (yes/no)?Type yes at the prompt, then enter the password for the user pi, ‘raspberry’ by default. You should get a prompt that looks like this:pi@raspberrypi:~$Configuring VNC
Now that we have logged in to the Raspberry Pi, we can setup VNC for remote access. First we need to install the VNC server:sudo apt-get install tightvncserverNext, start the VNC server on the Raspberry Pi. Adjust the geometry paramater to your desired display size.vncserver :1 -geometry 1024x600 -depth 16 -pixelformat rgb565You will be prompted to create a password for VNC login. Once you do, you should see a line looking something like this:New ‘X’ desktop is raspberrypi:1Now, we can finally connect to the Pi with VNC. Back on the Ubuntu machine, install the VNC viewer client:sudo apt-get install xtightvncviewerThen connect to the running VNC server:vncviewer 192.168.0.112:5901To stop the VNC viewer, just close the application. To stop the VNC server, issue the following command (on the Raspberry Pi):
Comments
Post a Comment