mirror of
https://git.proxmox.com/git/mirror_zfs.git
synced 2024-12-26 03:09:34 +03:00
tests/block_cloning: try harder to stay on same txg in fallback test
We've observed this test failing intermittently. When it does, the "same block" check shows that both files have the same content, that is, the file was cloned. The only way this could have happened is if the open txg moved between the dd and clonefile calls. That's possible because although we set zfs_txg_timeout to be large, that only affects the wait time in the sync thread at the start of a new txg; it doesn't change anything if its currently waiting or working. So here we just force the txgs to move immediately before, which should get both operations onto the same txg as intented. Sponsored-By: OpenDrives Inc. Sponsored-By: Klara Inc. Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Signed-off-by: Rob Norris Rob Norris <rob.norris@klarasystems.com> Closes #15303
This commit is contained in:
parent
b53077a9e7
commit
2dc89b922b
@ -51,6 +51,7 @@ log_onexit cleanup
|
||||
log_must zpool create -o feature@block_cloning=enabled $TESTPOOL $DISKS
|
||||
|
||||
log_must set_tunable64 TXG_TIMEOUT 5000
|
||||
log_must sync_pool $TESTPOOL true
|
||||
|
||||
log_must dd if=/dev/urandom of=/$TESTPOOL/file bs=128K count=4
|
||||
log_must clonefile -f /$TESTPOOL/file /$TESTPOOL/clone 0 0 524288
|
||||
|
Loading…
Reference in New Issue
Block a user