TigerVNC Server crashes regularly

I have a tigervnc configured via system, I have it running on multiple times on different Raspis, and they run as expected. Except for one. This one exits regularly and with no obvious reason. Also the time between crashes can vary.
Between 3 and 30 days.

If I look at the command line in ps the only obvious difference I can see there compared to the other machines is that the Passwordfile is not the one specified in the home directory but -PasswordFile /tmp/tigervnc.RuRM8e/passwd where on the others it would be -PasswordFile /home/user/.vnc/passwd

The only message related I can find in the log is:
Sat Aug 24 07:43:12 2024
ComparingUpdateTracker: 0 pixels in / 0 pixels out
ComparingUpdateTracker: (1:nan ratio)
The Xtigervnc server cleanly exited!
Killing Xtigervnc process ID 870… success!

Any way to troubleshoot this?

on
DietPi v9.4.2
RPi 5 Model B
conf via dietpi.txt and systemd

did you tried to check journalctl or dmesg for related messages?

No because I don’t really know when it happens. I randomdly use the remote access and once I realize it it’s too late.

maybe you can check it next time

So now it happened again. journalctl | grep vnc gives me only the start:

Sep 12 10:17:05 ELROND vncserver[716]: [ INFO ] Starting virtual desktop at display :1 in 3440x1440x16

Logfile says:

Sat Sep 21 15:34:38 2024
 ComparingUpdateTracker: 0 pixels in / 0 pixels out
 ComparingUpdateTracker: (1:nan ratio)
The Xtigervnc server cleanly exited!
Killing Xtigervnc process ID 864... success!

Last used was on Sep 19th with a bit a strange entry:

Thu Sep 19 21:40:36 2024
 VNCSConnST:  closing 192.168.0.1::55383: read: Connection reset by peer (104)
 EncodeManager: Framebuffer updates: 2806
 EncodeManager:   RRE:
 EncodeManager:     Solid: 3.204 krects, 5.35363 Mpixels
 EncodeManager:            56.3203 KiB (1:186.324 ratio)
 EncodeManager:   Hextile:
 EncodeManager:     Bitmap RLE: 950 rects, 2.34537 Mpixels
 EncodeManager:                 45.8887 KiB (1:100.067 ratio)
 EncodeManager:     Indexed RLE: 5.442 krects, 21.7399 Mpixels
 EncodeManager:                  2.42175 MiB (1:17.1479 ratio)
 EncodeManager:     Full Colour: 7.497 krects, 51.3841 Mpixels
 EncodeManager:                  26.578 MiB (1:3.69077 ratio)
 EncodeManager:   Total: 17.093 krects, 80.823 Mpixels
 EncodeManager:          29.0995 MiB (1:5.30432 ratio)
 Connections: closed: 192.168.0.1::55383
 ComparingUpdateTracker: 2.16437 Gpixels in / 76.4218 Mpixels out
 ComparingUpdateTracker: (1:28.3214 ratio)
X connection to :1 broken (explicit kill or server shutdown).

I don’t know if it has anything to do with it but I am getting A LOT of messages into .xsession-errors like so, permanently:

ALSA lib conf.c:5703:(snd_config_expand) Evaluate error: Datei oder Verzeichnis nicht gefunden
ALSA lib control.c:1528:(snd_ctl_open_noupdate) Invalid CTL default
ALSA lib confmisc.c:855:(parse_card) cannot find card '0'
ALSA lib conf.c:5180:(_snd_config_evaluate) function snd_func_card_inum returned error: Datei oder Verzeichnis nicht gefunden
ALSA lib confmisc.c:422:(snd_func_concat) error evaluating strings
ALSA lib conf.c:5180:(_snd_config_evaluate) function snd_func_concat returned error: Datei oder Verzeichnis nicht gefunden
ALSA lib confmisc.c:1334:(snd_func_refer) error evaluating name
ALSA lib conf.c:5180:(_snd_config_evaluate) function snd_func_refer returned error: Datei oder Verzeichnis nicht gefunden
ALSA lib conf.c:5703:(snd_config_expand) Evaluate error: Datei oder Verzeichnis nicht gefunden
ALSA lib control.c:1528:(snd_ctl_open_noupdate) Invalid CTL default

