[HowTo] Install a vnc server on the Raspberry pi


#369

It is working now! For some reason the files you mentioned earlier messed up and kept failing to install properly.


#370

A year ago I followed this instruction and on my old install SD and it worked.

https://github.com/patrikolausson/dispmanx_vnc/archive/master.zip

Now with new install I can run but somehow I cannot make it run at the startup. Any time I want to VNC to my Pi I have to use putty, login start server and keep putty open. I checked my Rc.local file and it has the line

/home/osmc/dispmanx_vnc-master/dispmanx_vncserver &

but it seems it’s not doing anything. Anytime I want to run the VNC server I have to SHH to my Pi, login and issue command:

cd /home/osmc/dispmanx_vnc-master/
sudo ./dispmanx_vncserver'

If I try sudo make I get the last line:

    cd /home/osmc/dispmanx_vnc-master/
    sudo make
    make: Nothing to be done for 'all'

What am I doing wrong?


#371

Hi,

I thinking the instructions have changed since you first done, its now using systemd unit file, rather rc.local. Please reread the first post.

Thanks Tom.


#372

yup, you gotta start fresh,
Just to be sure first do:

sudo systemctl stop dispmanx_vncserver.service
sudo systemctl disable dispmanx_vncserver.service
sudo systemctl daemon-reload

then

cd /home/osmc
rm -rf dispmanx_vnc-master/

Then do the guide again from scratch. Even the .conf file has some differences since then. Better erase the content and repaste the new settings that are there in the guide.


#373

Silly question, what is the username if I am using a password? I’ve tried: “osmc”, “root”, and blank, and it always disconnects me telling me invalid user/password.

If I remove the password, I am able to connect without authentication.

Thanks @fzinken
I got the problem sorted out. Not sure if the problem was RealVNC’s “quick connect”, or if manually adding a profile for it was the solution, but now when I log it the username box is grayed out and it accepts my password fine.


#374

VNC doesn’t use a username. So if your client has such a field leave it empty.


#375

I just retired my five-year old Pi in favour of a shiny new Vero 4k. I used VNC a lot previously but the instructions here don’t work on the Vero. To be more specific, there is a clash between libraries. This doesn’t really surprise me and I see lots of discussion on such matters throughout this thread, but I haven’t found the answer. It may well be there in the 360+ posts. If so, I missed it and apologise. The closest I can find is Sam’s post #163 mentioning a process for the Vero and possibly an app-store version. Did this progress further?

dpkg-divert: error: ‘diversion of /etc/kernel-img.conf to /etc/kernel-img.conf.distributed by rbp-userland-osmc’ clashes with ‘diversion of /etc/kernel-img.conf to /etc/kernel-img.conf.distributed by vero3-userland-osmc’
dpkg: error processing archive /var/cache/apt/archives/rbp-userland-osmc_2.9.0-1_armhf.deb (–unpack):
subprocess new pre-installation script returned error exit status 2


#376

This hasn’t progressed for the time being!

Don’t try to install Raspberry Pi packages on the Vero

Check this thread for VNC on Vero4k


#377

Thanks for that. Sadly that method also has a library/dependency problem:
sudo apt-get install libvncserver0
Reading package lists… Done
Building dependency tree
Reading state information… Done
Package libvncserver0 is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source
However the following packages replace it:
libvncclient1:arm64 libvncclient1

I tried installing those instead but then get (no surprise…):

/usr/bin/aml-vnc

/usr/bin/aml-vnc: error while loading shared libraries: libvncserver.so.0: cannot open shared object file: No such file or directory


#378

That because it’s compiled for Jessie, I can compile one for Stretch and update the link, but it wont be with mouse support since that lags terrible. Here you go:

wget https://github.com/zjoasan/vnc-vero3/raw/master/aml-vnc
chmod +x aml-vnc
sudo cp aml-vnc /usr/bin

#379

This worked for me

  sudo apt-get install libvncserver-dev
  ./aml-vnc

#380

@joakim_s that versions seems responsive but has a strange issue compared to your older jessie version (which was still working on stretch). Sometimes after going into a menu the screen is not redrawn till you press a button.


#381

Okey working on it, was awhile since i looked at this source, cant get it to navigate through remote keyboard at all. Might be the same bug as my RF keyboard wont work after reboot, untill i remove and insert doongle.Allthough it refresh the screen if i touch a key. Running the latest leila.


#382

Brilliant! and so easy for me…
Many thanks Joakim


#383

Hi
i did a complete reinstall,
but still have:
“RFB protocol error: bad xrle data.”
any idea?


#384

Which Client are you using? Have you tried another Client?


#385

VPN running? Might have something to do with MTU-settings


#386

Hi,
Is this supported on Ubuntu? I am receiving the error

g++ -Wall -std=c++11 -O3 -DHAVE_LIBBCM_HOST -DUSE_EXTERNAL_LIBBCM_HOST -DUSE_VCHIQ_ARM -I/opt/vc/include/ -I/opt/vc/include/interface/vcos/pthreads -I/opt/vc/include/interface/vmcs_host/linux -c main.cpp -o main.o
In file included from main.cpp:22:0:
DMXResource.hh:4:10: fatal error: bcm_host.h: No such file or directory
#include “bcm_host.h”
^~~~~~~~~~~~
compilation terminated.
Makefile:28: recipe for target ‘main.o’ failed
make: *** [main.o] Error 1

Although, when I try to install “libconfig+±dev” I receive
E: Unable to locate package libconfig+±dev
E: Couldn’t find any package by regex ‘libconfig+±dev’

Thanks


#387

What do you mean supported on Ubuntu?
The server (including compile) obviously is for OSMC. For client you take Remmina on Ubuntu


#388

I am using dismax to view graphical programs in vnc! I used it before on my raspberry pi under both OSMC and Raspbian and it worked well. I just want to know if I can do the same under Ubuntu? I am not 100% Remmina is? I have actually found another solution which is to use MobaXterm.