Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 9 Oct 2019 20:16:41 +0000 (UTC)
From:      Alan Somers <asomers@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r353366 - head/tests/sys/cddl/zfs/tests/cli_root/zpool_add
Message-ID:  <201910092016.x99KGfJS013069@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: asomers
Date: Wed Oct  9 20:16:40 2019
New Revision: 353366
URL: https://svnweb.freebsd.org/changeset/base/353366

Log:
  ZFS: fix the zpool_add_010_pos test
  
  The test is necessarily racy, because it depends on being able to complete a
  "zpool add" before a previous resilver finishes.  But it was racier than it
  needed to be.  Move the first "zpool add" to before the resilver starts.
  
  MFC after:	2 weeks
  Sponsored by:	Axcient

Modified:
  head/tests/sys/cddl/zfs/tests/cli_root/zpool_add/zpool_add_010_pos.ksh

Modified: head/tests/sys/cddl/zfs/tests/cli_root/zpool_add/zpool_add_010_pos.ksh
==============================================================================
--- head/tests/sys/cddl/zfs/tests/cli_root/zpool_add/zpool_add_010_pos.ksh	Wed Oct  9 20:05:14 2019	(r353365)
+++ head/tests/sys/cddl/zfs/tests/cli_root/zpool_add/zpool_add_010_pos.ksh	Wed Oct  9 20:16:40 2019	(r353366)
@@ -48,8 +48,8 @@ create_pool $TESTPOOL mirror ${DISK0} ${DISK1}
 # is complete.  We don't want that to happen during this test, so write some
 # data just to slow down resilvering.
 $TIMEOUT 60s $DD if=/dev/zero of=/$TESTPOOL/zerofile bs=128k
-log_must $ZPOOL replace $TESTPOOL ${DISK0} ${DISK2}
 log_must $ZPOOL add $TESTPOOL spare ${DISK3}
+log_must $ZPOOL replace $TESTPOOL ${DISK0} ${DISK2}
 log_must $ZPOOL replace $TESTPOOL ${DISK0} ${DISK3}
 log_must $ZPOOL add $TESTPOOL spare ${DISK4}
 



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201910092016.x99KGfJS013069>