overlay/005: only run for xfs underlying fs
PATCH 1/1 overlay/005: only run for xfs underlying fs
When we runs overlay/005 on a system without xfs module, it always fails as "unknown filesystem type xfs", due to this case require xfs to be the underlying fs explicitly:
$MKFS_XFS_PROG -f -n ftype=1 $upper_loop_dev >>$seqres.full 2>&1
So notrun this case if the underlying fs isn't 'xfs'.
--- tests/overlay/005 | 1 + 1 file changed, 1 insertion(+)
tests/overlay/005 +1 -0
@@ -31,6 +31,7 @@ _cleanup() # them explicity after test. _require_scratch_nocheck _require_loop +[ "$OVL_BASE_FSTYP" = "xfs" ] || _notrun "The underlying fs should be xfs" # Remove all files from previous tests _scratch_mkfs
Signature · 1 line
2.49.0
Quoted 8 lines · Zorro Lang
When we runs overlay/005 on a system without xfs module, it always fails as "unknown filesystem type xfs", due to this case require xfs to be the underlying fs explicitly:
$MKFS_XFS_PROG -f -n ftype=1 $upper_loop_dev >>$seqres.full 2>&1
So notrun this case if the underlying fs isn't 'xfs'.
It would have been better if instead of mkfs.xfs, we would have used a helper to format $upper_loop_dev as $OVL_BASE_FSTYP
But this is easier, so unless anybody wants to take on the better fix
Thanks,
Amir.
Quoted 23 lines
Reported-by Philip Daly <[email protected]>Signed-off-by Zorro Lang <[email protected]>--- tests/overlay/005 | 1 + 1 file changed, 1 insertion(+)tests/overlay/005 +1
-1@@ -31,6 +31,7 @@ _cleanup() # them explicity after test. _require_scratch_nocheck _require_loop +[ "$OVL_BASE_FSTYP" = "xfs" ] || _notrun "The underlying fs should be xfs" # Remove all files from previous tests _scratch_mkfs --2.49.0
Quoted 8 lines · Amir Goldstein
Quoted 7 lines · Zorro Lang
When we runs overlay/005 on a system without xfs module, it always fails as "unknown filesystem type xfs", due to this case require xfs to be the underlying fs explicitly:
$MKFS_XFS_PROG -f -n ftype=1 $upper_loop_dev >>$seqres.full 2>&1
Quoted 8 lines
Quoted 1 line
So notrun this case if the underlying fs isn't 'xfs'.
It would have been better if instead of mkfs.xfs, we would have used a helper to format $upper_loop_dev as $OVL_BASE_FSTYP
But this is easier, so unless anybody wants to take on the better fix
Acked-by Amir Goldstein <[email protected]>
Thanks Amir, No matter what kinds of underlying fs are all good?
I saw this case use:
$MKFS_XFS_PROG -f -n ftype=1 $upper_loop_dev
So I thought it need the xfs ftype feature :-D
Quoted 28 lines
Thanks,
Amir.Quoted 23 lines
Reported-by Philip Daly <[email protected]>Signed-off-by Zorro Lang <[email protected]>--- tests/overlay/005 | 1 + 1 file changed, 1 insertion(+)tests/overlay/005 +1
-1@@ -31,6 +31,7 @@ _cleanup() # them explicity after test. _require_scratch_nocheck _require_loop +[ "$OVL_BASE_FSTYP" = "xfs" ] || _notrun "The underlying fs should be xfs" # Remove all files from previous tests _scratch_mkfs --2.49.0
Quoted 12 lines · Zorro Lang
Quoted 10 lines · Amir Goldstein
Quoted 8 lines · Zorro Lang
When we runs overlay/005 on a system without xfs module, it always fails as "unknown filesystem type xfs", due to this case require xfs to be the underlying fs explicitly:
$MKFS_XFS_PROG -f -n ftype=1 $upper_loop_dev >>$seqres.full 2>&1
So notrun this case if the underlying fs isn't 'xfs'.
Quoted 9 lines
Quoted 6 lines
It would have been better if instead of mkfs.xfs, we would have used a helper to format $upper_loop_dev as $OVL_BASE_FSTYP
But this is easier, so unless anybody wants to take on the better fix
Acked-by Amir Goldstein <[email protected]>Thanks Amir, No matter what kinds of underlying fs are all good?
All I know is what I read in the comments and git history. The documented kernel commit has nothing to do with xfs.
Quoted 6 lines
I saw this case use:
$MKFS_XFS_PROG -f -n ftype=1 $upper_loop_dev
So I thought it need the xfs ftype feature :-D
Ha no. Overlayfs needs underlying support for readdir d_type but ftype is the default for xfs for a long long time.
I think that when Xiong Zhou wrote tests 003,004,0005:
https://lore.kernel.org/fstests/[email protected]/
One of the tests was supposed to test the non-default ftype=0 config and then 005 used explicit ftype=1, but I am pretty sure that ftype=1 was the default long before those tests were written.
IOW, any the loop devices could be formatted with any base fs. The only thing that matters for the test is the small size of the formatted loop devices.
Thanks,
Amir.
Quoted 41 lines · Amir Goldstein
Quoted 12 lines · Zorro Lang
Quoted 10 lines · Amir Goldstein
Quoted 8 lines · Zorro Lang
When we runs overlay/005 on a system without xfs module, it always fails as "unknown filesystem type xfs", due to this case require xfs to be the underlying fs explicitly:
$MKFS_XFS_PROG -f -n ftype=1 $upper_loop_dev >>$seqres.full 2>&1
So notrun this case if the underlying fs isn't 'xfs'.
Quoted 9 lines
Quoted 6 lines
It would have been better if instead of mkfs.xfs, we would have used a helper to format $upper_loop_dev as $OVL_BASE_FSTYP
But this is easier, so unless anybody wants to take on the better fix
Acked-by Amir Goldstein <[email protected]>Thanks Amir, No matter what kinds of underlying fs are all good?
All I know is what I read in the comments and git history. The documented kernel commit has nothing to do with xfs.
Quoted 6 lines
I saw this case use:
$MKFS_XFS_PROG -f -n ftype=1 $upper_loop_dev
So I thought it need the xfs ftype feature :-D
Ha no. Overlayfs needs underlying support for readdir
d_typebut ftype is the default for xfs for a long long time.I think that when Xiong Zhou wrote tests 003,004,0005:
Quoted 7 lines
One of the tests was supposed to test the non-default ftype=0 config and then 005 used explicit ftype=1, but I am pretty sure that ftype=1 was the default long before those tests were written.
IOW, any the loop devices could be formatted with any base fs. The only thing that matters for the test is the small size of the formatted loop devices.
Agree to remove the restrictions.
Quoted 5 lines
Thanks,
Amir.