Your message dated Mon, 15 Oct 2018 19:34:16 +0000
with message-id <[email protected]>
and subject line Bug#906227: fixed in autopkgtest 5.6
has caused the Debian Bug report #906227,
regarding autopkgtest: cannot reboot a jessie VM (regression in 5.5)
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact [email protected]
immediately.)


-- 
906227: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=906227
Debian Bug Tracking System
Contact [email protected] with problems
--- Begin Message ---
Package: autopkgtest
Version: 5.5
Severity: normal
Tags: patch

When I test packages on Debian jessie with autopkgtest-virt-qemu (actually
a jessie derivative, but I'm fairly sure real jessie would be the same),
rebooting the VM fails with:

    systemd-run: unrecognized option '--no-block'

This appears to have been caused by fixing ci-team/autopkgtest!16 in
5.5: jessie's systemd-run didn't have the --no-block option. It can be
addressed by reverting to the non-systemd mechanism if systemd doesn't
work, as in the attached patch. I'll send a merge request when I have
a bug number for it.

Thanks,
    smcv

-- System Information:
Debian Release: buster/sid
  APT prefers buildd-unstable
  APT policy: (500, 'buildd-unstable'), (500, 'unstable'), (500, 'testing'), 
(500, 'stable'), (1, 'buildd-experimental'), (1, 'experimental')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 4.17.0-1-amd64 (SMP w/4 CPU cores)
Locale: LANG=en_GB.utf8, LC_CTYPE=en_GB.utf8 (charmap=UTF-8), LANGUAGE=en_GB:en 
(charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled

Versions of packages autopkgtest depends on:
ii  apt-utils       1.6.3
ii  libdpkg-perl    1.19.0.5
ii  procps          2:3.3.15-2
ii  python3         3.6.6-1
ii  python3-debian  0.1.32

Versions of packages autopkgtest recommends:
ii  autodep8  0.13

Versions of packages autopkgtest suggests:
pn  lxc               <none>
pn  lxd-client        <none>
ii  ovmf              0~20180803.dd4cae4d-1
ii  qemu-efi-aarch64  0~20180803.dd4cae4d-1
pn  qemu-efi-arm      <none>
ii  qemu-system       1:2.12+dfsg-3
ii  qemu-utils        1:2.12+dfsg-3
ii  schroot           1.6.10-5

-- no debconf information
>From 5f99fb2c2b55acda2dee285f9bc3d135b477a1a0 Mon Sep 17 00:00:00 2001
From: Simon McVittie <[email protected]>
Date: Wed, 15 Aug 2018 16:21:52 +0100
Subject: [PATCH] Restore ability to boot pre-stretch systemd systems

The systemctl in Debian jessie didn't support the --no-block option.

Signed-off-by: Simon McVittie <[email protected]>
---
 lib/VirtSubproc.py | 32 ++++++++++++++++++++++----------
 1 file changed, 22 insertions(+), 10 deletions(-)

diff --git a/lib/VirtSubproc.py b/lib/VirtSubproc.py
index 671a21d..847eac8 100644
--- a/lib/VirtSubproc.py
+++ b/lib/VirtSubproc.py
@@ -309,6 +309,27 @@ def cmd_revert(c, ce):
     return [downtmp]
 
 
+def reboot_testbed():
+    (systemd_check, out, err) = execute_timeout(
+        None, 10, auxverb + ['test', '-d', '/run/systemd/system'],
+        stdout=subprocess.PIPE, stderr=subprocess.PIPE
+    )
+    if systemd_check == 0:
+        reboot_cmd = ['systemd-run', '--no-block', '--quiet', 'sh', '-c', 'sleep 3; reboot']
+        adtlog.debug('rebooting with command: %s' % reboot_cmd)
+        status, out, err = execute_timeout(None, 30, auxverb + reboot_cmd)
+
+        if status == 0:
+            return
+        else:
+            adtlog.debug(
+                'Cannot reboot with %s, trying something else' % reboot_cmd)
+
+    reboot_cmd = ['sh', '-c', '(sleep 3; reboot) >/dev/null 2>&1 &']
+    adtlog.debug('rebooting with command: %s' % reboot_cmd)
+    status, out, err = execute_timeout(None, 30, auxverb + reboot_cmd)
+
+
 def cmd_reboot(c, ce):
     global downtmp
     cmdnumargs(c, ce, 0, 1)
@@ -337,17 +358,8 @@ def cmd_reboot(c, ce):
     if len(c) > 1 and c[1] == 'prepare-only':
         adtlog.info('state saved, waiting for testbed to reboot...')
     else:
-        (systemd_check, out, err) = execute_timeout(
-            None, 10, auxverb + ['test', '-d', '/run/systemd/system'],
-            stdout=subprocess.PIPE, stderr=subprocess.PIPE
-        )
-        if systemd_check == 0:
-            reboot_cmd = ['systemd-run', '--no-block', '--quiet', 'sh', '-c', 'sleep 3; reboot']
-        else:
-            reboot_cmd = ['sh', '-c', '(sleep 3; reboot) >/dev/null 2>&1 &']
+        reboot_testbed()
 
-        adtlog.debug('rebooting with command: %s' % reboot_cmd)
-        execute_timeout(None, 30, auxverb + reboot_cmd)
     caller.hook_wait_reboot()
 
     # restore downtmp
-- 
2.18.0


--- End Message ---
--- Begin Message ---
Source: autopkgtest
Source-Version: 5.6

We believe that the bug you reported is fixed in the latest version of
autopkgtest, which is due to be installed in the Debian FTP archive.

A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to [email protected],
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Paul Gevers <[email protected]> (supplier of updated autopkgtest package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing [email protected])


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

Format: 1.8
Date: Mon, 15 Oct 2018 20:35:36 +0200
Source: autopkgtest
Binary: autopkgtest
Architecture: source
Version: 5.6
Distribution: unstable
Urgency: medium
Maintainer: Debian CI team <[email protected]>
Changed-By: Paul Gevers <[email protected]>
Description:
 autopkgtest - automatic as-installed testing for Debian packages
Closes: 904972 904979 906227
Changes:
 autopkgtest (5.6) unstable; urgency=medium
 .
   [ Simon McVittie ]
   * Restore ability to boot pre-stretch systemd systems (Closes: #906227)
   * runner: Document exit status 8 for "all tests skipped"
   * Implement superficial as a test restriction (Closes: #904979)
   * man page: Document that PASS can now be followed by details too
   * Ignore pycodestyle W504 "line break after binary operator"
   * tests/pycodestyle: Print all warnings before exiting unsuccessfully
   * Fix most pycodestyle warnings for invalid escape sequences
 .
   [ Martin Pitt ]
   * autopkgtest-buildvm-ubuntu-cloud: Drop obsolete Ubuntu release names
   * doc: Clarify scope of tests
   * Adjust lxd Suggests: (LP: #1788040)
 .
   [ Paul Gevers ]
   * doc: deprecate needs-recommends
   * Improve documentation of --no-apt-fallback
   * runner/autopkgtest: improve apt-source for Debian
 .
   [ Antonio Terceiro ]
   * autopkgtest-build-qemu: build VM images with vmdb2 (Closes: #904972)
Checksums-Sha1:
 64034b1e2c6e53e0a0bff7dee10e2a772365d17f 1582 autopkgtest_5.6.dsc
 7504493fce7ffb8c52592b04ccbdf0150512363e 179536 autopkgtest_5.6.tar.xz
Checksums-Sha256:
 844a43f6f1828098afbac88073ed381f030214bad17f9b2713a5b7661b1b6686 1582 
autopkgtest_5.6.dsc
 bb9cc0859dad92de1883361f90f97ea3b29246a98f7e710ea6af4d02b4ef4fd0 179536 
autopkgtest_5.6.tar.xz
Files:
 6fd4389cc71c98c7e8c3c58f175aaa36 1582 devel optional autopkgtest_5.6.dsc
 d41080b438aff3dff5cc64819142ed68 179536 devel optional autopkgtest_5.6.tar.xz

-----BEGIN PGP SIGNATURE-----

iQEzBAEBCAAdFiEEWLZtSHNr6TsFLeZynFyZ6wW9dQoFAlvE3k8ACgkQnFyZ6wW9
dQppcAgAlPKe3SI/La6h/ZPoVmpP3V7N14f/gRPfJohaJsdiIoL2zAo3+K0iMJ+T
9fDZCgu0m6vrq6uN/AhJcEzTasbS7KUh14EQhwOpaVMWwNIz9GVgi+//zqfpCrMN
X5YFp6/z6fo4B6efhSX+u0E0yUqvBTqk49JCBeZhe++OjdmazVltH5EPU+5FfnHp
Adk6ssB2qn9i/Jj3v7oEOCDvjPw/2N+X/5mIr3XE6Kh/XdHnEsVFsRrhmy53u8x+
XhsGaYGyl3wvg+MSp3L7yKA2IIZH++qrRb9WOlsBWRrV2xXpfzampbXcqSBfzvDw
ppo/guv87X8Ifnta6p+VElt9IU6hhA==
=XGq3
-----END PGP SIGNATURE-----

--- End Message ---

Reply via email to