All of lore.kernel.org
 help / color / mirror / Atom feed
* more reflink fixes
@ 2016-02-03 16:02 Christoph Hellwig
  2016-02-03 16:02 ` [PATCH 1/4] xfstests: filter whitespaces in 128 and 132 Christoph Hellwig
                   ` (4 more replies)
  0 siblings, 5 replies; 11+ messages in thread
From: Christoph Hellwig @ 2016-02-03 16:02 UTC (permalink / raw)
  To: darrick.wong; +Cc: fstests

See http://www.infradead.org/rpr.html

A couple more fixes for the reflink tests.  With this I'm down to
zero failures an a single notrun on XFS, while some more work remains
to be done for NFS.

^ permalink raw reply	[flat|nested] 11+ messages in thread

* [PATCH 1/4] xfstests: filter whitespaces in 128 and 132
  2016-02-03 16:02 more reflink fixes Christoph Hellwig
@ 2016-02-03 16:02 ` Christoph Hellwig
  2016-02-03 21:10   ` Darrick J. Wong
  2016-02-03 16:02 ` [PATCH 2/4] xfstests: make _scratch_mkfs_blocksized usable Christoph Hellwig
                   ` (3 subsequent siblings)
  4 siblings, 1 reply; 11+ messages in thread
From: Christoph Hellwig @ 2016-02-03 16:02 UTC (permalink / raw)
  To: darrick.wong; +Cc: fstests

See http://www.infradead.org/rpr.html

Seems either I have a different lsattr version, or different mount points
cause differences in the golden output.  Send the lsattr output through
the whitespaces filter so that it works everywhere.

Signed-off-by: Christoph Hellwig <hch@lst.de>
---
 tests/xfs/128     |  2 +-
 tests/xfs/128.out |  8 ++++----
 tests/xfs/132     | 10 +++++-----
 tests/xfs/132.out | 40 ++++++++++++++++++++--------------------
 4 files changed, 30 insertions(+), 30 deletions(-)

diff --git a/tests/xfs/128 b/tests/xfs/128
index e843e6c..2e1da3f 100755
--- a/tests/xfs/128
+++ b/tests/xfs/128
@@ -97,7 +97,7 @@ c13=$(_md5_checksum "$testdir/file3")
 c14=$(_md5_checksum "$testdir/file4")
 
 echo "Defragment"
-lsattr -l "$testdir/" | _filter_scratch
+lsattr -l "$testdir/" | _filter_scratch | _filter_spaces
 xfs_fsr -v -d "$testdir/file1" >> "$seqres.full"
 xfs_fsr -v -d "$testdir/file2" >> "$seqres.full" # fsr probably breaks the link
 xfs_fsr -v -d "$testdir/file3" >> "$seqres.full" # fsr probably breaks the link
diff --git a/tests/xfs/128.out b/tests/xfs/128.out
index 7e72dcd..0ac06db 100644
--- a/tests/xfs/128.out
+++ b/tests/xfs/128.out
@@ -11,10 +11,10 @@ c650f1cf6c9f07b22e3e21ec7d49ded5  SCRATCH_MNT/test-128/file2
 56ed2f712c91e035adeeb26ed105a982  SCRATCH_MNT/test-128/file3
 b81534f439aac5c34ce3ed60a03eba70  SCRATCH_MNT/test-128/file4
 Defragment
-SCRATCH_MNT/test-128/file1          ---
-SCRATCH_MNT/test-128/file2          ---
-SCRATCH_MNT/test-128/file3          ---
-SCRATCH_MNT/test-128/file4          ---
+SCRATCH_MNT/test-128/file1 ---
+SCRATCH_MNT/test-128/file2 ---
+SCRATCH_MNT/test-128/file3 ---
+SCRATCH_MNT/test-128/file4 ---
 b81534f439aac5c34ce3ed60a03eba70  SCRATCH_MNT/test-128/file1
 c650f1cf6c9f07b22e3e21ec7d49ded5  SCRATCH_MNT/test-128/file2
 56ed2f712c91e035adeeb26ed105a982  SCRATCH_MNT/test-128/file3
diff --git a/tests/xfs/132 b/tests/xfs/132
index 79a6d57..9c57c3b 100755
--- a/tests/xfs/132
+++ b/tests/xfs/132
@@ -87,32 +87,32 @@ for i in `seq 2 $nr`; do
 done
 _test_remount
 free_blocks1=$(stat -f "$testdir" -c '%f')
