Beginner struggles - Help with VNC?

Hello everyone,
I have begun my journey with Linux in September this year and even if I feel I made a lot of progress by following Jay, reading books, following our community , etc, I still struggle badly with some basics.
For instance VNC.
I am trying to connect to my local server using VNC, and I actually make it happen but unfortunately get a grey screen on my client computer… I was wondering if someone had an idea of what is wrong?

vncserver (xtightvnc) is installed on Debian12.
I use tigervnc as client on a win11 machine.

Here are the logs and the ~/.vnc/xstartup file

29/12/23 20:17:25 Xvnc version TightVNC-1.3.10
29/12/23 20:17:25 Copyright (C) 2000-2009 TightVNC Group
29/12/23 20:17:25 Copyright (C) 1999 AT&T Laboratories Cambridge
29/12/23 20:17:25 All Rights Reserved.
29/12/23 20:17:25 See http://www.tightvnc.com/ for information on TightVNC
29/12/23 20:17:25 Desktop name 'X' (debian02:1)
29/12/23 20:17:25 Protocol versions supported: 3.3, 3.7, 3.8, 3.7t, 3.8t
29/12/23 20:17:25 Listening for VNC connections on TCP port 5901

29/12/23 20:17:33 Got connection from client 192.168.1.243
29/12/23 20:17:33 Using protocol version 3.8
29/12/23 20:17:37 Full-control authentication passed by 192.168.1.243
29/12/23 20:17:37 Pixel format for client 192.168.1.243:
29/12/23 20:17:37   8 bpp, depth 8
29/12/23 20:17:37   true colour: max r 7 g 7 b 3, shift r 5 g 2 b 0
29/12/23 20:17:37 rfbProcessClientNormalMessage: ignoring unknown encoding -314
29/12/23 20:17:37 rfbProcessClientNormalMessage: ignoring unknown encoding 1464686180
29/12/23 20:17:37 Enabling full-color cursor updates for client 192.168.1.243
29/12/23 20:17:37 Enabling X-style cursor updates for client 192.168.1.243
29/12/23 20:17:37 rfbProcessClientNormalMessage: ignoring unknown encoding 1464686182
29/12/23 20:17:37 rfbProcessClientNormalMessage: ignoring unknown encoding -223
29/12/23 20:17:37 rfbProcessClientNormalMessage: ignoring unknown encoding -308
29/12/23 20:17:37 rfbProcessClientNormalMessage: ignoring unknown encoding -261
29/12/23 20:17:37 rfbProcessClientNormalMessage: ignoring unknown encoding 1464686184
29/12/23 20:17:37 rfbProcessClientNormalMessage: ignoring unknown encoding -307
29/12/23 20:17:37 Enabling LastRect protocol extension for client 192.168.1.243
29/12/23 20:17:37 rfbProcessClientNormalMessage: ignoring unknown encoding -1063131698
29/12/23 20:17:37 rfbProcessClientNormalMessage: ignoring unknown encoding -313
29/12/23 20:17:37 rfbProcessClientNormalMessage: ignoring unknown encoding -312
29/12/23 20:17:37 rfbProcessClientNormalMessage: ignoring unknown encoding -258
29/12/23 20:17:37 Using tight encoding for client 192.168.1.243
29/12/23 20:17:37 rfbProcessClientNormalMessage: ignoring unknown encoding 50
29/12/23 20:17:37 rfbProcessClientNormalMessage: ignoring unknown encoding 16
29/12/23 20:17:37 Using compression level 2 for client 192.168.1.243
29/12/23 20:24:59 Client 192.168.1.243 gone
29/12/23 20:24:59 Statistics:
29/12/23 20:24:59   key events received 0, pointer events 63
29/12/23 20:24:59   framebuffer updates 1, rectangles 130, bytes 4341
29/12/23 20:24:59     LastRect markers 1, bytes 12
29/12/23 20:24:59     cursor shape updates 1, bytes 82
29/12/23 20:24:59     tight rectangles 128, bytes 4247
29/12/23 20:24:59   raw bytes equivalent 786444, compression ratio 185.176360

