[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

schroot und systemd



Hallo,

ich habe in einer schroot-Definition folgende fstab definiert:

|[14/514]mh@fan:~$ cat /etc/schroot/zg2-kernel/fstab
|# fstab: static file system information for chroots.
|# Note that the mount point will be prefixed by the chroot path
|# (CHROOT_PATH)
|#
|# <file system> <mount point>  <type>  <options> <dump> <pass>
|/proc   /proc  none    rw,rbind        0       0
|/sys   /sys   none    rw,rbind        0       0
|/dev/pts /dev/pts devpts rw,rbind 0 0
|/dev/mapper/kernelhome /home/mh ext4 defaults 0  0

Das führt seit der Umstellung auf systemd als PID 1 beim Beenden des
chroot zu folgender Fehlermeldung:

|[4/504]mh@fan:~$ schroot --end-session --all-sessions --force
| 
|E: 10mount: umount: /var/lib/schroot/mount/kernel/sys/fs/cgroup/systemd: target is busy
|E: 10mount:         (In some cases useful info about processes that
|E: 10mount:          use the device is found by lsof(8) or fuser(1).)
|E: kernel: Chroot setup failed: stage=setup-stop

Wenn ich fuser -m verwende, sehe ich dieselben Prozesse wie auf
/sys/fs/cgroup/systemd. Darunter is PID 1. Die Prozesse abschießen ist
also keine Option.

umount -l funktioniert, jedoch führt der neue Versuch das schroot zu
beenden nun zu einer neuen Fehlermeldung:

|[9/509]mh@fan:~$ schroot --end-session --all-sessions --force
|E: 10mount: rmdir: failed to remove '/var/lib/schroot/mount/kernel': Device or resource busy
|E: kernel: Chroot setup failed: stage=setup-stop

Und hier ist jetzt "game over", denn ich kriegt das Verzeichnis weder
weg noch umbenannt.

Die mit schroot mitkommende fstab sieht so aus:

|[1/501]mh@fan:~$ cat /etc/schroot/minimal/fstab
|# fstab: static file system information for chroots.
|# Note that the mount point will be prefixed by the chroot path
|# (CHROOT_PATH)
|#
|# <file system> <mount point>   <type>  <options>       <dump>  <pass>
|/proc           /proc           none    rw,bind         0       0
|/sys            /sys            none    rw,bind         0       0
|[2/502]mh@fan:~$

Wird bind statt rbind an dieser Stelle besser funktionieren? Oder wie
geh ich mit chroots auf einem systemd-System um, wenn innerhalb des
chroots /sys benötigt wird?

Grüße
Marc

-- 
-----------------------------------------------------------------------------
Marc Haber         | "I don't trust Computers. They | Mailadresse im Header
Leimen, Germany    |  lose things."    Winona Ryder | Fon: *49 6224 1600402
Nordisch by Nature |  How to make an American Quilt | Fax: *49 6224 1600420


Reply to: