In some cases it is very useful to access Raspberry pi directly and control the desktop. We’ll see in this post how to perform VNC installation.
1. Get connected to raspberry pi via ssh terminal
2. Run the command below:
sudo apt-get install tightvncserver
3. TightVNC will ask you to enter a password which will be used for authentication. You’d better notice this password somewhere since it will be used each time you want to access the raspberry pi via VNC.
4. Run the below command in the terminal window to start the vnc server.
vncserver :1 -geometry 1920x1080 -depth 24
you may change the screen size that is given as 1920×1080 above.(example: 800×600)
5. Now we install the vnc viewer to access raspberry pi.