From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from gate001.proxmox.com (gate001.proxmox.com [IPv6:2a0f:8001:1:32::40]) by lore.proxmox.com (Postfix) with ESMTPS id 25BA11FF0B7 for ; Fri, 16 Oct 2026 08:56:17 +0200 (CEST) Received: from gate001.proxmox.com (localhost.localdomain [127.0.0.1]) by gate001.proxmox.com (Proxmox) with ESMTP id 7CD2E21480; Fri, 16 Oct 2026 08:56:13 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20251104; t=1792133760; x=1792738560; darn=lists.proxmox.com; h=disposition-notification-to:thread-index:in-reply-to :content-transfer-encoding:content-type:mime-version:message-id:date :subject:to:from:return-receipt-to:from:to:cc:subject:date :message-id:reply-to:content-type; bh=L35UrE4A/Q8straAB3Iqq96Td/GZQFSti7jJoIymECs=; b=PRv62swxIg8qX82BleB5pQwui1jEgkCibBkYGnNgzIXQnTDi0oCREBUW03Ivu+bbTu SPTC3AzFEEuOjsln5BVtaDePnoAuo+IqoIobWY7VX+vZQHdMeevmOhOHkEs2Qhtge1nM JYrTBd7g9r44jEjMthBH1mZbXWXjyq4ygn8BpUaMIPdOGCT0lG4LPEGFYoELmh1hSUSB nGNCi+Ic7OnE4h2B8twx+9Mf0fU+cGDZU63qf1pEzYmwPsQjqvJpY7tuB9vF+4ZmJv1M pQjxF4sQE3qcBxxn7UPDNK3IJrDGQaUa0gNfj0gNt2+NMfV3liBrRN43qvERTJ0zjwfB PL+w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20260707; t=1792133760; x=1792738560; h=disposition-notification-to:thread-index:in-reply-to :content-transfer-encoding:content-type:mime-version:message-id:date :subject:to:from:return-receipt-to:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to:content-type; bh=L35UrE4A/Q8straAB3Iqq96Td/GZQFSti7jJoIymECs=; b=ysyPzz6x1duASN0S/5ioQILuk9GyS1qx8BHOw7aOlhNwZFlxsdGK1bSdoFyb8XpXRi 49ZBXNDl8qitvRQGDGum6agw65tm4ZfsLQRO5QwPWHVomtYPYiwrUr1tDoBxxh5NldTS M0IRqIq93PDADGUhClYdTSx0K9HZQW4gKZ4xrSih+rE8yEjBV938Tu33Hnqdt7ILYiD+ vAabYMAWcNF76KIuWwKjK261+WlnKnw+44yWGd56+Vv0NR7TCdH8+XOH8kcgdORMEbJf Lc7R4MFpu81HUGRT4CCP8q2tG/CJlfZ/kti+JSsAy9AsgXHQdWiDqA/NHjjF2149cuhM y7Ig== X-Forwarded-Encrypted: i=1; AKwUvBwm8HsePuTYff27ZFmCg+0e5T6M3R2LhROYZRCaOQ8oSd3+NxP0N/5jLPlkB2ZaqGAFmpJzmgyC04w=@lists.proxmox.com X-Gm-Message-State: AFq9FYJddwypIXWriV9oanBimabZmNTOKRiQXcuQaLHKUJaWdYDFS+ok JTlHirka+Bq05kg/XgglCM26VF32ID8+E6k2CwpHx6NobmdDn3Nw4oDbwt9BUud4JUQ= X-Gm-Gg: AYBFou0C5GOvBYlcH2dek2Lfyue/juyhuMHE9NEflR2rIwvH62pTfYp7LeKSaEJxZPh yl9eYjvuYGTbp+vh4YnnWwPDQdGTejMiQ+ITZdXk+hGoU14VBID1qV9MNA3KC3I92EsFaifBKBr wz2OH1J7/RpefPZdSmCdWb+5uBjqEkdyZRQvTlrxmsck0zenIpWob+guh4kk0PvfiEPTeo/sJz5 Vwjv2sZ+L18pwaGnqumoQOPN77bY9urkvdzK8Yeqt2Ca5/ZJCaLUDhJxqUVlgJxNSa3Rme01MpS 4oqdlP6h9yE9Uo6cPmEpND6ntpaCgZ+8fxfhHJEcFRHwgOhCHOKhZCW29Ydo4G4yo1ruq+7Y4l4 axpfO57KeNmEcQbeqgIs/qcJLeVEyXQjqOen57H0M+kJHKY4nAjey7uk8jiVjHLRBnoLEeQDtf5 kj0NJR5z51v76FBBQEc95VN2a+4uWJ5FvIqR5wAf/L9pmNjfgBWr8bmcdFVAmkjkladBiggOsDr WQXhE32M+UXi4Gccg== X-Received: by 2002:a05:6000:2407:b0:48b:9d2:1a6a with SMTP id ffacd0b85a97d-48ddf883a1bmr23291322f8f.1.1792133759541; Thu, 15 Oct 2026 23:55:59 -0700 (PDT) From: "Dmitry R" To: "'DERUMIER, Alexandre'" , Subject: RE: [RFC] WebRTC console for VMs via QEMU's D-Bus display Date: Fri, 16 Oct 2026 09:58:00 +0300 Message-ID: MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable X-Mailer: Microsoft Office Outlook, Build 11.0.6353 In-Reply-To: Thread-Index: AQHdVXBGRf4eiR7QAEqLeEZZz5ArJ7byIEeAgArwHwCAABI1QIABJVlQgAAi5ICAAV+1gA== X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2180 X-SPAM-LEVEL: Spam detection results: 2 AWL 0.417 Adjusted score from AWL reputation of From: address DKIM_SIGNED 0.1 Message has a DKIM or DK signature, not necessarily valid DKIM_VALID -0.1 Message has at least one valid DKIM or DK signature DKIM_VALID_AU -0.1 Message has a valid DKIM or DK signature from author's domain DKIM_VALID_EF -0.1 Message has a valid DKIM or DK signature from envelope-from domain DMARC_PASS -0.1 DMARC pass policy FREEMAIL_ENVFROM_END_DIGIT 1 Envelope-from freemail username ends in digit FREEMAIL_FROM 0.001 Sender email is commonly abused enduser mail provider GB_FREEMAIL_NUM 0.75 Freemail spammy address POISEN_SPAM_PILL 0.1 Meta: its spam POISEN_SPAM_PILL_1 0.1 random spam to be learned in bayes POISEN_SPAM_PILL_3 0.1 random spam to be learned in bayes RCVD_IN_DNSWL_NONE -0.0001 Sender listed at https://www.dnswl.org/, no trust SPF_HELO_NONE 0.001 SPF: HELO does not publish an SPF Record SPF_PASS -0.001 SPF: sender matches SPF record Message-ID-Hash: MFJDMZF25ZUIT5B7G6NEI73XPX5TGWV5 X-Message-ID-Hash: MFJDMZF25ZUIT5B7G6NEI73XPX5TGWV5 X-MailFrom: rdmitry0911@gmail.com X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; loop; banned-address; emergency; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header X-Mailman-Version: 3.3.10 Precedence: list List-Id: Proxmox VE development discussion List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: Hi Alexandre, =20 Thanks for looking at it. =20 Yes, the native version now goes through pveproxy on 8006. The browser uses the PVE API for signalling, status and media settings; the API = handlers check the PVE permissions and forward requests to the media daemon over = a local Unix socket. This works for both VMs and LXC. WebRTC media still = uses UDP between the browser and the node. =20 Thanks for pointing out the PBS conflict. Port 8007 belongs to the = older standalone add-on. The native path does not need it, and the = compatibility service can be disabled once the old consumers are migrated. I checked = VM and LXC consoles with that service stopped, so a native installation can leave 8007 available for PBS. =20 For latency, I used a small test page inside the guest and a = Playwright script observing the console in the browser. It records = performance.now() when the console receives the mousemove event, then detects the test = page's colored hover popup in the returned image. Each detection poll redraws = the current video or noVNC canvas before reading its pixels. The poll runs = at the browser's animation cadence, and both timestamps use the same = browser clock. The popup is cleared before each repetition. =20 On the CPU-only nested lab, the median of five hover runs on the same Standard VGA VM was 88 ms through QSM with libx264 and 52 ms through = noVNC. So noVNC was faster for that isolated pointer event. The smoother video/scrolling results are separate measurements of delivered pictures = and bandwidth, rather than evidence of lower interaction latency. =20 This measures browser input-event to detected guest response, = including guest repaint and browser scheduling. It does not measure physical mouse-to-monitor latency. These figures are from the September setup; I = have not repeated this latency comparison on the shared-platform revision or = with NVENC. =20 Method, environment and results (https://github.com/rdmitry0911/qsm-rd/blob/main/qsm-direct/docs/COMPARIS= ON. md#interaction-latency-2026-09-08) =20 Measurement script (https://github.com/rdmitry0911/qsm-rd/blob/main/qsm-direct/lab/proxmox9/= mea sure-interaction.cjs) =20 Thanks, Dmitry =20 -----Original Message----- From: DERUMIER, Alexandre [mailto:alexandre.derumier@groupe-cyllene.com] = Sent: Thursday, October 15, 2026 12:52 PM To: pve-devel@lists.proxmox.com; rdmitry0911@gmail.com Subject: Re: [RFC] WebRTC console for VMs via QEMU's D-Bus display Hi Dmitry, I wonder if it could be possible to put your qsm-pve-direct daemon = behind pveproxy , like I do for my rdp daemon ? (it's just forwarding) This could avoid to expose another port. (I really don't known if it's possible). Also, be carefull, 8007 is also used by PBS. (and some user sometimes install PBS on same host than PVE) Btw, how do you have benched and retrieve metrics for latency ? Le jeudi 15 octobre 2026 =E0 10:53 +0300, Dmitry R a =E9crit=A0: > Hi Alexandre, hi all, >=20 > Following up on my reply yesterday: I've completed the QSM port to the = > shared per-VM D-Bus foundation and uploaded the source, patches and a=20 > matching preview build: >=20 > https://github.com/rdmitry0911/qsm-rd/releases/tag/v0.4.0-qsm-direct-2 > 026101 > 5-shared9 >=20 > The original D-Bus patch retains Alexandre's authorship and sign-off. > qemu-server owns the bus and its lifetime; QSM attaches as a consumer. = > The proposed opt-in is dbus-display: 1, with GPU type/rendernode in=20 > vga and driver=3Ddbus for audio0. CPU displays can keep VNC; GL = displays=20 > cannot provide VNC/SPICE alongside the D-Bus display. >=20 > The common display foundation, WebRTC API and pve-manager UI are=20 > separate series. A small pve-guest-common module now handles the local = > console service exchange for both VM and LXC APIs. Native signalling,=20 > status and media settings use PVE's existing HTTPS origin on8006, with = > VM.Console for offers/reads and VM.Config.Options for settings writes. = > There is no separate HTTPS port; WebRTC media still uses UDP. >=20 > I checked Firefox video and an ordinary Reconnect in the embedded VM=20 > console, and LXC video/settings, with the old8007 service stopped. > Anonymous > reads and writes without a CSRF token are rejected. The Firefox mDNS=20 > negotiation and reconnect issues found during VPN testing are fixed. > The > earlier shared-base lab checks also covered CPU/GL display, audio,=20 > microphone, clipboard and a second independent display consumer. >=20 > The graphical LXC sessions and provisioning remain in a separate add-=20 > on. > Their API patches can be reviewed independently of the QEMU=20 > foundation. > There are builds against pve-container 6.1.13 and 6.1.14, so the newer = > container package does not need to be downgraded. >=20 > Markus Frank's Venus configuration adaptation and the NVIDIA readback=20 > patch remain separate optional work. Runtime Venus and full Kyber/RDP=20 > browser integration have not been qualified by these tests. The source = > bases, package hashes, test logs and migration instructions are here: >=20 > https://github.com/rdmitry0911/qsm-rd/tree/main/qsm-direct/upstream >=20 > I'd appreciate feedback on the VM-wide option, bus lifetime, audio=20 > configuration and the API/service split. The patches are still a=20 > proposal; I have not treated the new configuration as an agreed=20 > upstream interface. >=20 > Thanks, > Dmitry >=20 > -----Original Message----- > From: Dmitry R [mailto:rdmitry0911@gmail.com] > Sent: Wednesday, October 14, 2026 5:20 PM > To: 'DERUMIER, Alexandre'; 'pve-devel@lists.proxmox.com' > Subject: RE: [RFC] WebRTC console for VMs via QEMU's D-Bus display >=20 > Hi Alexandre, >=20 > Thanks for your reply, and for making your patches available. I'm glad = > we can build on the same foundation. >=20 > I'll work from your v2 series, first separating the shared qemu-=20 > server D-Bus display support from the console-specific parts. Then=20 > I'll rebase the WebRTC console onto that base, using the per-VM bus=20 > from your DBusDisplay.pm. I'll keep the media service in a separate=20 > package and preserve your authorship on the original patches. >=20 > I'll also include the NVIDIA EGL readback fix I linked in my previous=20 > mail, keeping the existing VAAPI path available. My testing of that=20 > fix was limited to the capture/encoding adapter with output to a file; = > I still need to check it through the full Kyber console in the=20 > browser. >=20 > I'll take the OpenGL 4.6 / Venus series you mentioned into account=20 > when rebasing. The shared base will still need feedback from the=20 > Proxmox developers on the configuration and integration. >=20 > No problem about your availability. I'll send the revised patches to=20 > the list with you in Cc, so you can have a look when you have time. >=20 > Thanks, > Dmitry >=20 > -----Original Message----- > From: DERUMIER, Alexandre > [mailto:alexandre.derumier@groupe-cyllene.com] > Sent: Wednesday, October 14, 2026 4:12 PM > To: pve-devel@lists.proxmox.com; rdmitry0911@gmail.com > Subject: Re: [RFC] WebRTC console for VMs via QEMU's D-Bus display >=20 > Hi Dmitry, >=20 > Thanks for testing on nvidia, I didn't have hardware to test it. >=20 > Feel free to rework my patches, I was waiting from proxmox devs review = > && comments before doing more work. >=20 > I was waiting for the merge of this patch too: >=20 > =A0[PATCH qemu-server/pve-manager/docs v4 0/1] add virtio-vga-gl = OpenGL > 4.6 & Vulkan (venus) support > https://lore.proxmox.com/all/20260831094605.114396-1-m.frank@proxmox.c > om/ >=20 > to rebase my serie. >=20 > I'll be pretty busy at work until next month, so I'll don't have too=20 > much time to work on it. >=20 > but I'm glad that somebody is interested by me patch serie :) >=20 > Best Regards, >=20 > Alexandre >=20 >=20 >=20 > Le mercredi 07 octobre 2026 =E0 17:10 +0300, Dmitry R a =E9crit=A0: > >=20 > > Hi all, hi Alexandre, > > =A0 > > only after sending this RFC I noticed that Alexandre posted "add rdp = > > && kyber consoles for qemu over D-Bus display" in August [1]. Both=20 > > proposals need the same foundation in qemu-server -- QEMU's D-Bus=20 > > display -- and differ in what consumes it. Rather than two competing = > > ways to enable it, I would suggest one shared base with the consoles = > > on top. What the two series have in common: > > =A0*=A0 qemu-server enables '-display dbus' for a VM, and a separate = > > package attaches to it and streams the guest to the browser (RDP and = > > Kyber daemons there, a WebRTC media service here); > > =A0*=A0 with GL, QEMU refuses VNC and SPICE next to the D-Bus = display,=20 > > so both have to deal with a VM that has no VNC console. Where they=20 > > differ, and why I think Alexandre's base is the better one: > > =A0*=A0 His series runs a private dbus-daemon per VM; mine uses = p2p=3Dyes=20 > > and attaches every console with getfd + add_client. > > =A0*=A0 With p2p=3Dyes, each add_client replaces the previous = connection,=20 > > so only one consumer can be attached at a time. On a bus, RDP, Kyber = > > and WebRTC can attach to the same VM side by side. > > =A0*=A0 With p2p=3Dyes, QEMU 11.0 did not deliver audio in my tests: = the=20 > > AudioOutListener gets the Init/SetEnabled calls made while=20 > > RegisterOutListener runs, then nothing (the same with a plain GDBus=20 > > client, so it does not look like a problem of my listener). On a=20 > > private bus, which my add-on uses today, both playback and the=20 > > microphone (AudioInListener) work. > > A possible split: > > =A0=A0=A01.=A0 qemu-server: the per-VM D-Bus display (Alexandre's=20 > > DBusDisplay.pm), the option that enables it, 'rendernode' for > > virtio- > > gl (bug #4771) and a 'dbus' driver for audio0. > > =A0=A0=A02.=A0 One package per console, each attaching as a client = on that > > bus: RDP and Kyber (Alexandre), WebRTC (mine, bug #8106), with their = > > API calls and UI entries in qemu-server and pve-manager. > > =A0 > > I am happy to rebase the WebRTC part onto Alexandre's DBusDisplay.pm = > > and drop my p2p attach and the separate 'dbus' VGA flag. Alexandre=20 > > wrote that the DMA-BUF path is untested on NVIDIA, so I tried it on=20 > > an RTX 3080 (driver 595.91, nvidia-vaapi-driver 0.0.16, QEMU 11.0, a = > > virtio-vga-gl guest on a private per-VM bus; kyber-qemu-server and=20 > > txproto built from the v2 patch against Debian trixie's FFmpeg 7.1,=20 > > encoding to a file): > > =A0 > > - --dmabuf (h264_vaapi): QEMU hands over the scanout (XB24/AB24 with = > > the NVIDIA block-linear modifier 0x300000000e08014), but the VAAPI=20 > > frames context fails on the first frame -- "Failed to create > > surface: > > 14 (the requested RT Format is not supported)" -- and nothing is=20 > > encoded. With --encoder h264_nvenc it ends the same way, since the=20 > > path goes through VAAPI whatever the encoder. > > - The cause is the driver: on NVIDIA, VAAPI means nvidia-vaapi-=20 > > driver, which only decodes (VAEntrypointVLD): no encoding, no video=20 > > processing, no RGB surfaces. The mmap fallback would not help=20 > > either, as a block-linear buffer does not read as linear memory. > > - Without --dmabuf, the listener received no scanout at all from the = > > GL display within 15 s (libx264 and h264_nvenc alike). > > - Control on the same VM: my worker imports the same DMA-BUF with=20 > > EGL (eglCreateImageKHR, EGL_LINUX_DMA_BUF_EXT with the modifier),=20 > > reads it back with glReadPixels and encodes it with NVENC -- that=20 > > works. So with a virtio-gl guest on NVIDIA, the Kyber console shows=20 > > no picture today. > > =A0 > > A fix, tested [2]: a patch on top of v2 adds --dmabuf-readback to=20 > > kyber-qemu-server (358 lines, mostly one new file, LGPL like=20 > > dmabuf.c). It still requests DMA-BUF scanouts, imports each buffer=20 > > with EGL (GBM platform, surfaceless context, the modifier passed),=20 > > reads it back with glReadPixels and feeds your existing software=20 > > path, so any --encoder works -- h264_nvenc on NVIDIA. A buffer is=20 > > imported once and read only after QEMU reports damage. Same setup, a = > > terminal running 'top -d 0.1' for 20 s: 1226 frames encoded with=20 > > h264_nvenc, 0 dropped, the picture correct; about 24% of one CPU=20 > > core (36% with libx264). The --dmabuf path is unchanged;=20 > > kycontroller could choose '--dmabuf-readback --encoder h264_nvenc'=20 > > when the render node belongs to the nvidia driver. > > =A0 > > To be fair about the trade-off: the readback copies every changed=20 > > frame into system memory, so on AMD and Intel your zero-copy VAAPI=20 > > path is likely the more efficient one. The best of both would be=20 > > zero-copy where VAAPI can import and encode, and the EGL readback=20 > > everywhere else -- the same split would serve the WebRTC console. > > =A0 > > Maintainers: would one shared base series like this work for you,=20 > > and is there a preferred name and place for the option that enables=20 > > the D-Bus display? > > [1] https://lore.proxmox.com/pve-devel/20260826074347.1256659-1- > > alexandre.derumier@groupe-cyllene.com/ > > [2] https://github.com/rdmitry0911/qsm-rd/blob/main/qsm- > > direct/upstream/kyber-nvidia/0001-kyber-qemu-server-read-DMA-BUF- > > scanouts-back-through.patch > > =A0 > > Thanks, > > Dmitry > >=20 > > =A0 > > From: Dmitry R [mailto:rdmitry0911@gmail.com] > > Sent: Thursday, October 01, 2026 6:11 PM > > To: pve-devel@lists.proxmox.com > > Subject: [RFC] WebRTC console for VMs via QEMU's D-Bus display > >=20 > > Hi all, > >=20 > > I would like to ask whether a hardware-encoded WebRTC console for=20 > > VMs would be welcome upstream, and if so, in which shape.=A0 It runs = > > today as an add-on for PVE 9.2, and I have prepared the qemu-server=20 > > and pve-manager parts as patch series against current master (tested = > > on PVE 9.2 with an RTX 3080, see below) -- but I'd like your opinion = > > on the design before sending them. > >=20 > > Feature request: bug #8106 > > https://bugzilla.proxmox.com/show_bug.cgi?id=3D8106 > >=20 > > Motivation > > ---------- > > noVNC is the right console for firmware, installers and text=20 > > consoles. > > For time spent inside a running desktop it transfers changed=20 > > rectangles instead of video, has no audio, and a VirGL (virtio-gl)=20 > > guest reaches it through egl-headless readback.=A0 Measured with one = > > guest image and the same workloads (method and raw numbers in the=20 > > repository below): > >=20 > > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 WebRTC, = virtio-gl =A0 noVNC, std VGA > > =A0 720p video, pictures/s =A0 =A0 =A030 (source rate) =A0 =A07.4 > > =A0 scrolling, pictures/s =A0 =A0 =A0 36 (52 on NVENC) =A0 =A012.0 > > =A0 animated UI, pictures/s =A0 =A0 38 (45 on NVENC) =A0 =A011.0 > > =A0 bandwidth, 720p video =A0 =A0 =A0 18.8 Mbit/s =A0 =A0 =A0 =A0 = 120 Mbit/s > > =A0 single pointer event =A0 =A0 =A0 =A088 ms =A0 =A0 =A0 =A0 =A0 = =A0 =A0 52 ms > > =A0 console open -> 1st picture 3.4 s =A0 =A0 =A0 =A0 =A0 =A0 =A0 = 1.0 s > >=20 > > The last two rows are where noVNC stays better: a single isolated=20 > > event is one small rectangle for VNC, but a full encode/decode round = > > trip for video (the 88 ms were measured with software libx264 on a=20 > > CPU-only node).=A0 With NVENC (RTX 3080) the encoder used 4% while=20 > > streaming the animated scene. > >=20 > > What QEMU already provides > > -------------------------- > > QEMU's D-Bus display (-display dbus) exports the guest scanout --=20 > > the GL/DMA-BUF scanout of virtio-gl included -- and takes keyboard,=20 > > mouse, multi-touch, clipboard and audio.=A0 With p2p=3Dyes there is = no=20 > > bus > > daemon: > > a client is attached per connection through QMP (getfd +=20 > > add_client), which PVE::QMPClient can already do (it passes the fd=20 > > for getfd). > >=20 > > Proposed series > > --------------- > > 1. qemu-server: 'rendernode' for the VGA property > > =A0 =A0 =A0vga: virtio-gl,rendernode=3D/dev/dri/renderD129 > > =A0 =A0so a virtio-gl guest can be placed on a chosen GPU instead of = the > > =A0 =A0first render node (fixes #4771).=A0 Small and useful on its = own. > >=20 > > 2. qemu-server: opt-in 'dbus' for the VGA property > > =A0 =A0 =A0vga: virtio-gl,dbus=3D1 > > =A0 =A0adds '-display dbus,p2p=3Dyes' (gl=3Don with the render node = for > > =A0 =A0virtio-gl, gl=3Doff for the other types).=A0 One constraint: = with GL, > > =A0 =A0QEMU refuses VNC and SPICE next to it ("Display vnc is=20 > > incompatible > > =A0 =A0with the GL context"), so a virtio-gl VM with dbus=3D1 has = neither=20 > > and > > =A0 =A0offers the WebRTC console instead; non-GL types keep VNC as = well. > > =A0 =A0The clipboard reaches the guest through qemu-vdagent (as for = the > > =A0 =A0VNC clipboard) and the guest's spice-vdagent. > > =A0 =A0Audio is not part of the series yet: the add-on plays it = through=20 > > a > > =A0 =A0bus-mode D-Bus display (a 'dbus' audiodev named in -display), = but > > =A0 =A0with p2p=3Dyes our listener got no audio from QEMU 11.0 -- = only the > > =A0 =A0Init/SetEnabled calls made while RegisterOutListener runs,=20 > > nothing > > =A0 =A0afterwards.=A0 A 'dbus' audio0 driver is ready once that is=20 > > resolved. > >=20 > > 3. qemu-server: API call to attach a console > > =A0 =A0 =A0POST /nodes/{node}/qemu/{vmid}/webrtcproxy = =A0(VM.Console) > > =A0 =A0takes the browser's SDP offer, creates a socketpair, attaches = one > > =A0 =A0end to QEMU (getfd + add_client) and hands the other end with = the > > =A0 =A0offer to a local media service over a root-owned unix socket > > =A0 =A0(SCM_RIGHTS); returns the SDP answer.=A0 Authentication and = ACL=20 > > stay > > =A0 =A0exactly those of vncproxy/termproxy -- no extra port, no own=20 > > auth. > > =A0 =A0The status API reports 'dbus' and 'vnc' so the UI knows which > > =A0 =A0consoles a VM offers. > >=20 > > 4. pve-manager: WebRTC console type next to noVNC/SPICE/xterm.js > > =A0 =A0in the console button and the VM's Console panel, offered = when=20 > > the > > =A0 =A0VM's display has dbus=3D1; the display editor gets the two = options. > > =A0 =A0Like noVNC and xterm.js, the viewer itself is a page from a=20 > > separate > > =A0 =A0package that pveproxy serves ('?console=3Dkvm&webrtc=3D1'). > >=20 > > 5. A separate package with the media service: capture from the D-=20 > > Bus > > =A0 =A0display (the virtio-gl DMA-BUF scanout is imported through = EGL=20 > > and > > =A0 =A0read back; a zero-copy path to the encoder is future work),=20 > > encode > > =A0 =A0(NVENC, VA-API, QSV; libx264 fallback; H.264, HEVC where the > > =A0 =A0browser decodes it), > > =A0 =A0Opus audio, WebRTC.=A0 Today it is C++ (FFmpeg) plus a=20 > > Python/aiortc > > =A0 =A0WebRTC bridge; I realise Python/aiortc is unusual in your = stack. > >=20 > > Questions > > --------- > > - Is this something you would consider upstream at all? > > - Property naming: 'rendernode' and 'dbus' inside 'vga', or a=20 > > separate > > =A0 display property? > > - Would you rather keep the media service out of tree (users install > > =A0 it, the API call returns an error when it is absent), or should = it > > =A0 eventually live in a Proxmox-maintained package, and would you=20 > > then > > =A0 want it in Rust? > > - Is 'webrtcproxy' next to 'vncproxy'/'termproxy' the right place? > >=20 > > Not part of this proposal: the prototype also has a graphical=20 > > console for LXC containers (a headless compositor in the container=20 > > with its own login screen, one console per tty like the terminal=20 > > console). > > It > > needs software inside the guest, so I plan to keep it as a separate=20 > > add-on package. > >=20 > > Tested end to end on PVE 9.2 (qemu-server 9.2.7 and pve-manager > > 9.2.11 plus the series): a Kubuntu 26.04 guest with > > 'vga: virtio-gl,dbus=3D1' streams 1280x800 at 60 fps (NVENC H.264)=20 > > through webrtcproxy, in a popup and in the VM's Console panel, for a = > > user holding only PVEVMUser on the VM (403 without VM.Console). > >=20 > > Code and measurements: https://github.com/rdmitry0911/qsm-rd > > (qsm-direct/, docs/COMPARISON.md for the numbers; the prepared=20 > > series are in qsm-direct/upstream/patches/). > >=20 > > Transparency: I developed the prototype with the help of an AI=20 > > coding assistant (Claude).=A0 I have reviewed and tested the code = and=20 > > will sign the Harmony CLA; please tell me if that is a problem for=20 > > you. > >=20 > > Thanks, > > Dmitry