29/12/23 20:25:59 Got connection from client 192.168.1.243
29/12/23 20:25:59 Using protocol version 3.8
29/12/23 20:26:09 Full-control authentication passed by 192.168.1.243
29/12/23 20:26:09 Pixel format for client 192.168.1.243:
29/12/23 20:26:09   8 bpp, depth 8
29/12/23 20:26:09   true colour: max r 7 g 7 b 3, shift r 5 g 2 b 0
29/12/23 20:26:09 rfbProcessClientNormalMessage: ignoring unknown encoding -314
29/12/23 20:26:09 rfbProcessClientNormalMessage: ignoring unknown encoding 1464686180
29/12/23 20:26:09 Enabling full-color cursor updates for client 192.168.1.243
29/12/23 20:26:09 Enabling X-style cursor updates for client 192.168.1.243
29/12/23 20:26:09 rfbProcessClientNormalMessage: ignoring unknown encoding 1464686182
29/12/23 20:26:09 rfbProcessClientNormalMessage: ignoring unknown encoding -223
29/12/23 20:26:09 rfbProcessClientNormalMessage: ignoring unknown encoding -308
29/12/23 20:26:09 rfbProcessClientNormalMessage: ignoring unknown encoding -261
29/12/23 20:26:09 rfbProcessClientNormalMessage: ignoring unknown encoding 1464686184
29/12/23 20:26:09 rfbProcessClientNormalMessage: ignoring unknown encoding -307
29/12/23 20:26:09 Enabling LastRect protocol extension for client 192.168.1.243
29/12/23 20:26:09 rfbProcessClientNormalMessage: ignoring unknown encoding -1063131698
29/12/23 20:26:09 rfbProcessClientNormalMessage: ignoring unknown encoding -313
29/12/23 20:26:09 rfbProcessClientNormalMessage: ignoring unknown encoding -312
29/12/23 20:26:09 rfbProcessClientNormalMessage: ignoring unknown encoding -258
29/12/23 20:26:09 Using tight encoding for client 192.168.1.243
29/12/23 20:26:09 rfbProcessClientNormalMessage: ignoring unknown encoding 50
29/12/23 20:26:09 rfbProcessClientNormalMessage: ignoring unknown encoding 16
29/12/23 20:26:09 Using compression level 2 for client 192.168.1.243
29/12/23 20:26:28 Client 192.168.1.243 gone
29/12/23 20:26:28 Statistics:
29/12/23 20:26:28   key events received 0, pointer events 60
29/12/23 20:26:28   framebuffer updates 1, rectangles 130, bytes 4341
29/12/23 20:26:28     LastRect markers 1, bytes 12
29/12/23 20:26:28     cursor shape updates 1, bytes 82
29/12/23 20:26:28     tight rectangles 128, bytes 4247
29/12/23 20:26:28   raw bytes equivalent 786444, compression ratio 185.176360


#!/bin/sh

xrdb "$HOME/.Xresources"
xsetroot -solid grey
#x-terminal-emulator -geometry 80x24+10+10 -ls -title "$VNCDESKTOP Desktop" &
#x-window-manager &
# Fix to make GNOME work
export XKL_XMODMAP_DISABLE=1
/etc/X11/Xsession

Welcome to the forum!

Many desktop environments fail to work with VNC. GNOME Shell and KDE used to not work. XFCE and LXDE worked fine with both vnc and xrdp, last I checked them.

If you’re using KDE Plasma, idk. If you’re using GNOME Shell, well, that has its own screen sharing built-in tool in the settings, which is based on vnc. You can enable it and it allows you to remote to it.

Thank you for the information and the welcome, very much appreciated. I’ve actually installed xfce on the server and tried to log from my client.

Something happens which is good but my server instantly logs out.

Of course when it logs out it seems that the #vncserver process stops and then I cannot even try to log in again. Any advice?

I tried to make the process persistent even at log-out but I struggle with the correct commands… Any help is very much appreciated.

Cheers,

I think the current configuration is to not control the logged in screen, but to log in a new session. And when that happens, your current one gets signed out. Not sure though, last I tried VNC on linux (like 6 or more years ago), I was getting a new session with the same user.

Not sure what I can advise. Try to set the VNC server as a service in systemd? Or maybe switch to x2go, Jay did a video on it (probably skip around min 10).

There is an x2go client for windows.

Yes I am going to try x2go, I just struggle too much with VNC Server. I managed to get it to work on an Oracle Linux 8 but I think it was beginner’s luck.