You are not logged in.

#1 2020-04-02 02:08:04

memeplex
Member
Registered: 2008-11-10
Posts: 33

[SOLVED] Screen sharing broken in Wayland

I know this is a recurrent topic, but I think I've already done everything that has to be done [1] in order to get screen sharing under Wayland working, or kinda working, but to no avail.

Concretely:

  • I'm trying to share my screen from Google Meet in Chromium.

  • I have one single screen, built in my laptop.

  • pipewire is 0.3.2-1

  • xdg-desktop portal is 1.6.0-2

  • chromium is 80.0.3987.149-1

  • chrome://flags/#enable-webrtc-pipewire-capturer is enabled

  • I'm successfully running https://gitlab.gnome.org/snippets/39

  • In Meet the portal dialog is open, I allow to share my screen but I see no snapshot to select afterwards, the Meet dialog is just blank until I hover it to reveal a square, I can select the square and then the portal dialog is open again as expected, but giving it share permission only shows a black screen or immediately aborts sharing.

I should also mention that

systemctl --user status pipewire.service

shows messages like the following ones:

● pipewire.service - Multimedia Service
     Loaded: loaded (/usr/lib/systemd/user/pipewire.service; disabled; vendor preset: enabled)
     Active: active (running) since Wed 2020-04-01 19:31:08 -03; 3h 31min ago
TriggeredBy: ● pipewire.socket
   Main PID: 4102 (pipewire)
     CGroup: /user.slice/user-1000.slice/user@1000.service/pipewire.service
             ├─4102 /usr/bin/pipewire
             └─4104 exec pipewire-media-session

abr 01 22:02:11 carlos pipewire[4102]: [W][000011009.665681][module-protocol-native.c:370 client_new()] server 0x55be73440ad0: no peersec: Protocol not available
abr 01 22:02:11 carlos pipewire[4102]: [E][000011009.665755][module-access.c:91 check_flatpak()] failed to open "/proc/1292/root": Permission denied
abr 01 22:02:11 carlos pipewire[4102]: [W][000011009.665764][module-access.c:165 context_check_access()] module 0x55be73448730: client 0x55be73765080 sandbox check failed: Permission denied
abr 01 22:02:11 carlos pipewire[4102]: [W][000011009.701670][module-protocol-native.c:370 client_new()] server 0x55be73440ad0: no peersec: Protocol not available
abr 01 22:02:11 carlos pipewire[4102]: [W][000011009.702539][impl-client.c:608 pw_impl_client_update_permissions()] client 0x55be73bba080: invalid global 671101152
abr 01 22:47:29 carlos pipewire[4102]: [W][000013728.272901][module-protocol-native.c:370 client_new()] server 0x55be73440ad0: no peersec: Protocol not available
abr 01 22:47:29 carlos pipewire[4102]: [E][000013728.273000][module-access.c:91 check_flatpak()] failed to open "/proc/1292/root": Permission denied
abr 01 22:47:29 carlos pipewire[4102]: [W][000013728.273015][module-access.c:165 context_check_access()] module 0x55be73448730: client 0x55be73765080 sandbox check failed: Permission denied
abr 01 22:47:29 carlos pipewire[4102]: [W][000013728.342358][module-protocol-native.c:370 client_new()] server 0x55be73440ad0: no peersec: Protocol not available
abr 01 22:47:29 carlos pipewire[4102]: [W][000013728.343581][impl-client.c:608 pw_impl_client_update_permissions()] client 0x55be7377c4e0: invalid global 604319056

That said, I'm not sure whether that is important or not, because when running the test script https://gitlab.gnome.org/snippets/39 those message are also shown and, nevertheless, the script runs just fine.

Any help will be appreciated. Thank you in advance.

[1] As explained in https://jgrulich.cz/2019/08/01/tutorial … tation-30/ and elsewhere.

Last edited by memeplex (2020-04-04 02:21:09)

Offline

#2 2020-04-02 03:08:52

memeplex
Member
Registered: 2008-11-10
Posts: 33

Re: [SOLVED] Screen sharing broken in Wayland

I've enabled further debug info for pipewire.

Here is the output I get from the failed screen sharing:

[W][000016125.318252][module-protocol-native.c:370 client_new()] server 0x5560f80bdad0: no peersec: Protocol not available
[I][000016125.318309][module-access.c:134 context_check_access()] client 0x5560f83f23a0 has trusted pid 111489
[E][000016125.318325][module-access.c:91 check_flatpak()] failed to open "/proc/111489/root": Permission denied
[W][000016125.318332][module-access.c:165 context_check_access()] module 0x5560f80c5730: client 0x5560f83f23a0 sandbox check failed: Permission denied
[I][000016125.319186][impl-node.c:713 check_properties()] node 0x5560f83c8a50: name 'meta-screen-cast-src'
[I][000016125.319199][impl-node.c:732 check_properties()] node 0x5560f83c8a50: driver 0 -> 1
[W][000016125.339223][module-protocol-native.c:370 client_new()] server 0x5560f80bdad0: no peersec: Protocol not available
[I][000016125.339242][module-access.c:134 context_check_access()] client 0x5560f819b160 has trusted pid 112994
[W][000016125.339615][impl-client.c:608 pw_impl_client_update_permissions()] client 0x5560f819b160: invalid global 805322432
[I][000016125.460309][module-protocol-native.c:288 connection_data()] protocol-native 0x5560f80bd640: client 0x5560f83f23a0 disconnected

Here is the output I get from the successful python script:

[W][000016163.074871][module-protocol-native.c:370 client_new()] server 0x5560f80bdad0: no peersec: Protocol not available
[I][000016163.074901][module-access.c:134 context_check_access()] client 0x5560f83f20b0 has trusted pid 111489
[E][000016163.074927][module-access.c:91 check_flatpak()] failed to open "/proc/111489/root": Permission denied
[W][000016163.074937][module-access.c:165 context_check_access()] module 0x5560f80c5730: client 0x5560f83f20b0 sandbox check failed: Permission denied
[I][000016163.079884][impl-node.c:713 check_properties()] node 0x5560f83c8a50: name 'meta-screen-cast-src'
[I][000016163.079907][impl-node.c:732 check_properties()] node 0x5560f83c8a50: driver 0 -> 1
[W][000016163.114554][module-protocol-native.c:370 client_new()] server 0x5560f80bdad0: no peersec: Protocol not available
[I][000016163.114575][module-access.c:134 context_check_access()] client 0x5560f83fa200 has trusted pid 112994
[W][000016163.115026][impl-client.c:608 pw_impl_client_update_permissions()] client 0x5560f83fa200: invalid global 805309920
[I][000016163.134144][impl-node.c:713 check_properties()] node 0x5560f81929a0: name 'python'
[I][000016163.138702][policy-node.c:463 rescan_node()] policy-node 0x55dc076285e0: exclusive:0
[I][000016163.138720][policy-node.c:468 rescan_node()] policy-node 0x55dc076285e0: target:61
[I][000016163.138846][impl-node.c:666 pw_impl_node_set_driver()] node 0x5560f81929a0: driver 0x5560f83c8a50 (meta-screen-cast-src) master:0

Offline

#3 2020-04-04 02:12:34

memeplex
Member
Registered: 2008-11-10
Posts: 33

Re: [SOLVED] Screen sharing broken in Wayland

Ok, according to Chromium developers (https://bugs.chromium.org/p/chromium/is … id=1067113) this is because Chromium is using PipeWire 0.2 while Arch is currently shipping 0.3. This is not a specific problem of Arch being too bleeding edge, indeed Fedora 32 (beta) is also shipping 0.3. Ubuntu 19.10 provides 0.2 but its support is broken otherwise, maybe the portal is not working or whatever. All in all, support from Chromium is precary and broken in all major distros as of today, and support from Firefox is non-existent except for a patched version provided by Fedora.

Last edited by memeplex (2020-04-04 14:22:28)

Offline

#4 2020-04-04 10:18:28

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 10,871

Re: [SOLVED] Screen sharing broken in Wayland

Arch ships pipewire 0.2 specifically for chromium

pacman -Qi chromium wrote:

Optional Deps   : pepper-flash: support for Flash content [installed]
                  libpipewire02: WebRTC desktop sharing under Wayland
                  kdialog: needed for file dialogs in KDE [installed]
                  org.freedesktop.secrets: password storage backend on GNOME / Xfce [installed]
                  kwallet: for storing passwords in KWallet on KDE desktops [installed]

Offline

#5 2020-04-04 13:47:27

memeplex
Member
Registered: 2008-11-10
Posts: 33

Re: [SOLVED] Screen sharing broken in Wayland

Thank you V1del, but you can read in the report I opened in Chromium bug tracker that I indeed tested that with no luck, although I wasn't aware that it's provided specifically for this use case. Should it work when the service and the portal are running against 0.3? Seems like it should but it doesn't for me.

Offline

#6 2020-04-04 14:20:49

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 10,871

Re: [SOLVED] Screen sharing broken in Wayland

well you will have to install libpipewire02 at the very least, is that the case and it doesn't work?

Offline

#7 2020-04-04 14:22:10

memeplex
Member
Registered: 2008-11-10
Posts: 33

Re: [SOLVED] Screen sharing broken in Wayland

Ok, I tried it again and now it's working fine. It might be that I'd been testing many different things (including some downgrades) at the time and maybe the involved parts weren't in a consistent state when I installed libpipewire02. Thank you again!

Offline

Board footer

Powered by FluxBB