NetBSD Problem Report #56061

From www@netbsd.org  Tue Mar 16 17:56:50 2021
Return-Path: <www@netbsd.org>
Received: from mail.netbsd.org (mail.netbsd.org [199.233.217.200])
	(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits))
	(Client CN "mail.NetBSD.org", Issuer "mail.NetBSD.org CA" (not verified))
	by mollari.NetBSD.org (Postfix) with ESMTPS id D134B1A9217
	for <gnats-bugs@gnats.NetBSD.org>; Tue, 16 Mar 2021 17:56:49 +0000 (UTC)
Message-Id: <20210316175648.5EA9A1A9239@mollari.NetBSD.org>
Date: Tue, 16 Mar 2021 17:56:48 +0000 (UTC)
From: jsarkes@gmail.com
Reply-To: jsarkes@gmail.com
To: gnats-bugs@NetBSD.org
Subject: crash on first boot of live usbdisk
X-Send-Pr-Version: www-1.0

>Number:         56061
>Category:       install
>Synopsis:       crash on first boot of live usbdisk
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    install-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Tue Mar 16 18:00:00 +0000 2021
>Last-Modified:  Thu Mar 18 01:20:00 +0000 2021
>Originator:     Joseph Sarkes
>Release:        current
>Organization:
none
>Environment:
sorry, away from machine. old toshiba sattelite laptop
>Description:
upon first boot of the live filesystem the root fs is resized to cover the entire usb stick. this part works and writes back, all seems fine.
next step i think it is trying to reboot and ends up in the kernel debugger.  this should not occur. upon reboot manually it worked fine with the full stick as root.
i hope this enough info. i have yet to try the install usb but i do not
expect that root to be resized so likely no problem. i'll try to check this out later.

as am aside, likely also deserving a separate pr.  the live usb stick 
and i think the install one also can not be accessed using disklabel.
if memory serves the "latest" and "current" sticks had different fdisk
partition id's, gpt and netbsd partitions respectively, disklabel not 
able to work with either one, but they work to boot into and mount
the filesystem. the gpt in "latest" could be read but not the current
one. this may not matter one whit, as long as things mount and are
useable but it is inconsistant.


>How-To-Repeat:
should just take the live .gz file, uncompress and dd onto a stick that is larger than the file. then boot it and let it resize.
>Fix:
unknown. this may already be in the works or totally nonsequitor if 
nobody uses the live filesystem.

