Raspberry OS / VNC Server on Le Potato

I am having VNC Server troubles using a Raspbian 11 (Bullseye 64 bit) running on an AML-X509-CC (Le Potato) that is headless. This is something that I do all the time on Raspberry Pis.

The image boots fine, but trying to connect using VNC Viewer (from a Mac) gives me a ‘The connection was refused by the computer’ error. However, the VNC Server is installed and works fine if I take the same image (card) and boot it on a real RPi 4.

It looks like the X server is running:

$ ps -aef | grep xorg
root 627 604 0 10:59 tty7 00:00:20 /usr/lib/xorg/Xorg :0 -seat seat0 -auth /var/run/lightdm/root/:0 -nolisten tcp vt7 -novtswitch

Is this something that should work, and if so, what do I need to do? Below is the VNC log file. Thanks in advance for any advice, as I can’t find anything useful on Google or searching this site.

Regards,

Dave.

OS: Debian GNU/Linux 11, Linux 6.0.15, aarch64
<14> 2022-12-31T15:56:08.169Z bambam vncserver-x11[608]: LogDestMem: Start replaying stored messages
<14> 2022-12-31T15:56:08.170Z bambam vncserver-x11[608]: Localize: Locales en_US
<14> 2022-12-31T15:56:08.170Z bambam vncserver-x11[608]: PlanMgr: Getting CloudConfig.pkg from built-in resource
<14> 2022-12-31T15:56:08.170Z bambam vncserver-x11[608]: PlanMgr: Using business identifier 7af732a6-4a61-4849-b6d6-55bde3a8f55b
<14> 2022-12-31T15:56:08.170Z bambam vncserver-x11[608]: PlanKeys: Setting no license key
<14> 2022-12-31T15:56:08.170Z bambam vncserver-x11[608]: LogDestMem: Finished replaying stored messages
<13> 2022-12-31T15:56:08.170Z bambam vncserver-x11[608]: ServerManager: Server started
<14> 2022-12-31T15:56:08.170Z bambam vncserver-x11[608]: FeaturePlans: Using Unlicensed plan
<14> 2022-12-31T15:56:08.219Z bambam vncserver-x11[608]: GoogleAnalytics: X.509 Error: Certificate expired
<14> 2022-12-31T15:56:08.228Z bambam vncserver-x11[608]: SModuleCtrlCommsListen: listening on /tmp/.vnc-vncservice/vncserver-x11.CtrlComms
<13> 2022-12-31T15:56:08.228Z bambam vncserver-x11[608]: ConsoleDisplay: Found running X server (pid=627, binary=/usr/lib/xorg/Xorg)
<14> 2022-12-31T15:56:08.229Z bambam vncserver-x11[608]: AgentMgrService: consoleDisplayChanged, running 1
<14> 2022-12-31T15:56:08.229Z bambam vncserver-x11[608]: AgentMgrLauncher: Restarting agent in 0ms
<14> 2022-12-31T15:56:11.376Z bambam vncserver-x11[608]: SDesktopAgent: agent connected
<14> 2022-12-31T15:56:11.376Z bambam vncserver-x11[608]: UiProcess: Restart in 500ms
<14> 2022-12-31T15:56:11.387Z bambam vncserver-x11[608]: Agent: Localize: Locales en_US
<14> 2022-12-31T15:56:11.387Z bambam vncserver-x11[608]: Agent: Randr: XRandr extension present - version 1.5
<14> 2022-12-31T15:56:11.387Z bambam vncserver-x11[608]: Agent: SDesktopX11: XFixes extension present - version 5.0
<14> 2022-12-31T15:56:11.387Z bambam vncserver-x11[608]: Agent: SDesktopX11: XDamage extension present - version 1.1
<14> 2022-12-31T15:56:11.387Z bambam vncserver-x11[608]: Agent: TXClipboardMgr: XFixes extension present - version 5.0
<14> 2022-12-31T15:56:11.387Z bambam vncserver-x11[608]: Agent: DesktopUidMonitor: Starting desktop uid monitor
<14> 2022-12-31T15:56:11.387Z bambam vncserver-x11[608]: Agent: DesktopUidMonitor: Desktop user is -1
<14> 2022-12-31T15:56:15.012Z bambam vncserver-x11[608]: UiProcess: Restart in 500ms
<14> 2022-12-31T15:56:15.012Z bambam vncserver-x11[608]: Agent: DesktopUidMonitor: Desktop user is 1000
<14> 2022-12-31T15:56:15.531Z bambam vncserver-x11[608]: UiProcess: UI process starte
<14> 2022-12-31T15:56:16.095Z bambam vncserver-x11[608]: Ipc: Ui: Bad msg name ‘desktopEnv’

I had the same issue. For me, running sudo vnclicensewiz on the server and filling in the forms corrected the problem. The file transfer doesn’t work on the potato as it does on the pi’s and you have to login via your team (cloud) vs a simple ip address on your network. And for the life of me I can’t find a command to set the default video output to HDMI, so the remote window is 720 x 5xx. My workaround is an edid emulator in the hdmi slot. Hang in there.

It’s probably picking up the CVBS connection as the first device instead of the HDMI.

