Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Black screen and unresponsive viewer after setting XFCE Display resolution #447

Open
yghorbal opened this issue Feb 10, 2025 · 4 comments
Open

Comments

@yghorbal
Copy link

Hi,

I'm investigating a TurboVNC issue on macOS leading to the viewer showing black screen and beeing unresponsive when certain conditions are met. It goes like this:

  1. make sur ~/.config/xfce is empty
  2. user connects with the viewer for the first time
  3. a new session is created and XFCE is started correctly
  4. the user changes Display options (Settings -> Connection) and sets Remote desktop size to Server and Scaling Factor to Fixed Aspect Ratio
Image
  1. the user sets a new Display resolution in XFCE Display settings pane. In my exemple: 1512x849
  2. the user disconnects
  3. the user starts the viewer again, sets back Remote desktop size options to Auto before connecting back
  4. the user hits connect
  5. session manager correctly identifies an already running session
  6. the user chooses to kill that session
  7. session manager proposes to create a new session
  8. the user chooses to create a new session
  9. the viewer starts and hit the black screen issue and becomes unresponsive (needs to be hardly killed)

Env description:
Client: macOS 13.6.9 (and tested it with macOS 14.3 as well) TurboVNC Version 3.1.3 (20241108)
Server: RHEL 8.8 turbovnc-3.1.3-20241108
/etc/turbovncserver.conf

[...]
$wm = "xfce";
$securityTypes = "OTP";
$geometry = "2560x1440";
$desktopName = "Foo ($ENV{USER})";
$serverArgs = "-noserverkeymap -verbose";

/etc/turbovncserver-security.conf

no-remote-connections
no-x11-tcp-connections
no-reverse-connections

The client's logs when connecting back (starting step 6)