Sounds something related to audio. Not sure how that could influence TigerVNC.

maybe @MichaIng has an idea what the audio issue could be.

Actually I don’t think it has anything to do with TigerVNC. But this is a problem in itself. since I was looking for hints for what could be the reason for TigerVNCs crrashes I came across this. And I found a .xsession-errors file in my home directory that was 1.6GB in file size.
The Raspi is used mainly by terminal but is for convenience sometimes approached via vnc.
So I installed TigerVNC and mate. No further configuration for anything else. There is no audio stuff connected whatsoever.
This file grows by the minute.

did you already tried disabling audio?

No I didn’t because I don’t know anything about audio. And there is no audio present, no device connected and nothing that I have installed related to audio.
So what would you recommend?

Try going to dietpi-config and adjust audio settings

I disabled audio now but it doesn’t change anything.
.xsession-errors is growing 1MB per 5 minutes by this error messages.

Did you reboot?

of course

As I watch it now with tail -f I see that there is a permanent stream of error messages/s coming in

The only thing that remotely has to do with audio is handbrake which I have installed to automatically transcode video files. No clue if there could be a connection.

did you tried to remove it for testing?

No I haven’t. Any additional ideas?

Creating a bug report/issue

I have searched the existing open and closed issues

Required Information

  • DietPi version | cat /boot/dietpi/.version
    G_DIETPI_VERSION_CORE=9
    G_DIETPI_VERSION_SUB=4
    G_DIETPI_VERSION_RC=2
    G_GITBRANCH=‘master’
    G_GITOWNER=‘MichaIng’
    G_LIVE_PATCH_STATUS[0]=‘not applicable’

  • Distro version | echo $G_DISTRO_NAME $G_RASPBIAN
    bookworm 0

  • Kernel version | uname --all
    Linux ELROND 6.6.31+rpt-rpi-2712 #1 SMP PREEMPT Debian 1:6.6.31-1+rpt1 (2024-05-29) aarch64 GNU/Linux

  • Architecture | dpkg --print-architecture
    arm64

  • SBC model | echo $G_HW_MODEL_NAME or (EG: RPi3)
    RPi 5 Model B (aarch64)

  • Power supply used | (EG: 5V 1A RAVpower)

  • SD card used | (EG: SanDisk ultra)

I am getting about 50 entries per second in .xsession-errors

ALSA lib conf.c:5703:(snd_config_expand) Evaluate error: Datei oder Verzeichnis nicht gefunden
ALSA lib control.c:1528:(snd_ctl_open_noupdate) Invalid CTL default
ALSA lib confmisc.c:855:(parse_card) cannot find card '0'
ALSA lib conf.c:5180:(_snd_config_evaluate) function snd_func_card_inum returned error: Datei oder Verzeichnis nicht gefunden
ALSA lib confmisc.c:422:(snd_func_concat) error evaluating strings
ALSA lib conf.c:5180:(_snd_config_evaluate) function snd_func_concat returned error: Datei oder Verzeichnis nicht gefunden
ALSA lib confmisc.c:1334:(snd_func_refer) error evaluating name
ALSA lib conf.c:5180:(_snd_config_evaluate) function snd_func_refer returned error: Datei oder Verzeichnis nicht gefunden

Although I understand your desire to keep things slender, the ALSA lib problem has nothing to do with TigerVNC.

In fact the ALSA lib problem is much more dramatic. It is a permanent anoying filling of diskspace which cannot be stopped. That’s why I opened a new topic.

At this point Joulinar I need to know whether there is anything to expect from your side or if I’m alone on this and should consider deleting this server and try a different OS?