-lsattr -l $testdir/ | _filter_test_dir
+lsattr -l $testdir/ | _filter_test_dir | _filter_spaces
 
 echo "funshare part of a file"
 "$XFS_IO_PROG" -f -c "falloc 0 $((sz / 2))" "$testdir/file2"
 _test_remount
-lsattr -l $testdir/ | _filter_test_dir
+lsattr -l $testdir/ | _filter_test_dir | _filter_spaces
 
 echo "funshare some of the copies"
 "$XFS_IO_PROG" -f -c "falloc 0 $sz" "$testdir/file2"
 "$XFS_IO_PROG" -f -c "falloc 0 $sz" "$testdir/file3"
 _test_remount
 free_blocks2=$(stat -f "$testdir" -c '%f')
-lsattr -l $testdir/ | _filter_test_dir
+lsattr -l $testdir/ | _filter_test_dir | _filter_spaces
 
 echo "funshare the rest of the files"
 "$XFS_IO_PROG" -f -c "falloc 0 $sz" "$testdir/file4"
 "$XFS_IO_PROG" -f -c "falloc 0 $sz" "$testdir/file1"
 _test_remount
 free_blocks3=$(stat -f "$testdir" -c '%f')
-lsattr -l $testdir/ | _filter_test_dir
+lsattr -l $testdir/ | _filter_test_dir | _filter_spaces
 
 echo "Rewrite the original file"
 _pwrite_byte 0x65 0 $sz "$testdir/file1" >> "$seqres.full"
 _test_remount
 free_blocks4=$(stat -f "$testdir" -c '%f')
-lsattr -l $testdir/ | _filter_test_dir
+lsattr -l $testdir/ | _filter_test_dir | _filter_spaces
 #echo $free_blocks0 $free_blocks1 $free_blocks2 $free_blocks3 $free_blocks4
 
 _within_tolerance "free blocks after reflinking" $free_blocks1 $((free_blocks0 - blks)) $margin -v
diff --git a/tests/xfs/132.out b/tests/xfs/132.out
index fd2b7bd..f32db7d 100644
--- a/tests/xfs/132.out
+++ b/tests/xfs/132.out
@@ -1,30 +1,30 @@
 QA output created by 132
 Create the original file blocks
 Create the reflink copies
-TEST_DIR/test-132/file1          ---
-TEST_DIR/test-132/file2          ---
-TEST_DIR/test-132/file3          ---
-TEST_DIR/test-132/file4          ---
+TEST_DIR/test-132/file1 ---
+TEST_DIR/test-132/file2 ---
+TEST_DIR/test-132/file3 ---
+TEST_DIR/test-132/file4 ---
 funshare part of a file
-TEST_DIR/test-132/file1          ---
-TEST_DIR/test-132/file2          ---
-TEST_DIR/test-132/file3          ---
-TEST_DIR/test-132/file4          ---
+TEST_DIR/test-132/file1 ---
+TEST_DIR/test-132/file2 ---
+TEST_DIR/test-132/file3 ---
+TEST_DIR/test-132/file4 ---
 funshare some of the copies
-TEST_DIR/test-132/file1          ---
-TEST_DIR/test-132/file2          No_COW
-TEST_DIR/test-132/file3          No_COW
-TEST_DIR/test-132/file4          ---
+TEST_DIR/test-132/file1 ---
+TEST_DIR/test-132/file2 No_COW
+TEST_DIR/test-132/file3 No_COW
+TEST_DIR/test-132/file4 ---
 funshare the rest of the files
-TEST_DIR/test-132/file1          No_COW
-TEST_DIR/test-132/file2          No_COW
-TEST_DIR/test-132/file3          No_COW
-TEST_DIR/test-132/file4          No_COW
+TEST_DIR/test-132/file1 No_COW
+TEST_DIR/test-132/file2 No_COW
+TEST_DIR/test-132/file3 No_COW
+TEST_DIR/test-132/file4 No_COW
 Rewrite the original file
