--- Begin Message ---
- To: Debian Bug Tracking System <submit@bugs.debian.org>
- Subject: dropbear-initramfs: race condition prevents launch at boot
- From: Forest <forestix@sonic.net>
- Date: Sun, 16 Aug 2020 12:31:38 -0700
- Message-id: <042jjf99aodjecuehmd4ilumvvdcllopce@4ax.com>
Package: dropbear-initramfs
Version: 2020.80-1
Severity: important
Dear Maintainer,
About four times out of five, dropbear fails to launch at boot on the
RockPro64 single-board computer. When it fails, I see this message
repeated several times, scattered between various other messages on the
serial console:
ipconfig: no devices to configure
Finally, this message appears:
/scripts/init-premount/dropbear: .: line 279:
can't open '/run/net-*.conf': No such file or directory
The system then proceeds to the luks unlock prompt at the serial console
only, with dropbear not running, so the boot process will not continue
unless I connect a serial console and enter the password that way.
I have tried adding all my ethernet-related driver modules to
/etc/initramfs-tools/modules and rebuilding initramfs, but it
didn't help. I have tried using ip= kernel command line arguments
for a static address instead of DHCP, but that didn't help either.
However, editing /usr/share/initramfs-tools/scripts/init-premount/dropbear
does get it working. Making that script wait for a /run/net-*.conf file to
appear before it calls configure_networking appears to be a solution.
Even just sleeping for a few seconds before the configure_networking call
seems to work, though I don't know how consistently.
Based on this workaround and the fact that the aforementioned error messages
are interleaved with other boot messages, it looks to me like dropbear's
init-premount script is being run in parallel with driver and network setup,
and often executing before the rk3399's onboard ethernet has a chance to
finish initializing.
-- System Information:
Debian Release: bullseye/sid
APT prefers testing
APT policy: (500, 'testing')
Architecture: arm64 (aarch64)
Kernel: Linux 5.7.0-2-arm64 (SMP w/6 CPU threads)
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8), LANGUAGE not
set
Shell: /bin/sh linked to /usr/bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled
Versions of packages dropbear-initramfs depends on:
ii busybox 1:1.30.1-5
ii dropbear-bin 2020.80-1
ii initramfs-tools 0.137
ii udev 246-2
Versions of packages dropbear-initramfs recommends:
ii cryptsetup-initramfs 2:2.3.3-1
dropbear-initramfs suggests no packages.
-- Configuration Files:
/etc/dropbear-initramfs/config changed:
DROPBEAR_OPTIONS="-p 222"
-- no debconf information
--- End Message ---
--- Begin Message ---
Source: initramfs-tools
Source-Version: 0.140
Done: Bastian Blank <waldi@debian.org>
We believe that the bug you reported is fixed in the latest version of
initramfs-tools, 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 965935@bugs.debian.org,
and the maintainer will reopen the bug report if appropriate.
Debian distribution maintenance software
pp.
Bastian Blank <waldi@debian.org> (supplier of updated initramfs-tools 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 ftpmaster@ftp-master.debian.org)
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA512
Format: 1.8
Date: Sat, 13 Mar 2021 19:13:18 +0100
Source: initramfs-tools
Architecture: source
Version: 0.140
Distribution: unstable
Urgency: medium
Maintainer: Debian kernel team <debian-kernel@lists.debian.org>
Changed-By: Bastian Blank <waldi@debian.org>
Closes: 965935
Changes:
initramfs-tools (0.140) unstable; urgency=medium
.
[ Norbert Lange ]
* mkinitramfs: use temporary file for uncompressed cpio
.
[ Michael Prokop ]
* mkinitramfs: report actually requested compress util if it's not present
.
[ Ben Hutchings ]
* init: Mount /dev without the noexec option
.
[ dann frazier ]
* configure_networking(): Wait for specified network device (Closes: #965935)
.
[ Bastian Blank ]
* Include all PCI controller modules
* Include all reset controller modules
Checksums-Sha1:
ca9b2b7c1bcd523e6b0d01610a8ffc1f9469d3c9 1599 initramfs-tools_0.140.dsc
503b9ba5619bbb5fc1fefc54148b438517306a2f 95044 initramfs-tools_0.140.tar.xz
98067441d1545346eb097dbc0e8065c3bee85dfd 5816 initramfs-tools_0.140_source.buildinfo
Checksums-Sha256:
5537ff004f5e7fc9be4790a3248664806fa1ae4e5fe05ea47df821be8953aef4 1599 initramfs-tools_0.140.dsc
17ec1b0e5e1c6f8254f2184be780e50c8274f71cdf482e5c46d50f955370685f 95044 initramfs-tools_0.140.tar.xz
82eb6659251b86789c099f0c8f935eeac45c3158ad9a019583071baaf7e012cc 5816 initramfs-tools_0.140_source.buildinfo
Files:
02ccd954ee0094babe87b535f98f2149 1599 utils optional initramfs-tools_0.140.dsc
fd1364cfa57fa3580a70c6acf53b64ae 95044 utils optional initramfs-tools_0.140.tar.xz
162c5689195e92895b38ef34766eb053 5816 utils optional initramfs-tools_0.140_source.buildinfo
-----BEGIN PGP SIGNATURE-----
iQEzBAEBCgAdFiEER3HMN63jdS1rqjxLbZOIhYpp/lEFAmBNAiAACgkQbZOIhYpp
/lFf9AgAkzB4sVAsdAwPFul7jOh+Ocw4eZfHE4K10cAdz2p0tNq5bMipbwCBwLjh
ZvxYmFAcEDQBBCZkdQyWZPrVoiwM73IgU8MTP28MYfO/I2T4/N4cLO1KdUVpbg23
fridBQVl9xmVonmskgbjtQfvP4g0GJvEBcskexwpuTFEuIhFwJ3G2IXFYSkLkO3X
2zUv8jtZ4GpQ674kgK3+aco+IqsfCtD+BSvnpSkttuZdU/GjFsY1puFFceWbx8JU
zozPKEvPEH8mvtk3KenZbCO4jalF3xbhmmU00yHsHXeUlSKotpPyM5DsSaOy9S2D
5slscGKgtoTlxkqaPkcvlsj8JrKivA==
=/SaL
-----END PGP SIGNATURE-----
--- End Message ---