Yeah. I tried adding a newmode 1920x1080 59.4 to the CVBS via xrandr and it added the mode, but errored out when I tried to change to it. If anyone has a more elegant solution than the edid emulator I’d love to try it. Thanks.

You can try disabling CVBS using the libretech-wiring-tool. libretech-wiring-tool/cvbs-disable.dts at master · libre-computer-project/libretech-wiring-tool · GitHub

git clone https://github.com/libre-computer-project/libretech-wiring-tool.git lwt
cd lwt
make
sudo ./ldto merge cvbs-disable
reboot

Thank you adding the code and for this suggestion. No joy though. Errored out at u-boot. Had to remove the dtb folder from the boot directory. This with nothing in the HDMI port or the CVBS port. Interesting that there are hooks available in the wiring tool to play with the video ports though.

What was the error you got?

I took a pic of the screen because I’m not sure where this would be logged, but I kept getting an error on this compose screen when trying to upload the pic. My config is the current Raspberry from your distro [2022-09-22-raspbian-bullseye-arm64+aml-s905x-cc.img.xz](https://distro.libre.computer/ci/raspbian/11/2022-09-22-raspbian-bullseye-arm64%2Baml-s905x-cc.img.xz Dec 13 . I boot from a 32 gig emmc. Anyway…

scanning bus usb0c9000000 for devices… 3 USB devlce(s) found
scanning USB for storage devices… 0 Storage Device(s) found
Hit any key to stop autoboot: 0
switch to partitions #0, OK
mmc0 is current device
Scanning mmc 0:1
Invalid FAT entry
** Unable to read file /dtb/amloglc/meson-gxl-s905x-libretech-cc.dtb **
Failed to load ‘/dtb/amlogic/meson-gxl-s905x-libretech-cc.dtb’
No EFI system partition
fdt_find_or_add_subnode: memory: FDT_ERR_BADSTRUCTURE
ERROR: arch-specific fdt fixup failed

  • must RESET the board to recover.

ERROR: failed to process device tree
Found EFI removable media binary efl/boot/bootaa64.efi
856064 bytes read In 20 ms (40.8 NIB/s’)
fdt_find_or_add_subnode: memory: FDT_ERR_BADSTRUCTURE
ERROR: arch-specific fdt fixup failed

  • must RESET the board to recover.

ERROR: failed to process device tree
EFI LOAD FAILED: continuing…
Card did not respond to voltage select! : -110
MMC Device 2 not found
no mmc device at slot 2
Device 0: unknown device
=>

Thanks again.

PS: Once I deleted the dtd folder from the boot sector it booted normally. The goal is a headless box using VNC. I’m using it as an (airsoft.com) SDR spyserver and to relay several sensors via i2c.

Did you unplug the power instead of reboot? It says it cannot read the file…

Newbie error and you’ve done this before. Thank you for your personal attention. It’s not at 1920x1080 yet, but it’s large enough (I’ll keep tweaking). Eliminating the emulator was my goal and this is a huge improvement.

Dave,

I’m having exactly the same problem not being able to get VNC to work. Licensing isn’t the issue for me and port 5900 is specifically allowed in the firewall. However, when I try to telnet into port 5900, I get the message “telnet: Unable to connect to remote host: Connection refused”. Yet I can telnet into another port that i allowed in the firewall without a problem. Seems like something going on with the board, not with realvnc.

Have you had any luck getting vnc to work yet?

Craig

I have have the same problem. VNC won’t start because of licensing issue. I ran the wizard and signed up for a home account on real VNC. It looks licensed there. I would like to make this work as it does with a real raspberry. For now, until I have a solution, I installed tight VNC.

This is a software configuration problem with your VNC service. Connection refused means there’s no listening service or the firewall is blocking it.

Well yes it isn’t listening. The service is not running. It can not start.

I have allowed 5900 specifically, so firewall shouldn’t be the issue. How do I check to see if there is a listening service?

Craig

Actually, I checked using “sudo netstat -lpnt” and it does not show up as listening. However, I am able to start and stop the service using “sudo systemctl start vncserver-x11-serviced.service” or “sudo systemctl stop vncserver-x11-serviced.service”. When started, the VNC logo shows up in the task bar and I get the green checkmark in the vnc connect window, but it still doesn’t show up as listening.

Unfortunately, I do not have a team+cloud account, as I have been directly connecting via IP address, relying on the “free” Home + Educational license … which works on a Raspberry Pi but not a Le Potato (same boot image). The VNS server starts and is running, but it just won’t accept connections.

So I may instead use Remote Desktop, which seems to work.

I’ve use tigervnc without any issues.

I use tightvnc headless under raspberry pi OS (debian/raspbian) and it runs perfectly. I use ufw for firwall management (you don’t have to but I find it easier):

sudo apt install tightvncserver ufw
tightvncserver (configure the password)
sudo ufw allow from 192.168.0.0/24 to any port 5901 (change 192.168.0.0/24 for your network)
sudo ufw enable
Add to /etc/rc.local a line like this (replace myUserName with your login user name)
sudo -u myUserName tightvncserver :1 -geometry 1200x800 -depth 16