generic: test fsync new file after removing hard link

Test that if we have a file with two hard links in the same parent
directory, then remove of the links, create a new file in the same
parent directory and with the name of the link removed, fsync the new
file and have a power loss, mounting the filesystem succeeds.

This test is motivated by a bug found in btrfs, which is fixed by
the linux kernel patch titled:

  "Btrfs: fix log replay failure after unlink and link combination"

Signed-off-by: Filipe Manana <fdmanana@suse.com>
Reviewed-by: Eryu Guan <guaneryu@gmail.com>
Signed-off-by: Eryu Guan <guaneryu@gmail.com>
This commit is contained in:
Filipe Manana
2018-02-28 15:58:00 +00:00
committed by Eryu Guan
parent 5db58785e6
commit 204860fa5c
3 changed files with 86 additions and 0 deletions
+1
View File
@@ -482,3 +482,4 @@
477 auto quick exportfs
478 auto quick
479 auto quick metadata
480 auto quick metadata