overlay: test overlay file handles of lower dir with non-indexed ancestor
authorAmir Goldstein <amir73il@gmail.com>
Wed, 31 Jan 2018 11:44:54 +0000 (13:44 +0200)
committerEryu Guan <eguan@redhat.com>
Fri, 2 Feb 2018 16:33:51 +0000 (00:33 +0800)
commitce9707ccd0892df40a2f972b316bdbaf35fa46dd
treeb7438393656699fcef26471c382b0d545b151182
parentdc9f8c9ac02e10fbca80d74cf08b945e7c1c341a
overlay: test overlay file handles of lower dir with non-indexed ancestor

Overlayfs with nfs_export enabled, indexes all directories on copy
up.  Directory index is requires for decoding lower directory file
handles in case ancestors have been renamed.

When enabling nfs_export on an overlay that already has non-indexed
merge dirs, the possibility of non-indexed ancestor rename requires
special handling when encoding lower directory file handles.

- Check encode/decode/read file handles of non-indexed merge dir
- Check encode/decode/read file handles of dir with non-indexed parent
- Check encode/decode/read file handles of dir with non-indexed grandparent
- Check decode/read of file handles after rename of non-indexed merge dir
- Check decode/read of file handles after rename of non-indexed parent
- Check decode/read of file handles after rename of non-indexed grandparent

This test requires and enables overlayfs NFS export support and
merge dir rename support (redirect_dir).
NFS export support depends on and requires overlayfs index feature.

Signed-off-by: Amir Goldstein <amir73il@gmail.com>
Reviewed-by: Eryu Guan <eguan@redhat.com>
Signed-off-by: Eryu Guan <eguan@redhat.com>
tests/overlay/054 [new file with mode: 0755]
tests/overlay/054.out [new file with mode: 0644]
tests/overlay/group