3

http://www.instructables.com/id/Setting-up-a-VNC-Server-on-your-Raspberry-Pi/step4/Setting-up-the-Pi-to-Automatically-Start-a-VNC-Ser/

I have seen various tutorials explaining the exact process in the link above but I can't for the life of me work out why I can't get it to work.

VNC server works great if I manually boot it up with sudo vncserver.

I have created the specified autostart folder and inside of it placed a file called vncserver.desktop.

Inside that file there is the following information:

[Desktop Entry]
Type=Application
Name=TightVNC
Exec=vncserver:1
StartupNotify=false

Can anyone help?

My Raspberry Pi has been updated to the latest version by using:

sudo apt-get update

sudo apt-get dist-upgrade

After updating, I tried to run RealVNC but it didn't work so I am not sure it was installed after doing the upgrade process? Hence, I installed tightVNC.

1

Found an easier solution.

sudo apt-get install xrpd
sudo reboot

Problem solved. Using Microsoft Remote Desktop works perfectly on boot. Easy.

I imagine though that some people will say it is better to go with VNC but I am not sure why?

  • The primary advantage to VNC is that you get the desktop and don't need to worry about reconnecting to virtual sessions. But that is easily fixed by going into /etc/xrdp and editing the xrdp.ini file so the first session says "ask5910" instead of -1 - side effect is that for your first session you do need to manually change the 5910 to -1 upon login. Afterwards it will default to 5910 so you will reconnect. – SDsolar Oct 1 '17 at 3:08
1
 apt-get update
 apt-get upgrade
 apt-get dist-upgrade

after finish

sudo raspi-config 

then go to Interfacing Options then select vnc and enable it and reboot enjoy your vnc server running on boot

  • This works great. Note that any other vnc servers will be removed at this step (like vnc4server) - but press on and it all works out OK. Plus, the ~/.vnc/passwd file is not reset so you still have the same login password. And with this answer it will now work with all clients - both Windows TightVNCviewer and Linux remmina. – SDsolar Oct 1 '17 at 3:10
1

Dropped ":1" from the above and it worked the next time i booted ....

  • 3
    Why did this help solve the problem? Your answer may give a valid solution, but without further context it's not particularly helpful. – Jacobm001 Feb 26 '18 at 2:51
0

This seems like a very clumsy way of starting VNC (requiring you to boot to GUI - which seems to kind of defeat the purpose).

See Start VNC on Jessie at boot which I use to start TightVNC.

If you are just starting with VNC you might try RealVNC which is now included in Raspbian. See PIXEL

  • I have been following this guide: – Chumboski Oct 16 '16 at 16:27
  • elinux.org/RPi_VNC_Server – Chumboski Oct 16 '16 at 16:27
  • Ooops. Messed up on the comments there!! Followed this guide: elinux.org/RPi_VNC_Server and made sure I had updated and upgraded so running Pixel. Still can't seem to get tightvnc to boot automatically. At present, I have to ssh in, manually run the server and then use vnc viewer to boot up into desktop mode. – Chumboski Oct 16 '16 at 16:29
  • @Chumboski I tried that guide a couple of years ago and never got it to work (although others have). It is rather dated, and a systemd service would be more appropriate on Jessie. Do you have a Raspbian, pre-PIXEL or is it a new installation (which includes RealVNC)? RealVNC & TightVNC cannot co-exist. – Milliways Oct 16 '16 at 23:06
  • @Chumboski PS if you have followed the elinux guide, that makes your original question meaningless. You should post any updates into your question, not Comments. – Milliways Oct 16 '16 at 23:08

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.