From owner-freebsd-current@freebsd.org Sat Nov 10 23:08:04 2018 Return-Path: Delivered-To: freebsd-current@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 21D77110DF1E for ; Sat, 10 Nov 2018 23:08:04 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from kib.kiev.ua (kib.kiev.ua [IPv6:2001:470:d5e7:1::1]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id DB23E80A3A for ; Sat, 10 Nov 2018 23:08:02 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from tom.home (kib@localhost [127.0.0.1]) by kib.kiev.ua (8.15.2/8.15.2) with ESMTPS id wAAN7jQp019412 (version=TLSv1.2 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Sun, 11 Nov 2018 01:07:48 +0200 (EET) (envelope-from kostikbel@gmail.com) DKIM-Filter: OpenDKIM Filter v2.10.3 kib.kiev.ua wAAN7jQp019412 Received: (from kostik@localhost) by tom.home (8.15.2/8.15.2/Submit) id wAAN7imL019411; Sun, 11 Nov 2018 01:07:44 +0200 (EET) (envelope-from kostikbel@gmail.com) X-Authentication-Warning: tom.home: kostik set sender to kostikbel@gmail.com using -f Date: Sun, 11 Nov 2018 01:07:44 +0200 From: Konstantin Belousov To: Guido Falsi Cc: freebsd-current@freebsd.org Subject: Re: 13.0 failing to boot multiuser on one PC due to system utilities crashing during rc scipt Message-ID: <20181110230744.GN2378@kib.kiev.ua> References: <62bdb5ff-4d68-cf52-4dd5-f0a3cfa1c788@madpilot.net> <791e3488-b838-5cfd-8dca-8db8c74167a0@madpilot.net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <791e3488-b838-5cfd-8dca-8db8c74167a0@madpilot.net> User-Agent: Mutt/1.10.1 (2018-07-13) X-Spam-Status: No, score=-1.0 required=5.0 tests=ALL_TRUSTED,BAYES_00, DKIM_ADSP_CUSTOM_MED,FORGED_GMAIL_RCVD,FREEMAIL_FROM, NML_ADSP_CUSTOM_MED autolearn=no autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on tom.home X-Rspamd-Queue-Id: DB23E80A3A X-Spamd-Result: default: False [-4.86 / 200.00]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-1.00)[-1.000,0]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; FREEMAIL_FROM(0.00)[gmail.com]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; MIME_GOOD(-0.10)[text/plain]; HAS_XAW(0.00)[]; R_SPF_SOFTFAIL(0.00)[~all]; RCVD_COUNT_THREE(0.00)[3]; TO_MATCH_ENVRCPT_SOME(0.00)[]; MX_GOOD(-0.01)[cached: alt3.gmail-smtp-in.l.google.com]; RCPT_COUNT_TWO(0.00)[2]; NEURAL_HAM_SHORT(-0.93)[-0.933,0]; IP_SCORE(-1.92)[ip: (-1.57), ipnet: 2001:470::/32(-4.43), asn: 6939(-3.49), country: US(-0.09)]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(0.00)[]; FREEMAIL_ENVFROM(0.00)[gmail.com]; ASN(0.00)[asn:6939, ipnet:2001:470::/32, country:US]; RCVD_TLS_LAST(0.00)[]; DMARC_POLICY_SOFTFAIL(0.10)[gmail.com : No valid SPF, No valid DKIM,none] X-Rspamd-Server: mx1.freebsd.org X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 10 Nov 2018 23:08:04 -0000 On Sat, Nov 10, 2018 at 05:27:09PM +0100, Guido Falsi wrote: > On 10/11/18 13:08, Guido Falsi wrote: > > Hi, > > > > Today I was updating my home machines to recent head, r340303. > > Previously I was running r339449. > > > > I have a build machine where I build base packages (and also runs > > poudriere). I updated that machine using packages I built successfully. > > it is running fine and also successfully rebuilt a full ports package > > set on the new head. > > > > After that I upgraded, using the same package set, another machine, a PC > > from around three years ago with an i5. After upgrade the kernel boots > > fine but when running the rc script to go multiuser some system > > utilities fail, especially zfs, making it impossible for the machine to > > complete the boot process. > > > > I have tested booting from the memstick snapshot images, I tested: > > > > FreeBSD-13.0-CURRENT-amd64-20181107-r340239-memstick.img > > FreeBSD-13.0-CURRENT-amd64-20181101-r339979-memstick.img > > > > and both are also failing to go multiuser. The utility failing in this > > case is fsck, which, like zfs before, dumps core. > > > > I see a pattern where only disk related utilities crash. > > > > The 12.0-BETA4 installation memstick works fine though. > > > > So clearly something changed between r339449 and r340303 which causes > > incompatibility with my hardware. > > > > I'll to bisect things, but it will be a slow process. > > I narrowed it down to r339895. I somehow doubt that this is the case. If you take post-r339895 kernel and start e.g. 11.2-RELEASE userspace (untar the installation into jail to avoid reinstallation), does it still demonstrate the behaviour ? Also try to run pre-r339895 with the 12.0 userspace from e.g. 12.0-BETA4 builds. > > I'm not sure why it fails, it goes beyond my knowledge, the change looks > unharmful, but clearly isn't. Usually it means that the bisect went wrong and your environment failed to cleanly isolate the change. > > My impression is that the other conditions not moved inside the ifunc > also play a role so such optimization is not possible on all systems. > > > > > I have put dmesg and pciconf output here in case it could be useful: > > > > https://people.freebsd.org/~madpilot/boot_fail/ This is haswell, right ? It is exactly the same micro-arch as the machine where I tested this series of changes.