-TEST_DIR/test-132/file1          No_COW
-TEST_DIR/test-132/file2          No_COW
-TEST_DIR/test-132/file3          No_COW
-TEST_DIR/test-132/file4          No_COW
+TEST_DIR/test-132/file1 No_COW
+TEST_DIR/test-132/file2 No_COW
+TEST_DIR/test-132/file3 No_COW
+TEST_DIR/test-132/file4 No_COW
 free blocks after reflinking is in range
 free blocks after nocow'ing some copies is in range
 free blocks after nocow'ing all copies is in range
-- 
2.1.4

^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [PATCH 2/4] xfstests: make _scratch_mkfs_blocksized usable
  2016-02-03 16:02 more reflink fixes Christoph Hellwig
  2016-02-03 16:02 ` [PATCH 1/4] xfstests: filter whitespaces in 128 and 132 Christoph Hellwig
@ 2016-02-03 16:02 ` Christoph Hellwig
  2016-02-03 21:13   ` Darrick J. Wong
  2016-02-03 16:02 ` [PATCH 3/4] xfstests: 912 requires dedup support Christoph Hellwig
                   ` (2 subsequent siblings)
  4 siblings, 1 reply; 11+ messages in thread
From: Christoph Hellwig @ 2016-02-03 16:02 UTC (permalink / raw)
  To: darrick.wong; +Cc: fstests

See http://www.infradead.org/rpr.html

The default mkfs.xfs options contain -b size=4096, so all tests
using _scratch_mkfs_blocksized won't actually run unless those
options are changed.  As we're trying to specificly test 1k
blocks we should always override the default option.

BTW, why is _scratch_mkfs_blocksized in the reflink file and not
with more generic helpers?

Signed-off-by: Christoph Hellwig <hch@lst.de>
---
 common/reflink | 8 +-------
 1 file changed, 1 insertion(+), 7 deletions(-)

diff --git a/common/reflink b/common/reflink
index 398e505..bb1068a 100644
--- a/common/reflink
+++ b/common/reflink
@@ -201,13 +201,7 @@ _scratch_mkfs_blocksized()
 
     case $FSTYP in
     xfs)
-	# don't override MKFS_OPTIONS that set a block size.
-	echo $MKFS_OPTIONS |egrep -q "b?size="
-	if [ $? -eq 0 ]; then
-		_scratch_mkfs_xfs
-	else
-		_scratch_mkfs_xfs -b size=$blocksize
-	fi
+	_scratch_mkfs_xfs -b size=$blocksize
 	;;
     ext2|ext3|ext4|ocfs2)
 	${MKFS_PROG}.$FSTYP -F $MKFS_OPTIONS -b $blocksize $SCRATCH_DEV
-- 
2.1.4

^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [PATCH 3/4] xfstests: 912 requires dedup support
  2016-02-03 16:02 more reflink fixes Christoph Hellwig
  2016-02-03 16:02 ` [PATCH 1/4] xfstests: filter whitespaces in 128 and 132 Christoph Hellwig
  2016-02-03 16:02 ` [PATCH 2/4] xfstests: make _scratch_mkfs_blocksized usable Christoph Hellwig
@ 2016-02-03 16:02 ` Christoph Hellwig
  2016-02-03 20:56   ` Darrick J. Wong
  2016-02-03 16:02 ` [PATCH 4/4] xfstests: 899 requires a working filefrag Christoph Hellwig
  2016-02-04 15:45 ` more reflink fixes Christoph Hellwig
  4 siblings, 1 reply; 11+ messages in thread
From: Christoph Hellwig @ 2016-02-03 16:02 UTC (permalink / raw)
  To: darrick.wong; +Cc: fstests

See http://www.infradead.org/rpr.html

Signed-off-by: Christoph Hellwig <hch@lst.de>
---
 tests/generic/912 | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/tests/generic/912 b/tests/generic/912
index 910f1ea..7a629bc 100755
--- a/tests/generic/912
+++ b/tests/generic/912
@@ -43,7 +43,7 @@ _cleanup()
 
 # real QA test starts here
 _supported_os Linux
-_require_test_reflink
+_require_test_dedupe
 _require_cp_reflink
 
 rm -f "$seqres.full"
-- 
2.1.4

^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [PATCH 4/4] xfstests: 899 requires a working filefrag
  2016-02-03 16:02 more reflink fixes Christoph Hellwig
                   ` (2 preceding siblings ...)
  2016-02-03 16:02 ` [PATCH 3/4] xfstests: 912 requires dedup support Christoph Hellwig
@ 2016-02-03 16:02 ` Christoph Hellwig
  2016-02-03 20:58   ` Darrick J. Wong
  2016-02-04 15:45 ` more reflink fixes Christoph Hellwig
  4 siblings, 1 reply; 11+ messages in thread
