Re: zfs snapshot corruption when using encryption

From: Palle Girgensohn <girgen_at_FreeBSD.org>
Date: Sat, 09 Nov 2024 12:06:21 UTC

> 9 nov. 2024 kl. 02:59 skrev void <void@f-m.fm>:
> 
> On Fri, Nov 08, 2024 at 11:11:23PM +0100, Palle Girgensohn wrote:
> 
>> $ freebsd-version -ku
>> 14.0-RELEASE-p10
>> 14.0-RELEASE-p10
>> 
>> dunno how to present in the above fashion? Binary install, not from source.
> 
> % zfs version
> 
>> The latter, zfs per-filesystem zfs encryption. I haven't heard any horror stories about it, albeit it's quite fresh code.
> 
> I'm wrong about native zfs encryption not being on 14.0. Seems like it is. https://www.freebsd.org/releases/14.0R/relnotes/
> 
> I'm reading this bit:
> 
> ###
> ZFS Changes
> 
> OpenZFS has been upgraded to version 2.2. New features include:
> 
> block cloning, which allows shallow copies of blocks in file copies. This is optional, and disabled by default; it can be enabled with sysctl vfs.zfs.bclone_enabled=1.
> 
> scrub error log (zpool scrub -e)
> BLAKE3 checksums, which are fast, and are now the recommended secure checksums
> corrective zfs receive can heal corrupted data vdev and zpool user properties, similar to dataset user properties.
> ###
> 
> Then again, 14.0 is EoL.
> 
>> Na, it's JBOD alright. I see nothing weird with the disks.
> 
>>> Reallocated_Sector_Ct
>>> Reported_Uncorrect
>>> Current_Pending_Sector
>>> Offline_Uncorrectable
> 
> Were all these values '0' ?

I don't see the props at all.

> 
> Using truss might give a clue about the failure:
> 
> # truss -o /tmp/truss.out zfs-send-commands
> 
> make sure the outfile is made in a place with lots of spare space.

At present I don't have an error, had to remove the snapshot and run zpool scrub -e, to get the zfs send propagation working. We see these error popping up every other day, so I'll get a truss once we get the next problematic snapshot.

Box is updated to 14.1, FWIW.

Palle