Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.debian.kernel > #67262 > unrolled thread

Bug#962545: Invalid serial console blocks system boot

Started by"Guilherme G. Piccoli" <gpiccoli@canonical.com>
First post2020-06-09 20:30 +0200
Last post2020-09-11 22:40 +0200
Articles 2 — 2 participants

Back to article view | Back to linux.debian.kernel


Contents

  Bug#962545: Invalid serial console blocks system boot "Guilherme G. Piccoli" <gpiccoli@canonical.com> - 2020-06-09 20:30 +0200
    Bug#962545: marked as done (Invalid serial console blocks system  boot) "Debian Bug Tracking System" <owner@bugs.debian.org> - 2020-09-11 22:40 +0200

#67262 — Bug#962545: Invalid serial console blocks system boot

From"Guilherme G. Piccoli" <gpiccoli@canonical.com>
Date2020-06-09 20:30 +0200
SubjectBug#962545: Invalid serial console blocks system boot
Message-ID<AfRay-4Mq-7@gated-at.bofh.it>
Package: initramfs-tools
Version: 0.137
Followup-For: Bug #960355

Hi Ben and Jonas, I was reporting a similar bug and found this one, thanks
to reportbug!

So, I think this is indeed a bug. The problem was vastly debugged in a
recent Launchpad issue [0], I'll give a summary here.
Currently, _log_msg() is like a void-typed function, with no return. If the
parameter "quiet" is not provided, there's a printf and then the function
returns, which in shell language means the printf return is carried over
to the caller of _log_msg().

Problem is: checkfs() makes use of error log functions, which in the end
rely on _log_msg(). If "quiet" is not supplied, and the filesystem is not
set to fsck on boot (i.e., fsck is not included in the initrd), when the
bad console is provided, an error message on checkfs_once() will eventually
reach the printf on _log_msg(), causing checkfs_once() to "inherit" the bad
return from printf.
The big issue comes now: checkfs() runs a loop, and given in this corner
case checkfs_once() returns an error state, the loop goes on forever,
effectively preventing the boot.

I consider this a bug specially because we had reports of cases in which
the serial console was working...but after a (virtual) HW update the
serial port changed, hence introducing such boot loop.

I've proposed a really simple fix in the following merge request:
salsa.debian.org/kernel-team/initramfs-tools/-/merge_requests/30

One could argue the problem is on checkfs() and we could fix there.
I disagree, I think in no way an error log message should prevent boot or
induce such errors by carrying over a bad result due to invalid console.
Also, we could rethink printf returning error in case of bad console,
but this is/will be a long-term discussion, no quick fix will outcome
from there, so I'd rather have it fixed now if possible.

Cheers,


Guilherme


[0] bugs.launchpad.net/bugs/1573095


-- System Information:
Debian Release: stretch/sid
Architecture: amd64 (x86_64)

[toc] | [next] | [standalone]


#68103 — Bug#962545: marked as done (Invalid serial console blocks system boot)

From"Debian Bug Tracking System" <owner@bugs.debian.org>
Date2020-09-11 22:40 +0200
SubjectBug#962545: marked as done (Invalid serial console blocks system boot)
Message-ID<ANXZT-86k-25@gated-at.bofh.it>
In reply to#67262

[Multipart message — attachments visible in raw view] — view raw

Your message dated Fri, 11 Sep 2020 20:36:04 +0000
with message-id <E1kGpm8-000IoH-2Y@fasolo.debian.org>
and subject line Bug#960355: fixed in initramfs-tools 0.138
has caused the Debian Bug report #960355,
regarding Invalid serial console blocks system boot
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 owner@bugs.debian.org
immediately.)


-- 
960355: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=960355
Debian Bug Tracking System
Contact owner@bugs.debian.org with problems

[toc] | [prev] | [standalone]


Back to top | Article view | linux.debian.kernel


csiph-web