From: Christoph Hellwig @ 2016-02-03 16:02 UTC (permalink / raw)
  To: darrick.wong; +Cc: fstests

See http://www.infradead.org/rpr.html

NFS has neither FIBMAP nor FIEMAP so filefrag will fail.  Handle this
case gracefully.

Signed-off-by: Christoph Hellwig <hch@lst.de>
---
 tests/generic/899 | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/tests/generic/899 b/tests/generic/899
index 9b3f973..ce3db38 100755
--- a/tests/generic/899
+++ b/tests/generic/899
@@ -67,6 +67,10 @@ nr=64
 _pwrite_byte 0x61 0 $((blksz * nr)) "$testdir/file1" >> "$seqres.full"
 _pwrite_byte 0x62 0 $((blksz * nr)) "$testdir/file3" >> "$seqres.full"
 _pwrite_byte 0x61 0 $((blksz * nr)) "$testdir/file1.chk" >> "$seqres.full"
+
+filefrag -v "$testdir/file1" 2>&1 | grep -q "FIBMAP: Invalid argument" && \
+	_notrun "filefrag not support on file system type \"$FSTYP\""
+
 seq 1 2 $((nr-1)) | while read f; do
 	_reflink_range "$testdir/file1" $((blksz * f)) "$testdir/file3" $((blksz * f)) $blksz >> "$seqres.full"
 done
-- 
2.1.4

^ permalink raw reply related	[flat|nested] 11+ messages in thread

* Re: [PATCH 3/4] xfstests: 912 requires dedup support
  2016-02-03 16:02 ` [PATCH 3/4] xfstests: 912 requires dedup support Christoph Hellwig
@ 2016-02-03 20:56   ` Darrick J. Wong
  0 siblings, 0 replies; 11+ messages in thread
From: Darrick J. Wong @ 2016-02-03 20:56 UTC (permalink / raw)
  To: Christoph Hellwig; +Cc: fstests

On Wed, Feb 03, 2016 at 05:02:07PM +0100, Christoph Hellwig wrote:
> See http://www.infradead.org/rpr.html

Applied, thanks.

--D

> 
> Signed-off-by: Christoph Hellwig <hch@lst.de>
> ---
>  tests/generic/912 | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/tests/generic/912 b/tests/generic/912
> index 910f1ea..7a629bc 100755
> --- a/tests/generic/912
> +++ b/tests/generic/912
> @@ -43,7 +43,7 @@ _cleanup()
>  
>  # real QA test starts here
>  _supported_os Linux
> -_require_test_reflink
> +_require_test_dedupe
>  _require_cp_reflink
>  
>  rm -f "$seqres.full"
> -- 
> 2.1.4
> 

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH 4/4] xfstests: 899 requires a working filefrag
  2016-02-03 16:02 ` [PATCH 4/4] xfstests: 899 requires a working filefrag Christoph Hellwig
@ 2016-02-03 20:58   ` Darrick J. Wong
  0 siblings, 0 replies; 11+ messages in thread
From: Darrick J. Wong @ 2016-02-03 20:58 UTC (permalink / raw)
  To: Christoph Hellwig; +Cc: fstests

On Wed, Feb 03, 2016 at 05:02:08PM +0100, Christoph Hellwig wrote:
> See http://www.infradead.org/rpr.html
> 
> NFS has neither FIBMAP nor FIEMAP so filefrag will fail.  Handle this
> case gracefully.
> 
> Signed-off-by: Christoph Hellwig <hch@lst.de>
> ---
>  tests/generic/899 | 4 ++++
>  1 file changed, 4 insertions(+)
> 
> diff --git a/tests/generic/899 b/tests/generic/899
> index 9b3f973..ce3db38 100755
> --- a/tests/generic/899
> +++ b/tests/generic/899
> @@ -67,6 +67,10 @@ nr=64
>  _pwrite_byte 0x61 0 $((blksz * nr)) "$testdir/file1" >> "$seqres.full"
>  _pwrite_byte 0x62 0 $((blksz * nr)) "$testdir/file3" >> "$seqres.full"
>  _pwrite_byte 0x61 0 $((blksz * nr)) "$testdir/file1.chk" >> "$seqres.full"
> +
> +filefrag -v "$testdir/file1" 2>&1 | grep -q "FIBMAP: Invalid argument" && \
> +	_notrun "filefrag not support on file system type \"$FSTYP\""

