[Bug]: VBoxClient clipboard conflicts with XRDP clipboard in Linux guests
メンテナーはふだん 6 日以内に返信
まだ誰も着手していません。
評価
調査の方向性
Start by reading /etc/X11/Xsession.d/98vboxadd-xclient and /etc/xdg/autostart/vboxclient.desktop, the two startup paths named in the report, and trace how Guest Additions handle XRDP sessions. The workaround reports that suppressing VBoxClient in XRDP restores clipboard transfers and the XFCE wallpaper. Done means XRDP clipboard redirection works without disrupting the session, while local X11 startup remains available.
索引モデルが issue の本文から書いたものです。
説明
Version
7.2.20
Host OS Type
Linux
Host OS name + version
Lubuntu 24.04.3
Host Architecture
x86
Guest OS Type
Linux
Guest Architecture
x86
Guest OS name + version
Ubuntu 22.04.3
Component
Guest Additions/Shared Clipboard
What happened?
Environment
VirtualBox host OS: Lubuntu 24.04 (Linux)
VirtualBox host version: 7.2.20
Guest OS: Linux with XFCE desktop and XRDP
Guest Additions tested: 7.0.14 and 7.2.20
RDP client: FreeRDP (xfreerdp)
Guest networking: VirtualBox NAT with TCP port forwarding (host 127.0.0.1:3390 → guest port 3389)
The host itself is accessed remotely from Windows, resulting in the following connection chain:
Windows (MSTSC) → Lubuntu host (XRDP) → FreeRDP → VirtualBox Linux guest (XRDP)
Problem
When connecting to the Linux VirtualBox guest via XRDP with clipboard redirection enabled (+clipboard), clipboard synchronization becomes unreliable or stops working.
Observed symptoms:
Copy/paste between the RDP client and the Linux guest fails or hangs.
Clipboard synchronization can also affect the upstream RDP connection between Windows and the Linux host.
Windows applications using the clipboard (e.g. Notepad++) may become unresponsive.
The XFCE desktop wallpaper in the guest disappears and the desktop background becomes black.
Disabling RDP clipboard redirection (-clipboard) prevents these symptoms, but clipboard sharing is then unavailable.
The problem was reproduced using VirtualBox 7.2.20 on the host, with both Guest Additions 7.0.14 and 7.2.20 in the guest.
Updating the Guest Additions to match the host version did not resolve the problem.
Suspected cause
VirtualBox Guest Additions automatically start VBoxClient --clipboard inside the XRDP X11 session.
At the same time, XRDP starts xrdp-chansrv, which provides its own clipboard synchronization.
Both components therefore attempt to manage clipboard operations within the same X11 session.
Two VirtualBox autostart mechanisms were identified:
/etc/X11/Xsession.d/98vboxadd-xclient
/etc/xdg/autostart/vboxclient.desktop (starts VBoxClient-all)
The X11 startup script excludes SSH sessions but does not exclude XRDP sessions.
How can we reproduce this?
Steps to reproduce
Install a Linux guest with XFCE and XRDP in VirtualBox 7.2.20.
Install VirtualBox Guest Additions (tested with 7.0.14 and 7.2.20).
Configure VirtualBox NAT port forwarding for XRDP (host port 3390 → guest port 3389).
Connect using FreeRDP with clipboard redirection enabled:
xfreerdp /v:127.0.0.1:3390 /u:xuser /cert:ignore +clipboard
Check for VBoxClient processes inside the XRDP session.
Test clipboard transfers between the guest, the host and the upstream Windows client.
Confirmed workaround
Prevent VirtualBox's clipboard client from starting inside XRDP sessions while keeping XRDP clipboard redirection enabled.
- Mark XRDP sessions
In /etc/xrdp/startwm.sh, before starting XFCE:
export XRDP_SESSION=1
startxfce4
- Modify the VirtualBox X11 startup script
In /etc/X11/Xsession.d/98vboxadd-xclient, change:
elif test -z "${SSH_CONNECTION}"; then
to:
elif test -z "${SSH_CONNECTION}" && [ -z "${XRDP_SESSION}" ]; then
This prevents VBoxClient from being started by this script in XRDP sessions while preserving its startup in local X11 sessions.
- Disable the additional desktop autostart
Create a user-specific override:
mkdir -p ~/.config/autostart
cp /etc/xdg/autostart/vboxclient.desktop ~/.config/autostart/
echo 'Hidden=true' >> ~/.config/autostart/vboxclient.desktop
This disables the additional VBoxClient-all desktop autostart for the affected user.
Results after applying the workaround
No VBoxClient processes are started inside the XRDP session.
Clipboard redirection with FreeRDP +clipboard works correctly.
Copy/paste works across the complete connection chain: Windows ↔ Linux host ↔ VirtualBox guest.
The XFCE wallpaper remains visible.
The workaround continues to work after rebooting the guest.
The workaround works with both Guest Additions 7.0.14 and 7.2.20.
Reverting from Guest Additions 7.2.20 to 7.0.14 after applying the workaround did not reintroduce the problem.
This indicates that the issue is related to VBoxClient startup and clipboard interaction rather than a mismatch between the VirtualBox host and Guest Additions versions.
Suggested improvement
VirtualBox Guest Additions should detect XRDP sessions and avoid automatically starting VBoxClient --clipboard when XRDP already provides clipboard redirection.
Alternatively, the Guest Additions startup scripts should provide a documented mechanism for excluding XRDP sessions.
Note: The conflict between VBoxClient and XRDP clipboard handling is strongly suggested by the successful workaround. The exact internal failure mechanism has not yet been isolated.
Did you upload all of your necessary log files, screenshots, etc.?
- Yes, I've uploaded all pertinent files to this issue.
- 主要言語
- C
- スター
- 1.4k
- フォーク
- 219
- PR マージ指標
- 30日以内にマージされた PR はありません
環境構築
- Dockerfile・Docker Compose ファイルなし
- プルリクエストのテンプレートなし
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
VirtualBox/virtualbox のほかの issue
-
enhancement
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
VirtualBox/virtualbox#979 ·
メンテナーはふだん 6 日以内に返信
-
[Bug]: Guest Additions 7.2.20 vboxvideo fails to build on Linux kernel 6.12.113 (drm_fb_helper_restore_fbdev_mode_unlocked: too few arguments)対応中かも @Berbe が 11 日前に担当しました。 オープンbug
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
VirtualBox/virtualbox#918 · コメント 9 件 ·
メンテナーはふだん 6 日以内に返信
-
bug
難易度 4/5 3〜5日 初心者へのやさしさ 12/100
VirtualBox/virtualbox#981 ·
メンテナーはふだん 6 日以内に返信
-
bug
難易度 4/5 3〜5日 初心者へのやさしさ 8/100
VirtualBox/virtualbox#980 ·
メンテナーはふだん 6 日以内に返信
-
bug
難易度 4/5 3〜5日 初心者へのやさしさ 18/100
VirtualBox/virtualbox#977 ·
メンテナーはふだん 6 日以内に返信
VirtualBox/virtualbox の issue をすべて見る
似ている issue
-
bug good first issue
難易度 2/5 1〜3時間 初心者へのやさしさ 85/100
メンテナーはふだん 1 日以内に返信
-
Status: Opened
難易度 2/5 1〜3時間 初心者へのやさしさ 64/100
メンテナーはふだん 1 日以内に返信
-
bug
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
FriendsofECCE/ECCE#1018 ·
-
難易度 2/5 1〜3時間 初心者へのやさしさ 62/100
immortalwrt/immortalwrt#2522 ·
-
翻译冲突オープン
難易度 1/5 1時間未満 初心者へのやさしさ 78/100
fw876/helloworld#2089 ·
メンテナーはふだん 1 日以内に返信