% /opt/TurboVNC/bin/vncviewer -loglevel 100
Log setting: 100
main: start called
SessionManager: Opening SSH connection to host maestro-1490.maestro.pasteur.fr
Tunnel: Read OpenSSH config file /Users/djo/.ssh/config
SessionManager: Available sessions: :1
SessionManager: Killing TurboVNC session maestro-1490.maestro.pasteur.fr:1
SessionManager: ===============================================================================
SessionManager: SERVER WARNINGS/NOTIFICATIONS:
SessionManager: Killing Xvnc process ID 673121
SessionManager: ===============================================================================
SessionManager: Available sessions: None
SessionManager: Starting new TurboVNC session on host maestro-1490.maestro.pasteur.fr
SessionManager: ===============================================================================
SessionManager: SERVER WARNINGS/NOTIFICATIONS:
SessionManager: Starting applications specified in /opt/TurboVNC/bin/xstartup.turbovnc
SessionManager: Log file is /pasteur/appa/homes/djo/.vnc/maestro-1490:1.log
SessionManager:
SessionManager: ===============================================================================
SessionManager: Generating one-time password for session maestro-1490.maestro.pasteur.fr:1
SessionManager: ===============================================================================
SessionManager: SERVER WARNINGS/NOTIFICATIONS:
SessionManager: Full control one-time password: 23089894
SessionManager: ===============================================================================
Tunnel: Opening SSH tunnel through gateway maestro-1490.maestro.pasteur.fr
Tunnel: Forwarding local port 56805 to localhost:5901 (relative to gateway)
CConn: connected to host localhost port 56805
CConnection: reading protocol version
CConnection: Server supports RFB protocol version 3.8
CConnection: Using RFB protocol version 3.8
CConnection: processing security types message
CConnection: Server offers security type VncAuth(2)
CConnection: Server offers security type Tight(16)
CConnection: Choosing security type VncAuth(2)
CConnection: processing security message
CConnection: processing security result message
CConnection: Authentication success!
CConnection: reading server initialisation
CConnection: initialisation done
DesktopWindow: GraphicsDevice supports HW acceleration.
PlatformPixelBuffer: Native pixel format is depth 24 (32bpp) little-endian rgba8888
PlatformPixelBuffer: Native pixel format is depth 24 (32bpp) little-endian rgba8888
CConn: Using pixel format depth 24 (32bpp) little-endian rgba8888
CConn: Requesting Tight encoding
CConn: Screen 0 work area: 0, 38 1512 x 899
CConn: Spanned work area: 0, 38 1512 x 899
Viewport: Set geometry to 0, 38 1512 x 899
TurboVNC Helper: Intercepting tablet/keyboard events for window 0x1242621a0
CMsgHandler: Server clipboard capabilities:
CMsgHandler: - Plain text (limit = 0 bytes)
CMsgReader: Server supports GII version 1
CConn: Enabling GII
ScreenSet: LAYOUT RECEIVED:
ScreenSet:     64 (0x40): 2560x1440+0+0 (flags 0x0)
ScreenSet: LAYOUT SENT:
ScreenSet:     64 (0x40): 1512x849+0+0 (flags 0x0)
CConn: Enabling continuous updates
ScreenSet: LAYOUT RECEIVED:
ScreenSet:     64 (0x40): 1512x849+0+0 (flags 0x0)
TurboVNC Helper: Intercepting tablet/keyboard events for window 0x1242621a0
TurboVNC Helper: Shutting down tablet/keyboard event interceptor
CConn: Screen 0 work area: 0, 38 1512 x 899
CConn: Spanned work area: 0, 38 1512 x 899
Viewport: Set geometry to 0, 38 1512 x 899
TurboVNC Helper: Intercepting tablet/keyboard events for window 0x122fcc430
Viewport: Successfully created device 1 (Stylus)
Viewport: Successfully created device 2 (Eraser)
ScreenSet: LAYOUT RECEIVED:
ScreenSet:     64 (0x40): 1512x849+0+0 (flags 0x0)
TurboVNC Helper: Intercepting tablet/keyboard events for window 0x122fcc430
DesktopWindow: Local clipboard changed.  Notifying server.
CConn: key PRESS, RFB keycode 0x38 => 0xffe9
CConn: key release, RFB keycode 0x38 => 0xffe9
/opt/TurboVNC/bin/vncviewer: line 1: 11024 Killed: 9               "/Applications/TurboVNC/TurboVNC Viewer.app/Contents/MacOS/TurboVNC Viewer" ${1+"$@"}

Logs on the server looks like:

TurboVNC Server (Xvnc) 64-bit v3.1.3 (build 20241108)
Copyright (C) 1999-2024 The VirtualGL Project and many others (see README.md)
Visit http://www.TurboVNC.org for more information on TurboVNC

