Control: retitle -1 udevadm trigger fails in containers with ro /sys Am 17.11.19 um 02:43 schrieb Michael Biebl: > Am 17.11.19 um 01:57 schrieb Jonah BrĂ¼chert: >> After slightly looking into the debos source code it seems also possible >> that it uses a systemd-spawn container in some cases >> (https://github.com/go-debos/debos/blob/2764eed783b1b0ffb5d09f796338f09a4e2594b6/commands.go#L15) > > Can you please verify, what exactly you are using: > A container (systemd-nspawn,...), chroot or something else. > If it's a chroot, it would be good to know how the chroot is setup, > (e.g. which file systems are mounted into the chroot etc).
Assuming you do actually use systemd-nspawn, I think I found the commit which changed the behaviour of udevadm: > commit 97afc0351a96e0daa83964df33937967c75c644f (refs/bisect/bad) > Author: Zbigniew J<C4><99>drzejewski-Szmek <zbys...@in.waw.pl> > Date: Wed Jun 5 09:54:54 2019 +0200 > > udevadm trigger: log errors and return first failure > > When udevadm trigger is called, the list of devices to trigger is always > generated through enumeration, and devices can come and go, so we should > not > treat -ENOENT as a failure. But other types of failure should be logged. > It seems they were logged until baa30fbc2c04b23209d0b8fb3c86cd15ef9ea81a. > > Also, return the first error. (I'm not sure if there are other failure > modes > which we want to ignore. If they are, they'll need to be whitelisted like > -ENOENT.). https://github.com/systemd/systemd/commit/97afc0351a96e0daa83964df33937967c75c644f Whereas with v242 it would log only with debug level priority and return 0, with v243 it now logs with error level priority and returns 1. I assume this change was deliberate. This is unfortunate as we have quite a few packages calling "udevadm trigger" in postinst [1]. So, I think "udevadm trigger" actually behaves properly in a chroot as it becomes a nop there. In a container with a ro /sys it now fails. I just checked and LXC containers are affected as well. Retitling the bug report accordingly. [1] https://codesearch.debian.net/search?q=udevadm+trigger&literal=0 -- Why is it that all of the instruments seeking intelligent life in the universe are pointed away from Earth?
signature.asc
Description: OpenPGP digital signature