<div dir="ltr"><div class="gmail_quote"><div dir="ltr">On Thu, Jul 5, 2018 at 1:13 PM Michael Biebl <<a href="mailto:mbiebl@gmail.com">mbiebl@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi,<br>
<br>
in the latest upower release 0.99.8, the systemd service file was<br>
locked down considerably[1]. Unfortunately, a result of that is, that<br>
upower no longer detects any plug/unplug events [2].<br>
Through some trial and error I found that it's the addition of<br>
PrivateNetworks=true which broke upower.<br>
Now I'm a bit puzzled why upower would need network to function properly.<br></blockquote><div><br></div><div>Plug/unplug events are device uevents sent via AF_NETLINK socket. If you have PrivateNetworks=true, upower gets its own network namespace and is isolated from anything that udev (re)sends in the main namespace.</div><div><br></div><div>(Looks like namespaces can still receive the original kernel-generated uevents, but without the extra information that udev attaches to retransmitted ones – that's probably not enough for libudev to work. Compare `udevadm monitor -p` vs `unshare --net udevadm monitor -p`.)</div></div><div><br></div>-- <br><div dir="ltr" class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr">Mantas Mikulėnas</div></div></div>