I rewrote the test to avoid filefrag.

--D

> +
>  seq 1 2 $((nr-1)) | while read f; do
>  	_reflink_range "$testdir/file1" $((blksz * f)) "$testdir/file3" $((blksz * f)) $blksz >> "$seqres.full"
>  done
> -- 
> 2.1.4
> 

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH 1/4] xfstests: filter whitespaces in 128 and 132
  2016-02-03 16:02 ` [PATCH 1/4] xfstests: filter whitespaces in 128 and 132 Christoph Hellwig
@ 2016-02-03 21:10   ` Darrick J. Wong
  0 siblings, 0 replies; 11+ messages in thread
From: Darrick J. Wong @ 2016-02-03 21:10 UTC (permalink / raw)
  To: Christoph Hellwig; +Cc: fstests

On Wed, Feb 03, 2016 at 05:02:05PM +0100, Christoph Hellwig wrote:
> See http://www.infradead.org/rpr.html
> 
> Seems either I have a different lsattr version, or different mount points
> cause differences in the golden output.  Send the lsattr output through
> the whitespaces filter so that it works everywhere.

Yes, it does change, sigh....

Applied, thanks.  I added to the changelog documentation of the
messy history of using lsattr for testing. :(

--D

> 
> Signed-off-by: Christoph Hellwig <hch@lst.de>
> ---
>  tests/xfs/128     |  2 +-
>  tests/xfs/128.out |  8 ++++----
>  tests/xfs/132     | 10 +++++-----
>  tests/xfs/132.out | 40 ++++++++++++++++++++--------------------
>  4 files changed, 30 insertions(+), 30 deletions(-)
> 
> diff --git a/tests/xfs/128 b/tests/xfs/128
> index e843e6c..2e1da3f 100755
> --- a/tests/xfs/128
> +++ b/tests/xfs/128
> @@ -97,7 +97,7 @@ c13=$(_md5_checksum "$testdir/file3")
>  c14=$(_md5_checksum "$testdir/file4")
>  
>  echo "Defragment"
> -lsattr -l "$testdir/" | _filter_scratch
> +lsattr -l "$testdir/" | _filter_scratch | _filter_spaces
>  xfs_fsr -v -d "$testdir/file1" >> "$seqres.full"
>  xfs_fsr -v -d "$testdir/file2" >> "$seqres.full" # fsr probably breaks the link
>  xfs_fsr -v -d "$testdir/file3" >> "$seqres.full" # fsr probably breaks the link
> diff --git a/tests/xfs/128.out b/tests/xfs/128.out
> index 7e72dcd..0ac06db 100644
> --- a/tests/xfs/128.out
> +++ b/tests/xfs/128.out
> @@ -11,10 +11,10 @@ c650f1cf6c9f07b22e3e21ec7d49ded5  SCRATCH_MNT/test-128/file2
>  56ed2f712c91e035adeeb26ed105a982  SCRATCH_MNT/test-128/file3
>  b81534f439aac5c34ce3ed60a03eba70  SCRATCH_MNT/test-128/file4
>  Defragment
> -SCRATCH_MNT/test-128/file1          ---
> -SCRATCH_MNT/test-128/file2          ---
> -SCRATCH_MNT/test-128/file3          ---
> -SCRATCH_MNT/test-128/file4          ---
> +SCRATCH_MNT/test-128/file1 ---
> +SCRATCH_MNT/test-128/file2 ---
> +SCRATCH_MNT/test-128/file3 ---
> +SCRATCH_MNT/test-128/file4 ---
>  b81534f439aac5c34ce3ed60a03eba70  SCRATCH_MNT/test-128/file1
>  c650f1cf6c9f07b22e3e21ec7d49ded5  SCRATCH_MNT/test-128/file2
>  56ed2f712c91e035adeeb26ed105a982  SCRATCH_MNT/test-128/file3
> diff --git a/tests/xfs/132 b/tests/xfs/132
> index 79a6d57..9c57c3b 100755
> --- a/tests/xfs/132
> +++ b/tests/xfs/132
> @@ -87,32 +87,32 @@ for i in `seq 2 $nr`; do
>  done
>  _test_remount
>  free_blocks1=$(stat -f "$testdir" -c '%f')
> -lsattr -l $testdir/ | _filter_test_dir
> +lsattr -l $testdir/ | _filter_test_dir | _filter_spaces
>  
>  echo "funshare part of a file"
>  "$XFS_IO_PROG" -f -c "falloc 0 $((sz / 2))" "$testdir/file2"
>  _test_remount
> -lsattr -l $testdir/ | _filter_test_dir
> +lsattr -l $testdir/ | _filter_test_dir | _filter_spaces
>  
>  echo "funshare some of the copies"
>  "$XFS_IO_PROG" -f -c "falloc 0 $sz" "$testdir/file2"
>  "$XFS_IO_PROG" -f -c "falloc 0 $sz" "$testdir/file3"
>  _test_remount
>  free_blocks2=$(stat -f "$testdir" -c '%f')
> -lsattr -l $testdir/ | _filter_test_dir
> +lsattr -l $testdir/ | _filter_test_dir | _filter_spaces
>  
>  echo "funshare the rest of the files"
>  "$XFS_IO_PROG" -f -c "falloc 0 $sz" "$testdir/file4"
>  "$XFS_IO_PROG" -f -c "falloc 0 $sz" "$testdir/file1"
>  _test_remount
>  free_blocks3=$(stat -f "$testdir" -c '%f')
> -lsattr -l $testdir/ | _filter_test_dir
> +lsattr -l $testdir/ | _filter_test_dir | _filter_spaces
>  
>  echo "Rewrite the original file"
>  _pwrite_byte 0x65 0 $sz "$testdir/file1" >> "$seqres.full"
>  _test_remount
>  free_blocks4=$(stat -f "$testdir" -c '%f')
> -lsattr -l $testdir/ | _filter_test_dir
> +lsattr -l $testdir/ | _filter_test_dir | _filter_spaces
>  #echo $free_blocks0 $free_blocks1 $free_blocks2 $free_blocks3 $free_blocks4
>  
>  _within_tolerance "free blocks after reflinking" $free_blocks1 $((free_blocks0 - blks)) $margin -v
> diff --git a/tests/xfs/132.out b/tests/xfs/132.out
> index fd2b7bd..f32db7d 100644
> --- a/tests/xfs/132.out
> +++ b/tests/xfs/132.out
> @@ -1,30 +1,30 @@
>  QA output created by 132
>  Create the original file blocks
>  Create the reflink copies
> -TEST_DIR/test-132/file1          ---
> -TEST_DIR/test-132/file2          ---
> -TEST_DIR/test-132/file3          ---
> -TEST_DIR/test-132/file4          ---
> +TEST_DIR/test-132/file1 ---
> +TEST_DIR/test-132/file2 ---
> +TEST_DIR/test-132/file3 ---
> +TEST_DIR/test-132/file4 ---
>  funshare part of a file
> -TEST_DIR/test-132/file1          ---
> -TEST_DIR/test-132/file2          ---
> -TEST_DIR/test-132/file3          ---
> -TEST_DIR/test-132/file4          ---
> +TEST_DIR/test-132/file1 ---
> +TEST_DIR/test-132/file2 ---
> +TEST_DIR/test-132/file3 ---
> +TEST_DIR/test-132/file4 ---
>  funshare some of the copies
> -TEST_DIR/test-132/file1          ---
> -TEST_DIR/test-132/file2          No_COW
> -TEST_DIR/test-132/file3          No_COW
> -TEST_DIR/test-132/file4          ---
> +TEST_DIR/test-132/file1 ---
> +TEST_DIR/test-132/file2 No_COW
> +TEST_DIR/test-132/file3 No_COW
> +TEST_DIR/test-132/file4 ---
>  funshare the rest of the files
> -TEST_DIR/test-132/file1          No_COW
> -TEST_DIR/test-132/file2          No_COW
> -TEST_DIR/test-132/file3          No_COW
> -TEST_DIR/test-132/file4          No_COW
> +TEST_DIR/test-132/file1 No_COW
> +TEST_DIR/test-132/file2 No_COW
> +TEST_DIR/test-132/file3 No_COW
> +TEST_DIR/test-132/file4 No_COW
>  Rewrite the original file
> -TEST_DIR/test-132/file1          No_COW
> -TEST_DIR/test-132/file2          No_COW
> -TEST_DIR/test-132/file3          No_COW
> -TEST_DIR/test-132/file4          No_COW
> +TEST_DIR/test-132/file1 No_COW
> +TEST_DIR/test-132/file2 No_COW
> +TEST_DIR/test-132/file3 No_COW
> +TEST_DIR/test-132/file4 No_COW
>  free blocks after reflinking is in range
>  free blocks after nocow'ing some copies is in range
>  free blocks after nocow'ing all copies is in range
> -- 
> 2.1.4
> 

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH 2/4] xfstests: make _scratch_mkfs_blocksized usable
  2016-02-03 16:02 ` [PATCH 2/4] xfstests: make _scratch_mkfs_blocksized usable Christoph Hellwig
@ 2016-02-03 21:13   ` Darrick J. Wong
  0 siblings, 0 replies; 11+ messages in thread
