From nobody Thu Jan 27 13:57:03 2022 X-Original-To: freebsd-stable@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id E9AF9197BCF0 for ; Thu, 27 Jan 2022 13:57:06 +0000 (UTC) (envelope-from uqs@freebsd.org) Received: from smtp.freebsd.org (smtp.freebsd.org [96.47.72.83]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "smtp.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Jl2Ft6PDSz3HCs for ; Thu, 27 Jan 2022 13:57:06 +0000 (UTC) (envelope-from uqs@freebsd.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1643291826; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type; bh=IdlfUCDNQePYR6m3vZf6wILWgBfGJLbjFmKqzW3Zd6Q=; b=RAJHG8yHis4LJgSjADgro03vthossEJbAuTEPc77xT6eDzuGh7Hb0QK9EzUc+SfXhlDUyz 6TSaeQXIcSqsN3pdfzlH7JjXjkX6agqta1u+njLT1O5E7+hmE5AzGFXlhTk/BfMk3zzdQr bbSkqJnX9LcibXI4Yzy2ATOLOjMquwLqzgYm59j458L/NOyLCFPEs3vCAExmhX3xpvlD4V cpk0YCc6s3AAnQGCdK/Do7cqVzDEjQdpwP6qZjz/MChr8tvlyBWvOo4F74me57p3GR5WEx jEkEKQX1OYzkLJf3ytQrCNuKhOSOEB8NWTdQYr9zo9RzIIFRu3KDOZLqPY6X2A== Received: from localhost (acme.spoerlein.net [IPv6:2a05:fc87:1:5::15]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) (Authenticated sender: uqs/mail) by smtp.freebsd.org (Postfix) with ESMTPSA id 6FE39272B for ; Thu, 27 Jan 2022 13:57:06 +0000 (UTC) (envelope-from uqs@freebsd.org) Date: Thu, 27 Jan 2022 14:57:03 +0100 From: Ulrich =?utf-8?B?U3DDtnJsZWlu?= To: freebsd-stable@freebsd.org Subject: gptzfsboot can't boot from 4TB SSD Message-ID: Mail-Followup-To: freebsd-stable@freebsd.org List-Id: Production branch of FreeBSD source code List-Archive: https://lists.freebsd.org/archives/freebsd-stable List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-stable@freebsd.org X-BeenThere: freebsd-stable@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Disposition: inline User-Agent: Mutt/2.0.6 (2021-03-06) ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1643291826; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type; bh=IdlfUCDNQePYR6m3vZf6wILWgBfGJLbjFmKqzW3Zd6Q=; b=OmQfR4fpkFDhg5irx1sI9QBwxOeLpyBDnFVgpqU0pl4pepVAnLGHF4IEjUOjeTlSBquZor B+otwCl8CilcYK7Bm3vUmQc7PSQnd3/JEPSqp8epHQiLeP7n909lU5fJSmAxekz2/kzkqO 0I+r/AR9LY0Iuj8dYv3fyuDrLSbZYKF1D8ivY7Bhh4kHKMpwlcCEQUOhtyj6VKZLUBwFuy AVLFINQNt9TpJAPOjVcsYg3DKhC2y4dcplPtsR5aYPXlJKSrMaGKmMNc48KXzjUl9RoKo0 S+rsTbJzHFUsQJTD1EwNsGpaV9x99u9TUkuppbzybVS8QG5zV+WzXkcE84fOUw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1643291826; a=rsa-sha256; cv=none; b=kBD3GetJXmPh8et+v1TzTWgYohCzJJWXy3kevBTst+28D9vNsvLmFR93542fJHWdAs2k58 L0ZFYcb+cZ6dcZNtzUaxLQMDljfOA6YDdp6ruHpyGWNeEURwi85YjK4wsetcVI0JIDfzm7 Ryuwudwgohhq1JrmFPg8oDGUPumUJMHL377UIc11thkPKz5ikwr+8ktfGGogTepNIk9TDI 6uEdRsHkXgBzXjL5bgOGyC5y5Jj1L0RUmckzJH/ekM0QN39y4vyBPJ24wKjZuEb8CC/hvr CM+PyqKKfp0zMwn8mkDd5/pzieE8BWrGRefVDJ/12ywA9BxWBu15vW6AinG6Yg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N Hey folks, I'm stumped on what I assume is a BIOS bug... Upgraded a system from 2013 and a 60GB SSD with UFS (plus GELI and ZFS) with a shiny new 4TB Samsung SSD, on ZFS and with some parts of the pool encrypted. This was fine for half a year or so, but I noticed a stream of `zio_read error 5` from boot0 (I think?) sometimes during boot on the serial console, but it came up fine anyway. Did another installworld/installkernel dance yesterday and the system no longer boots. First it was showing streams of that zio_read error, then failed to load /tank/ROOT/default:/boot/kernel/kernel. Using the '?' command I could see / just fine, but I could get no combination to work to read inside dirs, the manpage makes me think I should try /boot?, but maybe I should've added a space?. Typed in /boot/kernel.old/kernel (!) and it started the spinner, but died shortly afterwards. Put the SSD into a different system (from ca. 2014) and it boots up just fine. Put the old 60GB SSD back in the old system, and it also boots just fine. Ok, on the newer system, I re-wrote the bootcode with `gpart bootcode -b /boot/pmbr -p /boot/gptzfsboot -i 1 ada0` but that seems to have made things even worse on the old system. Now the tank pool isn't even found anymore (due to the protective MBR maybe?), all I get is some zio_read errors and (from memory, sorry): ZFS: i/o error - all block copies unavailable ZFS: can't read MOS of pool tank Issuing '?' finds nothing anymore. My hypothesis is that this worked initially, as the loader was under some specific LBA threshold, but with more data on the disk, every update moved it back further and this triggers a BIOS bug. There was even a BIOS update from 2018 that I flashed, but it didn't fix any of this, only some Intel ME bugs. Sigh. This is what it looks like: % gpart show => 40 7814037088 ada0 GPT (3.6T) 40 1024 1 freebsd-boot (512K) 1064 984 - free - (492K) 2048 33554432 2 freebsd-swap (16G) 33556480 7780478976 3 freebsd-zfs (3.6T) 7814035456 1672 - free - (836K) So can this be a shortcoming in the BIOS with large drives? I had thought that only applies to boot0, not the loader itself. I thought I can maybe boot from an USB stick and have it find the root of the pool, but the CMOS battery is dead, so I can't switch the boot drive unattended. I can't even turn on UEFI boot as, due to the battery, it won't stick. And this being an "industrial" PC, the CMOS battery is actually rechargeable but soldered onto the board, so I would have to get that fixed as well. Sigh. Should I try to switch to UEFI? Would I have to move all 4T around and re-partition, or could I steal 256M from the swap partition? Should I try with, gasp, GRUB2? I'm kinda stuck on GPT and BIOS here for a while, I think. Thanks for reading all of that, Uli