svn commit: r323936 - projects/zfsd/head/tests/sys/cddl/zfs/tests/zfsd

Alan Somers asomers at FreeBSD.org
Fri Sep 22 21:55:43 UTC 2017


Author: asomers
Date: Fri Sep 22 21:55:41 2017
New Revision: 323936
URL: https://svnweb.freebsd.org/changeset/base/323936

Log:
  Fix intermittency in zfsd degrade tests
  
  tests/sys/cddl/zfs/tests/zfsd/zfsd.kshlib
  	Sync the file under test before corrupting the vdev, not after.
  
  tests/sys/cddl/zfs/tests/zfsd/zfsd_test.sh
  	Increase timeouts to 600s.  On systems with a slow rootpool, the
  	extra time is necessary.
  
  Sponsored by:	Spectra Logic Corp

Modified:
  projects/zfsd/head/tests/sys/cddl/zfs/tests/zfsd/zfsd.kshlib
  projects/zfsd/head/tests/sys/cddl/zfs/tests/zfsd/zfsd_test.sh

Modified: projects/zfsd/head/tests/sys/cddl/zfs/tests/zfsd/zfsd.kshlib
==============================================================================
--- projects/zfsd/head/tests/sys/cddl/zfs/tests/zfsd/zfsd.kshlib	Fri Sep 22 20:01:12 2017	(r323935)
+++ projects/zfsd/head/tests/sys/cddl/zfs/tests/zfsd/zfsd.kshlib	Fri Sep 22 21:55:41 2017	(r323936)
@@ -81,11 +81,12 @@ function corrupt_pool_vdev
 
 	# do some IO on the pool
 	log_must $DD if=/dev/zero of=$file bs=1024k count=128
+	$FSYNC $file
+
 	# scribble on the underlying file to corrupt the vdev
 	log_must $DD if=/dev/urandom of=$vdev bs=1024k count=64 conv=notrunc
 
 	# Scrub the pool to detect the corruption
-	$SYNC
 	log_must $ZPOOL scrub $pool
 	wait_until_scrubbed $pool
 

Modified: projects/zfsd/head/tests/sys/cddl/zfs/tests/zfsd/zfsd_test.sh
==============================================================================
--- projects/zfsd/head/tests/sys/cddl/zfs/tests/zfsd/zfsd_test.sh	Fri Sep 22 20:01:12 2017	(r323935)
+++ projects/zfsd/head/tests/sys/cddl/zfs/tests/zfsd/zfsd_test.sh	Fri Sep 22 21:55:41 2017	(r323936)
@@ -58,7 +58,7 @@ zfsd_degrade_001_pos_head()
 {
 	atf_set "descr" "ZFS will degrade a vdev that produces checksum errors"
 	atf_set "require.progs"  zpool zfsd
-	atf_set "timeout" 300
+	atf_set "timeout" 600
 }
 zfsd_degrade_001_pos_body()
 {
@@ -86,7 +86,7 @@ zfsd_degrade_002_pos_head()
 {
 	atf_set "descr" "ZFS will degrade a spare that produces checksum errors"
 	atf_set "require.progs"  zpool zfsd
-	atf_set "timeout" 300
+	atf_set "timeout" 600
 }
 zfsd_degrade_002_pos_body()
 {


More information about the svn-src-projects mailing list