From: Darrick J. Wong @ 2016-02-03 21:13 UTC (permalink / raw)
  To: Christoph Hellwig; +Cc: fstests

On Wed, Feb 03, 2016 at 05:02:06PM +0100, Christoph Hellwig wrote:
> See http://www.infradead.org/rpr.html
> 
> The default mkfs.xfs options contain -b size=4096, so all tests
> using _scratch_mkfs_blocksized won't actually run unless those
> options are changed.  As we're trying to specificly test 1k
> blocks we should always override the default option.
> 
> BTW, why is _scratch_mkfs_blocksized in the reflink file and not
> with more generic helpers?

Uh... I don't know.  I'll move it.  I have a feeling this might have
slipped through the cracks. :/

Applied, thanks.

--D

> 
> Signed-off-by: Christoph Hellwig <hch@lst.de>
> ---
>  common/reflink | 8 +-------
>  1 file changed, 1 insertion(+), 7 deletions(-)
> 
> diff --git a/common/reflink b/common/reflink
> index 398e505..bb1068a 100644
> --- a/common/reflink
> +++ b/common/reflink
> @@ -201,13 +201,7 @@ _scratch_mkfs_blocksized()
>  
>      case $FSTYP in
>      xfs)
> -	# don't override MKFS_OPTIONS that set a block size.
> -	echo $MKFS_OPTIONS |egrep -q "b?size="
> -	if [ $? -eq 0 ]; then
> -		_scratch_mkfs_xfs
> -	else
> -		_scratch_mkfs_xfs -b size=$blocksize
> -	fi
> +	_scratch_mkfs_xfs -b size=$blocksize
>  	;;
>      ext2|ext3|ext4|ocfs2)
>  	${MKFS_PROG}.$FSTYP -F $MKFS_OPTIONS -b $blocksize $SCRATCH_DEV
> -- 
> 2.1.4
> 

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: more reflink fixes
  2016-02-03 16:02 more reflink fixes Christoph Hellwig
                   ` (3 preceding siblings ...)
  2016-02-03 16:02 ` [PATCH 4/4] xfstests: 899 requires a working filefrag Christoph Hellwig
