Bug#951257: udevadm: please exit nonzero with "Running in chroot, ignoring request." when /proc is not mounted

Michael Biebl biebl at debian.org
Thu Feb 13 12:39:19 GMT 2020


Am 13.02.20 um 13:29 schrieb Trent W. Buck:
> Package: udev
> Version: 241-7~deb10u3
> Severity: wishlist
> File: /sbin/udevadm
> 
> Packages like udisks2 run "udevadm trigger" in their postinsts.
> When building a Debian Live image, if /proc is mounted in the chroot, all is well.
> When building a Debian Live image, if /proc is NOT mounted in the chroot,
> udevadm gives annoying errors, and the whole build crashes.
> 
> With /proc:
> 
>     root at DESKTOP-P00TKMM:/# udevadm trigger
>     Running in chroot, ignoring request.
>     root at DESKTOP-P00TKMM:/# udevadm control --help
>     Running in chroot, ignoring request.
> 
> Without /proc:
> 
>     root at DESKTOP-P00TKMM:/# udevadm trigger
>     Failed to scan devices: No such file or directory

This means, /sys is missing, not proc afaics.

>     root at DESKTOP-P00TKMM:/# udevadm control --reload
>     root at DESKTOP-P00TKMM:/# echo $?
>     1
> 
> Can you please make udevadm do something like this?
> 
>     printf("/proc is missing or empty.\n")
>     printf("Probably running in a chroot, ignoring request.\n")
>     exit(0)
> 
> It sounds like best current practice is for postinsts to ignore ALL
> errors[0], which (I think) is worse, because udevadm can be smarter
> than the postinst about what is a "real" error.

I guess you'd have to convince upstream that this is a good idea to add
such a check.

Once upstream has such a patch, we can cherry-pick it.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: OpenPGP digital signature
URL: <http://alioth-lists.debian.net/pipermail/pkg-systemd-maintainers/attachments/20200213/e1e33b95/attachment.sig>


More information about the Pkg-systemd-maintainers mailing list