>Audit-Trail:
From: Martin Husemann <martin@duskware.de>
To: gnats-bugs@netbsd.org
Cc: 
Subject: Re: install/56061: crash on first boot of live usbdisk
Date: Tue, 16 Mar 2021 19:09:38 +0100

 On Tue, Mar 16, 2021 at 06:00:01PM +0000, jsarkes@gmail.com wrote:
 > upon first boot of the live filesystem the root fs is resized to cover the entire usb stick. this part works and writes back, all seems fine.
 > next step i think it is trying to reboot and ends up in the kernel debugger.

 Please provide more details here. We need the last few lines of output
 before entering the debugger, there should be a

 panic: ....

 line that gives the most important infos, followed by a stack trace
 from the debugger. Without this, we can not really help without that
 exact hardware.

 It would also be nice to know which image exactly (URL) you are using.

 I failed to parse the disklabel part of the report, and it definitively
 should be discussed elsewhere (e.g. on the current-users or netbsd-users
 mailing list, I'm not sure it needs a separate PR).

 Martin

From: Andreas Gustafsson <gson@gson.org>
To: gnats-bugs@netbsd.org
Cc: 
Subject: Re: install/56061: crash on first boot of live usbdisk
Date: Wed, 17 Mar 2021 11:35:10 +0200

 jsarkes@gmail.com wrote:
 > upon first boot of the live filesystem the root fs is resized to
 > cover the entire usb stick. this part works and writes back, all
 > seems fine.  next step i think it is trying to reboot and ends up in
 > the kernel debugger.

 Perhaps this is manifestation of PR 55393, "System booted from USB
 panics on shutdown".
 -- 
 Andreas Gustafsson, gson@gson.org

From: Joseph Sarkes <jsarkes@gmail.com>
To: gnats-bugs@netbsd.org
Cc: 
Subject: Re: install/56061: crash on first boot of live usbdisk
Date: Wed, 17 Mar 2021 20:17:31 -0400

 version is a successful build of current Netbsd-9.99.81 (moving
 towards 10.0?)  that looks ok so far to me. however trying the live
 image, issues arrive on both my toshiba laptop p755 and a dell desktop
 optiplex 780 (on which i had to boot with acpi disabled).
 all looks fine with the green kernel messages until the white script?
 stuff starts. it wants to resize root  (sd0) and successfully does
 this as it works afterwards with the correct size etc.
 however after the resize the kernel crashes. i have no second machine
 or serial terminal capability so i am typing from 3.5 cards here.
 growing sd0 disklabel
 1907MB -> 29328MB
 resizing / (/dev/sd0a)
 lotsa dots
 reboot: rebooted by root
 sd0(umass0:0:0:0) generic HBA error
 sd0:cache synchronization failed
 fatal page fault in supervisor mode
 trap type 6 code 0x10 rip0 cs 0x8 rflags 0x10286 cr2 0 ilevel 0x5 rsp
 0xffffad808a0f1f38
 curlwp 0xffffa6ddc66f54c0
 kernel: page fault trap code=0
 stopped in pid 0.6 (system) at netbsd:disasm+0x8f .....

 anyways it seems apparent to me this is a problem with rebooting after
 messing with the filesystem and it goes bonkers trying to sync to
 boot? there is no swap at this time and the filesystem is still read
 only. hope this guides someone to a fix or just put up a message
 regarding the live filesystem that after resize you need to power
 cycle the machine as it won't reboot on its own properly. things
 startup ok after the resize.

 any other info i can pursue for you let me know.

 On 3/16/21, Martin Husemann <martin@duskware.de> wrote:
 > The following reply was made to PR install/56061; it has been noted by
 > GNATS.
 >
 > From: Martin Husemann <martin@duskware.de>
 > To: gnats-bugs@netbsd.org
 > Cc:
 > Subject: Re: install/56061: crash on first boot of live usbdisk
 > Date: Tue, 16 Mar 2021 19:09:38 +0100
 >
 >  On Tue, Mar 16, 2021 at 06:00:01PM +0000, jsarkes@gmail.com wrote:
 >  > upon first boot of the live filesystem the root fs is resized to cover
 > the entire usb stick. this part works and writes back, all seems fine.
 >  > next step i think it is trying to reboot and ends up in the kernel
 > debugger.
 >
 >  Please provide more details here. We need the last few lines of output
 >  before entering the debugger, there should be a
 >
 >  panic: ....
 >
 >  line that gives the most important infos, followed by a stack trace
 >  from the debugger. Without this, we can not really help without that
 >  exact hardware.
 >
 >  It would also be nice to know which image exactly (URL) you are using.
 >
 >  I failed to parse the disklabel part of the report, and it definitively
 >  should be discussed elsewhere (e.g. on the current-users or netbsd-users
 >  mailing list, I'm not sure it needs a separate PR).
 >
 >  Martin
 >
 >

From: Joseph Sarkes <jsarkes@gmail.com>
To: gnats-bugs@netbsd.org
Cc: 
Subject: Re: install/56061: crash on first boot of live usbdisk
Date: Wed, 17 Mar 2021 21:14:57 -0400

 --000000000000a5a09905bdc554d3
 Content-Type: text/plain; charset="UTF-8"

 Shutdown after forced first reboot seems fine. Likely a different issue.
 This is a crash after root filesystem
 resize.

 On Wed, Mar 17, 2021, 5:40 AM Andreas Gustafsson <gson@gson.org> wrote:

 > The following reply was made to PR install/56061; it has been noted by
 > GNATS.
 >
 > From: Andreas Gustafsson <gson@gson.org>
 > To: gnats-bugs@netbsd.org
 > Cc:
 > Subject: Re: install/56061: crash on first boot of live usbdisk
 > Date: Wed, 17 Mar 2021 11:35:10 +0200
 >
 >  jsarkes@gmail.com wrote:
 >  > upon first boot of the live filesystem the root fs is resized to
 >  > cover the entire usb stick. this part works and writes back, all
 >  > seems fine.  next step i think it is trying to reboot and ends up in
 >  > the kernel debugger.
 >
 >  Perhaps this is manifestation of PR 55393, "System booted from USB
 >  panics on shutdown".
 >  --
 >  Andreas Gustafsson, gson@gson.org
 >
 >

 --000000000000a5a09905bdc554d3
 Content-Type: text/html; charset="UTF-8"
 Content-Transfer-Encoding: quoted-printable

 <div dir=3D"auto">Shutdown after forced first reboot seems fine. Likely a d=
 ifferent issue.<div dir=3D"auto">This is a crash after root filesystem=C2=
 =A0</div><div dir=3D"auto">resize.</div></div><br><div class=3D"gmail_quote=
 "><div dir=3D"ltr" class=3D"gmail_attr">On Wed, Mar 17, 2021, 5:40 AM Andre=
 as Gustafsson &lt;<a href=3D"mailto:gson@gson.org">gson@gson.org</a>&gt; wr=
 ote:<br></div><blockquote class=3D"gmail_quote" style=3D"margin:0 0 0 .8ex;=
 border-left:1px #ccc solid;padding-left:1ex">The following reply was made t=
 o PR install/56061; it has been noted by GNATS.<br>
 <br>
 From: Andreas Gustafsson &lt;<a href=3D"mailto:gson@gson.org" target=3D"_bl=
 ank" rel=3D"noreferrer">gson@gson.org</a>&gt;<br>
 To: <a href=3D"mailto:gnats-bugs@netbsd.org" target=3D"_blank" rel=3D"noref=
 errer">gnats-bugs@netbsd.org</a><br>
 Cc: <br>
 Subject: Re: install/56061: crash on first boot of live usbdisk<br>
 Date: Wed, 17 Mar 2021 11:35:10 +0200<br>
 <br>
 =C2=A0<a href=3D"mailto:jsarkes@gmail.com" target=3D"_blank" rel=3D"norefer=
 rer">jsarkes@gmail.com</a> wrote:<br>
 =C2=A0&gt; upon first boot of the live filesystem the root fs is resized to=
 <br>
 =C2=A0&gt; cover the entire usb stick. this part works and writes back, all=
 <br>
 =C2=A0&gt; seems fine.=C2=A0 next step i think it is trying to reboot and e=
 nds up in<br>
 =C2=A0&gt; the kernel debugger.<br>
 <br>
 =C2=A0Perhaps this is manifestation of PR 55393, &quot;System booted from U=
 SB<br>
 =C2=A0panics on shutdown&quot;.<br>
 =C2=A0-- <br>
 =C2=A0Andreas Gustafsson, <a href=3D"mailto:gson@gson.org" target=3D"_blank=
 " rel=3D"noreferrer">gson@gson.org</a><br>
 <br>
 </blockquote></div>

 --000000000000a5a09905bdc554d3--

NetBSD Home
NetBSD PR Database Search

(Contact us) $NetBSD: query-full-pr,v 1.46 2020/01/03 16:35:01 leot Exp $
$NetBSD: gnats_config.sh,v 1.9 2014/08/02 14:16:04 spz Exp $
Copyright © 1994-2020 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.