@ 2016-02-04 15:45 ` Christoph Hellwig
  2016-02-04 17:27   ` Darrick J. Wong
  4 siblings, 1 reply; 11+ messages in thread
From: Christoph Hellwig @ 2016-02-04 15:45 UTC (permalink / raw)
  To: darrick.wong; +Cc: fstests

And another one:

---
>From 36919b5d1c84b0ceb8b9fc5c33ec1730d10e5d1c Mon Sep 17 00:00:00 2001
From: Christoph Hellwig <hch@lst.de>
Date: Thu, 4 Feb 2016 16:42:12 +0100
Subject: xfstests: don't run 907 and 908 on NFS

NFS can't interrupt pending clone operations as they are a remote
operation.  Skip the two tests that rely on this as they'll mess up
all following tests otherwise.

Signed-off-by: Christoph Hellwig <hch@lst.de>
---
 tests/generic/907 | 2 ++
 tests/generic/908 | 2 ++
 2 files changed, 4 insertions(+)

diff --git a/tests/generic/907 b/tests/generic/907
index fec22c8..e35e067 100755
--- a/tests/generic/907
+++ b/tests/generic/907
@@ -47,6 +47,8 @@ _require_scratch_reflink
 _require_cp_reflink
 _require_command "$(which timeout)" "timeout"
 