10/02/2025 23:55:49 Using security configuration file /etc/turbovncserver-security.conf
10/02/2025 23:55:49 Enabled security type 'otp'
10/02/2025 23:55:49 Desktop name 'Maestro (djo)' (maestro-1490:1)
10/02/2025 23:55:49 Protocol versions supported: 3.3, 3.7, 3.8, 3.7t, 3.8t
10/02/2025 23:55:49 Listening for VNC connections on TCP port 5901
10/02/2025 23:55:49   Interface 127.0.0.1
10/02/2025 23:55:49 Framebuffer: BGRX 8/8/8/8
10/02/2025 23:55:49 New desktop size: 2560 x 1440
10/02/2025 23:55:49 New screen layout:
10/02/2025 23:55:49   0x00000040 (output 0x00000040): 2560x1440+0+0
10/02/2025 23:55:49 Maximum clipboard transfer size: 1048576 bytes
(II) Initializing extension Generic Event Extension
(II) Initializing extension SHAPE
(II) Initializing extension MIT-SHM
(II) Initializing extension XInputExtension
(II) Initializing extension XTEST
(II) Initializing extension BIG-REQUESTS
(II) Initializing extension SYNC
(II) Initializing extension XKEYBOARD
(II) Initializing extension XC-MISC
(II) Initializing extension SECURITY
(II) Initializing extension XFIXES
(II) Initializing extension XFree86-Bigfont
(II) Initializing extension RENDER
(II) Initializing extension RANDR
(II) Initializing extension COMPOSITE
(II) Initializing extension DAMAGE
(II) Initializing extension MIT-SCREEN-SAVER
(II) Initializing extension RECORD
(II) Initializing extension DPMS
(II) Initializing extension Present
(II) Initializing extension X-Resource
(II) Initializing extension XVideo
(II) Initializing extension XVideo-MotionCompensation
(II) Initializing extension GLX
(II) IGLX: Loaded and initialized swrast
(II) GLX: Initialized DRISWRAST GL provider for screen 0
(II) Initializing extension VNC-EXTENSION
10/02/2025 23:55:49 VNC extension running!
(II) XKB: Reusing cached keymap
(II) XKB: Reusing cached keymap
(DB) Selection owner change for _DBUS_SESSION_BUS_SELECTION_djo_12984d5b15d24ac9af0922694d74e0a9
xstartup.turbovnc: Creating new session bus instance:
xstartup.turbovnc:   unix:abstract=/tmp/dbus-RoaAcPtCkh,guid=e9d9af7f23c371ba9b6039a967aa83f6
xstartup.turbovnc: Using 'xfce' window manager in
xstartup.turbovnc:   /usr/share/xsessions/xfce.desktop
xstartup.turbovnc: Executing startxfce4
/usr/bin/startxfce4: X server already running on display :1

10/02/2025 23:55:51 [1] Got connection from 127.0.0.1 on port 41094
10/02/2025 23:55:51 [1] Normal socket connection
10/02/2025 23:55:51 [1] Using protocol version 3.8
10/02/2025 23:55:51 [1] rfbSendSecurityTypeList: advertise sectype tight
10/02/2025 23:55:51 [1] Full-control authentication enabled
(DB) Selection owner change for WM_S0
10/02/2025 23:55:51 Number of connected clients: 1
10/02/2025 23:55:51 [1] Pixel format:
10/02/2025 23:55:51 [1]   32 bpp, depth 24, little endian
10/02/2025 23:55:51 [1]   true colour: max r 255 g 255 b 255, shift r 16 g 8 b 0
10/02/2025 23:55:51 [1]   no translation needed
(DB) Selection owner change for _NET_WM_CM_S0
(DB) Selection owner change for COMPOSITING_MANAGER
10/02/2025 23:55:51 [1] Enabling full-color cursor updates
10/02/2025 23:55:51 [1] Enabling Desktop Size protocol extension
10/02/2025 23:55:51 [1] Enabling Extended Desktop Size protocol extension
10/02/2025 23:55:51 [1] rfbProcessClientNormalMessage: ignoring unknown encoding -307 (fffffecd)
10/02/2025 23:55:51 [1] Enabling LastRect protocol extension
10/02/2025 23:55:51 [1] Enabling Continuous Updates protocol extension
10/02/2025 23:55:51 [1] Enabling Fence protocol extension
10/02/2025 23:55:51 [1] Enabling Extended Clipboard protocol extension
10/02/2025 23:55:51 [1] Enabling GII protocol extension
10/02/2025 23:55:51 [1] rfbProcessClientNormalMessage: ignoring unknown encoding -317 (fffffec3)
10/02/2025 23:55:51 [1] Using tight encoding
10/02/2025 23:55:51 [1] Enabling CopyRect encoding
10/02/2025 23:55:51 [1] Using JPEG subsampling 0, Q100
10/02/2025 23:55:51 [1] Using JPEG quality 95
10/02/2025 23:55:51 [1] Using JPEG subsampling 0
10/02/2025 23:55:51 [1] Using Tight compression level 1
10/02/2025 23:55:51 Using 2 threads for Tight encoding
10/02/2025 23:55:51 [1] Client clipboard capabilities:
10/02/2025 23:55:51 [1] - Plain text (limit = 0 bytes)
10/02/2025 23:55:51 [1] Client supports GII version 1
10/02/2025 23:55:51 New desktop size: 1512 x 849
10/02/2025 23:55:51 New screen layout:
10/02/2025 23:55:51   0x00000040 (output 0x00000040): 1512x849+0+0

