Re: [PATCH V3] xfstest: overlay: Add tests for overlay metadata only copy up feature

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Jun 01, 2018 at 11:34:38AM +0300, Amir Goldstein wrote:

[..]
> > +# File size on lower
> > +lowername="lowerfile"
> > +lowerlink="lowerfile-link"
> > +lowerdata="lower"
> > +lowerblocks="32"
> > +lowersize=$(( $lowerblocks * 512 ))
> > +
> 
> Although the test passes now on ext4/xfs, my comment remains -
> it makes no sense for this test to calculate expected nr of blocks
> instead of using actual lower file blocks.
> 
> While fallocate $size guaranties that resulting file size is $size
> you cannot say the same about $blocks. There is no guarantie
> that file systems will use $size / 512 blocks to store size$.
> file systems can and do allocate more blocks for e.g. xattr and
> other file metadata. There is really no reason for this test to
> make the assumption about $blocks however probable it may be.

Ok. So instead of making assumptions about number of blocks, instead,
create a file of pre-determined size, and then query the number of
blocks from lower and use that as expected blocks from overlay mount?

Will make that change. Thanks.

Vivek
--
To unsubscribe from this list: send the line "unsubscribe linux-unionfs" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux Filesystems Devel]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux