Xorg high CPU usage and log spam
Configuration and version information:
- RealVNC Server (7.9.0) on Kubuntu 22.04 (KDE desktop)
- RealVNC Viewer (7.9.0) on Windows 10
- Server is running Xorg headlessly with physical GPU and driver (as opposed to xserver-xorg-video-dummy driver)
- Identical behaviour when tested with actual monitor plugged into server
- Tested with both NVIDIA and old AMD Radeon GPUs and respective drivers (identical behaviour)
- Local (LAN) connection only
Generally, the whole setup works very well apart from one significant issue, which manifests in the following ways:
1. Xorg process shows constant high-CPU usage, even when both computers are idle: about 30% (of one CPU core).
2. Xorg.0.log (high verbosity here for debugging purposes) is being spammed many times per second with the following set of entries, which represent monitor EDID (Extended Display Identification Data) requests. This happens whether an actual monitor is plugged into the server or a virtual monitor is configured to mimic the real one.
[ 117.659] (II) RADEON(0): EDID for output DisplayPort-0
[ 117.686] (II) RADEON(0): EDID for output DisplayPort-1
[ 117.688] (II) RADEON(0): EDID for output HDMI-0
[ 117.689] (II) RADEON(0): EDID for output DVI-0
[ 117.689] (II) RADEON(0): EDID for output DVI-1
[ 117.689] (II) RADEON(0): Manufacturer: SAM Model: 27f Serial#: 1296380466
[ 117.689] (II) RADEON(0): Year: 2007 Week: 51
[ 117.689] (II) RADEON(0): EDID Version: 1.3
[ 117.689] (II) RADEON(0): Digital Display Input
[ 117.689] (II) RADEON(0): Max Image Size [cm]: horiz.: 47 vert.: 30
[ 117.689] (II) RADEON(0): Gamma: 2.20
[ 117.689] (II) RADEON(0): DPMS capabilities: Off
[ 117.689] (II) RADEON(0): Supported color encodings: RGB 4:4:4 YCrCb 4:4:4
[ 117.689] (II) RADEON(0): First detailed timing is preferred mode
[ 117.689] (II) RADEON(0): redX: 0.644 redY: 0.333 greenX: 0.286 greenY: 0.603
[ 117.689] (II) RADEON(0): blueX: 0.152 blueY: 0.079 whiteX: 0.313 whiteY: 0.329
[ 117.689] (II) RADEON(0): Supported established timings:
[ 117.689] (II) RADEON(0): 720x400@70Hz
[ 117.689] (II) RADEON(0): 640x480@60Hz
[ 117.689] (II) RADEON(0): 640x480@67Hz
[ 117.689] (II) RADEON(0): 640x480@72Hz
[ 117.689] (II) RADEON(0): 640x480@75Hz
[ 117.689] (II) RADEON(0): 800x600@56Hz
[ 117.689] (II) RADEON(0): 800x600@60Hz
[ 117.689] (II) RADEON(0): 800x600@72Hz
[ 117.689] (II) RADEON(0): 800x600@75Hz
[ 117.689] (II) RADEON(0): 832x624@75Hz
[ 117.689] (II) RADEON(0): 1024x768@60Hz
[ 117.689] (II) RADEON(0): 1024x768@70Hz
[ 117.689] (II) RADEON(0): 1024x768@75Hz
[ 117.689] (II) RADEON(0): 1280x1024@75Hz
[ 117.689] (II) RADEON(0): 1152x864@75Hz
[ 117.689] (II) RADEON(0): Manufacturer's mask: 0
[ 117.689] (II) RADEON(0): Supported standard timings:
[ 117.689] (II) RADEON(0): #0: hsize: 1680 vsize 1050 refresh: 60 vid: 179
[ 117.689] (II) RADEON(0): #1: hsize: 1280 vsize 1024 refresh: 60 vid: 32897
[ 117.689] (II) RADEON(0): #2: hsize: 1280 vsize 960 refresh: 60 vid: 16513
[ 117.689] (II) RADEON(0): #3: hsize: 1152 vsize 864 refresh: 75 vid: 20337
[ 117.689] (II) RADEON(0): Supported detailed timing:
[ 117.689] (II) RADEON(0): clock: 119.0 MHz Image Size: 474 x 296 mm
[ 117.689] (II) RADEON(0): h_active: 1680 h_sync: 1728 h_sync_end 1760 h_blank_end 1840 h_border: 0
[ 117.689] (II) RADEON(0): v_active: 1050 v_sync: 1053 v_sync_end 1059 v_blanking: 1080 v_border: 0
[ 117.689] (II) RADEON(0): Ranges: V min: 56 V max: 75 Hz, H min: 30 H max: 81 kHz, PixClock max 145 MHz
[ 117.689] (II) RADEON(0): Monitor name: SyncMaster
[ 117.689] (II) RADEON(0): Serial No: HMEPC00366
[ 117.689] (II) RADEON(0): EDID (in hex):
[ 117.689] (II) RADEON(0): 00ffffffffffff004c2d7f023232454d
[ 117.689] (II) RADEON(0): 33110103802f1e782ad515a455499a27
[ 117.689] (II) RADEON(0): 145054bfef80b30081808140714f0101
[ 117.689] (II) RADEON(0): 0101010101017c2e90a0601a1e403020
[ 117.689] (II) RADEON(0): 3600da281100001a000000fd00384b1e
[ 117.689] (II) RADEON(0): 510e000a202020202020000000fc0053
[ 117.689] (II) RADEON(0): 796e634d61737465720a2020000000ff
[ 117.689] (II) RADEON(0): 00484d45504330303336360a2020001f
[ 117.689] (II) RADEON(0): EDID vendor "SAM", prod id 639
[ 117.689] (II) RADEON(0): Using hsync ranges from config file
[ 117.689] (II) RADEON(0): Using vrefresh ranges from config file
[ 117.689] (II) RADEON(0): Printing DDC gathered Modelines:
[ 117.690] (II) RADEON(0): Modeline "1680x1050"x0.0 119.00 1680 1728 1760 1840 1050 1053 1059 1080 +hsync -vsync (64.7 kHz eP)
[ 117.690] (II) RADEON(0): Modeline "800x600"x0.0 40.00 800 840 968 1056 600 601 605 628 +hsync +vsync (37.9 kHz e)
[ 117.690] (II) RADEON(0): Modeline "800x600"x0.0 36.00 800 824 896 1024 600 601 603 625 +hsync +vsync (35.2 kHz e)
[ 117.690] (II) RADEON(0): Modeline "640x480"x0.0 31.50 640 656 720 840 480 481 484 500 -hsync -vsync (37.5 kHz e)
[ 117.690] (II) RADEON(0): Modeline "640x480"x0.0 31.50 640 664 704 832 480 489 492 520 -hsync -vsync (37.9 kHz e)
[ 117.690] (II) RADEON(0): Modeline "640x480"x0.0 30.24 640 704 768 864 480 483 486 525 -hsync -vsync (35.0 kHz e)
[ 117.690] (II) RADEON(0): Modeline "640x480"x0.0 25.18 640 656 752 800 480 490 492 525 -hsync -vsync (31.5 kHz e)
[ 117.690] (II) RADEON(0): Modeline "720x400"x0.0 28.32 720 738 846 900 400 412 414 449 -hsync +vsync (31.5 kHz e)
[ 117.690] (II) RADEON(0): Modeline "1280x1024"x0.0 135.00 1280 1296 1440 1688 1024 1025 1028 1066 +hsync +vsync (80.0 kHz e)
[ 117.690] (II) RADEON(0): Modeline "1024x768"x0.0 78.75 1024 1040 1136 1312 768 769 772 800 +hsync +vsync (60.0 kHz e)
[ 117.690] (II) RADEON(0): Modeline "1024x768"x0.0 75.00 1024 1048 1184 1328 768 771 777 806 -hsync -vsync (56.5 kHz e)
[ 117.690] (II) RADEON(0): Modeline "1024x768"x0.0 65.00 1024 1048 1184 1344 768 771 777 806 -hsync -vsync (48.4 kHz e)
[ 117.690] (II) RADEON(0): Modeline "832x624"x0.0 57.28 832 864 928 1152 624 625 628 667 -hsync -vsync (49.7 kHz e)
[ 117.690] (II) RADEON(0): Modeline "800x600"x0.0 49.50 800 816 896 1056 600 601 604 625 +hsync +vsync (46.9 kHz e)
[ 117.690] (II) RADEON(0): Modeline "800x600"x0.0 50.00 800 856 976 1040 600 637 643 666 +hsync +vsync (48.1 kHz e)
[ 117.690] (II) RADEON(0): Modeline "1152x864"x0.0 108.00 1152 1216 1344 1600 864 865 868 900 +hsync +vsync (67.5 kHz e)
[ 117.690] (II) RADEON(0): Modeline "1280x1024"x0.0 108.00 1280 1328 1440 1688 1024 1025 1028 1066 +hsync +vsync (64.0 kHz e)
[ 117.690] (II) RADEON(0): Modeline "1280x960"x0.0 108.00 1280 1376 1488 1800 960 961 964 1000 +hsync +vsync (60.0 kHz e)
[ 117.690] (II) RADEON(0): Printing probed modes for output DVI-1
[ 117.690] (II) RADEON(0): Modeline "1680x1050_virtual"x59.9 119.00 1680 1728 1760 1840 1050 1053 1059 1080 +hsync -vsync (64.7 kHz UP)
[ 117.690] (II) RADEON(0): Modeline "1680x1050"x59.9 119.00 1680 1728 1760 1840 1050 1053 1059 1080 +hsync -vsync (64.7 kHz eP)
[ 117.690] (II) RADEON(0): Modeline "1280x1024"x75.0 135.00 1280 1296 1440 1688 1024 1025 1028 1066 +hsync +vsync (80.0 kHz e)
[ 117.690] (II) RADEON(0): Modeline "1280x1024"x60.0 108.00 1280 1328 1440 1688 1024 1025 1028 1066 +hsync +vsync (64.0 kHz e)
[ 117.690] (II) RADEON(0): Modeline "1280x960"x60.0 108.00 1280 1376 1488 1800 960 961 964 1000 +hsync +vsync (60.0 kHz e)
[ 117.690] (II) RADEON(0): Modeline "1152x864"x75.0 108.00 1152 1216 1344 1600 864 865 868 900 +hsync +vsync (67.5 kHz e)
[ 117.690] (II) RADEON(0): Modeline "1024x768"x75.0 78.75 1024 1040 1136 1312 768 769 772 800 +hsync +vsync (60.0 kHz e)
[ 117.690] (II) RADEON(0): Modeline "1024x768"x70.1 75.00 1024 1048 1184 1328 768 771 777 806 -hsync -vsync (56.5 kHz e)
[ 117.690] (II) RADEON(0): Modeline "1024x768"x60.0 65.00 1024 1048 1184 1344 768 771 777 806 -hsync -vsync (48.4 kHz e)
[ 117.690] (II) RADEON(0): Modeline "832x624"x74.6 57.28 832 864 928 1152 624 625 628 667 -hsync -vsync (49.7 kHz e)
[ 117.690] (II) RADEON(0): Modeline "800x600"x72.2 50.00 800 856 976 1040 600 637 643 666 +hsync +vsync (48.1 kHz e)
[ 117.690] (II) RADEON(0): Modeline "800x600"x75.0 49.50 800 816 896 1056 600 601 604 625 +hsync +vsync (46.9 kHz e)
[ 117.690] (II) RADEON(0): Modeline "800x600"x60.3 40.00 800 840 968 1056 600 601 605 628 +hsync +vsync (37.9 kHz e)
[ 117.690] (II) RADEON(0): Modeline "800x600"x56.2 36.00 800 824 896 1024 600 601 603 625 +hsync +vsync (35.2 kHz e)
[ 117.690] (II) RADEON(0): Modeline "640x480"x75.0 31.50 640 656 720 840 480 481 484 500 -hsync -vsync (37.5 kHz e)
[ 117.690] (II) RADEON(0): Modeline "640x480"x72.8 31.50 640 664 704 832 480 489 492 520 -hsync -vsync (37.9 kHz e)
[ 117.690] (II) RADEON(0): Modeline "640x480"x66.7 30.24 640 704 768 864 480 483 486 525 -hsync -vsync (35.0 kHz e)
[ 117.690] (II) RADEON(0): Modeline "640x480"x59.9 25.18 640 656 752 800 480 490 492 525 -hsync -vsync (31.5 kHz e)
[ 117.690] (II) RADEON(0): Modeline "720x400"x70.1 28.32 720 738 846 900 400 412 414 449 -hsync +vsync (31.5 kHz e)
3. vncserver-x11.log (high verbosity here for debugging purposes) is being spammed with the following set of of entries many times per second. This happens even when using the dummy driver for Xorg. These messages are less verbose, but still present at the default log level of 30. When dropped to 29, the messages are not logged.
<15> 2024-02-03T15:26:02.162Z HomeServer vncserver-x11[1595]: SDesktopAgent: setPixelBuffer 1680x1050 at 0,0 stride 1680 pf depth 24 (32 bpp) little-endian rgb888
<15> 2024-02-03T15:26:02.162Z HomeServer vncserver-x11[1595]: SharedMemSysV: Receive 25 size 0x6baa80
<15> 2024-02-03T15:26:02.259Z HomeServer vncserver-x11[1595]: Agent: PixelBufferX11: XShm extension present - version 1.2 (with pixmaps)
<14> 2024-02-03T15:26:02.259Z HomeServer vncserver-x11[1595]: Agent: PixelBufferX11: Using shared memory Pixmap
<14> 2024-02-03T15:26:02.260Z HomeServer vncserver-x11[1595]: Agent: SServerAgent: setPixelBuffer 1680x1050 at 0,0 pf depth 24 (32 bpp) little-endian rgb888
<15> 2024-02-03T15:26:02.260Z HomeServer vncserver-x11[1595]: Agent: SharedMemSysV: sending 25 size 0x6baa80
All three symptoms seem to be aspects of the same process: RealVNC server is interacting with the Xorg via some sort of pixel buffer, which amongst others causes Xorg EDID queries many times a second.
Additional information:
When connected to the server, but before logging in, when the SDDM login screen is shown, none of the above symptoms manifest. I find this particularly surprising. It only starts when the user's desktop is shown — and stops again when logging out, back to the SDDM login screen (but remaining connected via RealVNC).
When configuring Xorg with a virtual screen and the xserver-xorg-video-dummy driver, only the RealVNC server log symptoms remain. There is no Xorg log spam and Xorg CPU usage drops to virtually nothing (as expected) while there is no desktop activity.
I've experiment with a few RealVNC Server settings, which I thought could conceivably be related, with no effect:
- CompareFB
- CaptureMethod
- AllowDynamicResolution
I did not find RealVNC Viewer settings that had any effect either.
Any thoughts on what causes this behaviour and how to prevent it, please?
Comments
Please sign in to leave a comment.