Re: FreeBSD 13.2-STABLE can not boot from damaged mirror AND pool stuck in "resilver" state even without new devices.

From: Lev Serebryakov <lev_at_FreeBSD.org>
Date: Sun, 07 Jan 2024 17:56:58 UTC
On 07.01.2024 16:38, Miroslav Lachman wrote:

>>> ZFS: i/o error - all block copies unavailable
>>> ZFS: can't read MOS of pool zroot
>>>
>>>     after that.
>>   I've re-created pool from scratch
>>
>>   zpool create znewroot ada0p3 && zfs send zroot | zfs receive znewroot && zpool destroy zroot && zpool attach znewroot ada0p3 ada1p3
>>
>>   but gptzfsboot still can not boot from it with same diagnostics :-(
> 
> How large are your disks in a question?
   2TB

ada0 at ahcich0 bus 0 scbus0 target 0 lun 0
ada0: <HGST HUS726020ALE610 APGNTD05> ACS-2 ATA SATA 3.x device
ada0: Serial Number K5HPZZLD
ada0: 600.000MB/s transfers (SATA 3.x, UDMA6, PIO 8192bytes)
ada0: Command Queueing enabled
ada0: 1907729MB (3907029168 512 byte sectors)
ada1 at ahcich1 bus 0 scbus1 target 0 lun 0
ada1: <WDC WD2000FYYZ-01UL1B1 01.01K02> ATA8-ACS SATA 3.x device
ada1: Serial Number WD-WMC1P0504169
ada1: 600.000MB/s transfers (SATA 3.x, UDMA6, PIO 8192bytes)
ada1: Command Queueing enabled
ada1: 1907729MB (3907029168 512 byte sectors)

> As far as I search the internet it is caused by the boot code (later stage which is in a file in /boot directory) was moved too far from the beginning of the disk and some old BIOS cannot allow the system to continue booting.
   Oh, it is good hypothesis. It is Haswell-time MSI board (old Hetzner EX40 instance)...

> It can also be avoided if your machine supports EFI boot, but my HP Microserver Gen 8 does not support it.
   I'll try to switch to EFI, but it needs some luck to get to BIOS with provided KVM, it is very unstable :-)

-- 
// Lev Serebryakov