+test "$FSTYP" == "nfs"  && _notrun "NFS can't interrupt clone operations"
+
 rm -f "$seqres.full"
 
 echo "Format and mount"
diff --git a/tests/generic/908 b/tests/generic/908
index 09a3101..c977ed6 100755
--- a/tests/generic/908
+++ b/tests/generic/908
@@ -47,6 +47,8 @@ _require_scratch_reflink
 _require_cp_reflink
 _require_command "$(which timeout)" "timeout"
 
+test "$FSTYP" == "nfs"  && _notrun "NFS can't interrupt clone operations"
+
 rm -f "$seqres.full"
 
 echo "Format and mount"
-- 
2.1.4


^ permalink raw reply related	[flat|nested] 11+ messages in thread

* Re: more reflink fixes
  2016-02-04 15:45 ` more reflink fixes Christoph Hellwig
@ 2016-02-04 17:27   ` Darrick J. Wong
  0 siblings, 0 replies; 11+ messages in thread
From: Darrick J. Wong @ 2016-02-04 17:27 UTC (permalink / raw)
  To: Christoph Hellwig; +Cc: fstests

On Thu, Feb 04, 2016 at 04:45:52PM +0100, Christoph Hellwig wrote:
> And another one:
> 
> ---
> From 36919b5d1c84b0ceb8b9fc5c33ec1730d10e5d1c Mon Sep 17 00:00:00 2001
> From: Christoph Hellwig <hch@lst.de>
> Date: Thu, 4 Feb 2016 16:42:12 +0100
> Subject: xfstests: don't run 907 and 908 on NFS
> 
> NFS can't interrupt pending clone operations as they are a remote
> operation.  Skip the two tests that rely on this as they'll mess up
> all following tests otherwise.

Applied, thanks.

--D

> 
> Signed-off-by: Christoph Hellwig <hch@lst.de>
> ---
>  tests/generic/907 | 2 ++
>  tests/generic/908 | 2 ++
>  2 files changed, 4 insertions(+)
> 
> diff --git a/tests/generic/907 b/tests/generic/907
> index fec22c8..e35e067 100755
> --- a/tests/generic/907
> +++ b/tests/generic/907
> @@ -47,6 +47,8 @@ _require_scratch_reflink
>  _require_cp_reflink
>  _require_command "$(which timeout)" "timeout"
>  
> +test "$FSTYP" == "nfs"  && _notrun "NFS can't interrupt clone operations"
> +
>  rm -f "$seqres.full"
>  
>  echo "Format and mount"
> diff --git a/tests/generic/908 b/tests/generic/908
> index 09a3101..c977ed6 100755
> --- a/tests/generic/908
> +++ b/tests/generic/908
> @@ -47,6 +47,8 @@ _require_scratch_reflink
>  _require_cp_reflink
>  _require_command "$(which timeout)" "timeout"
>  
> +test "$FSTYP" == "nfs"  && _notrun "NFS can't interrupt clone operations"
> +
>  rm -f "$seqres.full"
>  
>  echo "Format and mount"
> -- 
> 2.1.4
> 

^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2016-02-04 17:27 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-02-03 16:02 more reflink fixes Christoph Hellwig
2016-02-03 16:02 ` [PATCH 1/4] xfstests: filter whitespaces in 128 and 132 Christoph Hellwig
2016-02-03 21:10   ` Darrick J. Wong
2016-02-03 16:02 ` [PATCH 2/4] xfstests: make _scratch_mkfs_blocksized usable Christoph Hellwig
2016-02-03 21:13   ` Darrick J. Wong
2016-02-03 16:02 ` [PATCH 3/4] xfstests: 912 requires dedup support Christoph Hellwig
2016-02-03 20:56   ` Darrick J. Wong
2016-02-03 16:02 ` [PATCH 4/4] xfstests: 899 requires a working filefrag Christoph Hellwig
2016-02-03 20:58   ` Darrick J. Wong
2016-02-04 15:45 ` more reflink fixes Christoph Hellwig
2016-02-04 17:27   ` Darrick J. Wong

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.