(xfwm4:673758): xfwm4-WARNING **: 23:55:51.366: Unsupported GL renderer (llvmpipe (LLVM 15.0.7, 256 bits)).
(DB) Selection owner change for XFWM4_COMPOSITING_MANAGER
10/02/2025 23:55:51 [1] Continuous updates enabled
10/02/2025 23:55:51 [1] Continuous updates enabled
10/02/2025 23:55:51 [1] GII Device Create: Stylus
10/02/2025 23:55:51 [1] GII device ID = 1
10/02/2025 23:55:51 [1] GII Device Create: Eraser
10/02/2025 23:55:51 [1] GII device ID = 2
(DB) Selection owner change for _XSETTINGS_S0
10/02/2025 23:55:51 New desktop size: 2048 x 1152
10/02/2025 23:55:51 New screen layout:
10/02/2025 23:55:51   0x00000040 (output 0x00000040): 2048x1152+0+0

(xfsettingsd:673767): xfsettingsd-CRITICAL **: 23:55:51.412: Failed to apply display settings
10/02/2025 23:55:51 [1] GII Device Create: Stylus
10/02/2025 23:55:51 [1] Device 'Stylus' already exists with GII device ID 1
10/02/2025 23:55:51 [1] GII Device Create: Eraser
10/02/2025 23:55:51 [1] Device 'Eraser' already exists with GII device ID 2
10/02/2025 23:55:51 [1] Continuous updates enabled
10/02/2025 23:55:51 [1] Continuous updates enabled
(DB) Selection owner change for CLIPBOARD_MANAGER
(DB) Remote clipboard announced.  Grabbing local ownership.
(DB) Created selection window
(DB) Grabbed PRIMARY selection
(DB) Grabbed CLIPBOARD selection
(DB) Selection owner change for _NET_DESKTOP_LAYOUT_S0
(DB) Selection owner change for XFDESKTOP_SELECTION_0
(DB) Selection owner change for _NET_DESKTOP_MANAGER_S0

** (xfce-polkit:673793): CRITICAL **: 23:55:52.085: polkit_agent_listener_register_with_options: assertion 'POLKIT_IS_SUBJECT (subject)' failed
corrupted size vs. prev_size in fastbins

(wrapper-2.0:673812): libactions-WARNING **: 23:55:52.879: Calling CanShutdown failed GDBus.Error:org.xfce.SessionManager.Error.Failed: GDBus.Error:org.freedesktop.systemd1.UnitMasked: Unit systemd-logind.service is masked.

(wrapper-2.0:673812): libactions-WARNING **: 23:55:52.910: Calling CanRestart failed GDBus.Error:org.xfce.SessionManager.Error.Failed: GDBus.Error:org.freedesktop.systemd1.UnitMasked: Unit systemd-logind.service is masked.

(xfce4-session:673651): xfce4-session-WARNING **: 23:55:52.912: failed to run script: Failed to execute child process “/usr/bin/pm-is-supported” (No such file or directory)
(DB) Selection owner change for _NET_SYSTEM_TRAY_S0

(xfce4-session:673651): xfce4-session-WARNING **: 23:55:52.940: failed to run script: Failed to execute child process “/usr/bin/pm-is-supported” (No such file or directory)

(xfce4-session:673651): xfce4-session-WARNING **: 23:55:52.960: failed to run script: Failed to execute child process “/usr/bin/pm-is-supported” (No such file or directory)

(wrapper-2.0:673812): Gtk-WARNING **: 23:55:52.984: Negative content width -1 (allocation 1, extents 1x1) while allocating gadget (node button, owner XfceArrowButton)
(DB) PressKey: keycode 64 down
(DB) PressKey: keycode 64 up
10/02/2025 23:56:12 [1] Client gone
10/02/2025 23:56:12 [1] Statistics:
10/02/2025 23:56:12 [1]   key events received 2, pointer events 0
10/02/2025 23:56:12 [1]   framebuffer updates 20, rectangles 72, bytes 25673
10/02/2025 23:56:12 [1]     LastRect markers 10, bytes 120
10/02/2025 23:56:12 [1]     cursor shape updates 4, bytes 12720
10/02/2025 23:56:12 [1]     Tight rectangles 58, bytes 12833
10/02/2025 23:56:12 [1]   raw equivalent 53.641080 Mbytes, compression ratio 4179.932985
(DB) Remote clipboard lost.  Removing local ownership.
10/02/2025 23:56:12 Device 'Stylus' no longer used by any clients.  Deleting.
10/02/2025 23:56:12 Device 'Eraser' no longer used by any clients.  Deleting.
10/02/2025 23:56:12 Number of connected clients: 0

At this stage, I'm not really 100% sure it's a TurboVNC issue or an XFCE one (or a bad interaction with both of them)
The issue is nealy reproducible at will! (at least in my env)

@dcommander
Copy link
Member

I unfortunately can't reproduce the issue, but there is a possibility that it is another symptom of #435. Can you please try upgrading the server to 3.1.4?

@yghorbal
Copy link
Author

I've tested with 3.1.4 with no avail the issue is still happening.
Can you try clicking "Refresh" before hitting "New session" between step 10 and 11?
If you have any "advanced" logging I can activate I'd happy to!

@dcommander
Copy link
Member

Still can't reproduce, but what you said in Step 4 confuses me. You said that the user is setting the display resolution in XFCE to 1512x849. However, that is not one of the standard X RandR resolutions. 1512x849 would only be offered as a display resolution if it is the current resolution of the TurboVNC session. Thus, selecting that resolution would be a no-op, since it is already the current resolution.

In order to fully reproduce the issue, please provide the following additional information:

  1. The screen resolution of the client
  2. The output of xrandr in the TurboVNC session prior to Step 4

@yghorbal
Copy link
Author

To begin with, I completely missed my "copy/paste" for step 4, the user needs to change the resolution to 2048x1152
and not 1512x849, sorry about that :(

Now about your actual questions !

When connecting TurboVNC in Remote Desktop size set to "Auto" (as it's by default) in step 2:

Image

At that stage xrandr output is like this:

$ xrandr
Screen 0: minimum 32 x 32, current 1512 x 849, maximum 32767 x 32767
VNC-0 connected 1512x849+0+0 0mm x 0mm
   1512x849      60.00*+
   3840x2160     60.00  
   3200x1800     60.00  
   2880x1800     60.00  
   2560x1600     60.00  
   2560x1440     60.00  
   2048x1536     60.00  
   2048x1152     60.00  
   1920x1200     60.00  
   1920x1080     60.00  
   1680x1050     60.00  
   1600x1200     60.00  
   1600x1000     60.00  
   1600x900      60.00  
   1440x900      60.00  
   1400x1050     60.00  
   1366x768      60.00  
   1360x768      60.00  
   1344x1008     60.00  
   1344x840      60.00  
   1280x1024     60.00  
   1280x960      60.00  
   1280x800      60.00  
   1280x720      60.00  
   1152x864      60.00  
   1136x640      60.00  
   1024x768      60.00  
   1024x640      60.00  
   960x640       60.00  
   960x600       60.00  
   960x540       60.00  
   854x480       60.00  
   800x600       60.00  
   800x480       60.00  
   640x480       60.00  
   640x360       60.00  
   480x320       60.00 

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants