Control: tag -1 +confirmed Control: tag -1 +help On Thu, 2021-03-04 at 09:40 +0900, Ryutaroh Matsumoto wrote: > > What should be the steps to reproduce this bug on my machine using > > debci/autopkgtest ? > > (Assuming you are using Debian Bullseye amd64.) > > # debci setup -f -b qemu -a amd64 -s sid > The above will create /var/lib/debci/qemu/sid-amd64.img > "debci setup" sometimes fails, in such a case please retry... > > The above image has /sbin/init==systemd-sysv, of course. > As open-iscsi has no problem with /sbin/init==systemd-sysv, > We need to replace it with sysvinit-core in the VM image. > > # apt-get --install-recommends install virt-manager > # cp /var/lib/debci/qemu/sid-amd64.img /var/lib/libvirt/images > # virt-manager (this can be run by an ordinary user belonging to > libvirt group) > > Start VM on /var/lib/libvirt/images/sid-amd64.img > Login as root (no password) into the Linux running on VM. > on-VM# apt-get install sysvinit-core > on-VM# echo "S0:2345:respawn:/sbin/getty -L ttyS0 115200 vt100" > >>/etc/inittab > on-VM# shutdown -h -P now > > /var/lib/libvirt/images/sid-amd64.img should have > /sbin/init==sysvinit-core now. > > autopkgtest -B -u debci -o some-dir-for-logging open-iscsi -- qemu -- > debug --show-boot /var/lib/libvirt/images/sid-amd64.img > The test should get stuck at apt-get install open-iscsi...
I figured it out what the problem is. I'm fairly confident that the problem lies in the deb-systemd-helper tools that generates the following script (full generated script attached) ``` # Automatically added by dh_systemd_enable/13.3.3 if [ "$1" = "configure" ] || [ "$1" = "abort- upgrade" ] || [ "$1" = "abort-deconfigure" ] || [ "$1" = "abort- remove" ] ; then # This will only remove masks created by d-s- h on package removal. deb-systemd-helper unmask 'open- iscsi.service' >/dev/null || true # was- enabled defaults to true, so new installations run enable. if deb-systemd-helper --quiet was-enabled 'open- iscsi.service'; then # Enables the unit on first installation, creates new # symlinks on upgrades if the unit file has changed. deb-systemd-helper enable 'open- iscsi.service' >/dev/null || true else # Update the statefile to add new symlinks (if any), wh ich need to be # cleaned up on purge. Also remove old symlinks. deb-systemd-helper update-state 'open- iscsi.service' >/dev/null || true fi fi # End automatically added section ``` Please check my screenshot where the invocation of this tool is overridden and the overall installation completes immediately. Now, dh-systemd-helper tool written in perl, is not something I want to debug further. Because neither am I well versed with perl nor systemd. SO any help there is welcome. Bug has been tagged appropriately. @Ryutaroh: Thank you for finding and reporting the bug and having the patience with me. Working on this bug, with you, made me learn a couple of new things. :-) -- Ritesh Raj Sarraf | http://people.debian.org/~rrs Debian - The Universal Operating System
open-iscsi.postinst
Description: application/shellscript
signature.asc
Description: This is a digitally signed message part