diff options
| author | Jeff Darcy <jdarcy@fb.com> | 2017-05-13 05:54:26 -0700 |
|---|---|---|
| committer | Jeff Darcy <jeff@pl.atyp.us> | 2017-05-13 15:57:26 +0000 |
| commit | d7b46e8e5e8e5b8fead05ccf0901d5492edb6a51 (patch) | |
| tree | 5cd7373de32d292ce62f05f91ca80f4c2e5e7e02 /tests | |
| parent | db4058ae6245bd9a6bd841541e03c080e81218af (diff) | |
tests: avoid symlink between brick and mountpoint
These were causing hung tests when the bricks were restarted, in some
cases even accompanied by kernel stack traces involving fuse. They're
unnecessary to the purpose of the test.
Change-Id: I3c6c485324e2ee9418eb54929015b5bae436e9ea
Signed-off-by: Jeff Darcy <jdarcy@fb.com>
Reviewed-on: https://review.gluster.org/17284
Tested-by: Jeff Darcy <jeff@pl.atyp.us>
CentOS-regression: Gluster Build System <jenkins@build.gluster.org>
NetBSD-regression: NetBSD Build System <jenkins@build.gluster.org>
Smoke: Gluster Build System <jenkins@build.gluster.org>
Reviewed-by: Kevin Vigor <kvigor@fb.com>
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/basic/afr/self-heal.t | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/tests/basic/afr/self-heal.t b/tests/basic/afr/self-heal.t index e1ac17c2d79..f2af52d9773 100644 --- a/tests/basic/afr/self-heal.t +++ b/tests/basic/afr/self-heal.t @@ -194,13 +194,22 @@ TEST rm -rf $M0/* #7. Link/symlink heal +# Make links (especially symlinks) with relative paths instead of absolute +# paths, because absolute paths pointing from the brick to the mountpoint have +# caused problems. +make_link () { + mountpoint=$1; shift + # Do this in a subshell so we don't change "cd -" for the parent. + (cd $mountpoint; ln $*) +} + #Test TEST touch $M0/file -TEST ln $M0/file $M0/link_to_file +TEST make_link $M0 file link_to_file TEST kill_brick $V0 $H0 $B0/brick0 TEST rm -f $M0/link_to_file -TEST ln -s $M0/file $M0/link_to_file -TEST ln $M0/file $M0/hard_link_to_file +TEST make_link $M0 file -s link_to_file +TEST make_link $M0 file hard_link_to_file TEST $CLI volume start $V0 force EXPECT_WITHIN $CHILD_UP_TIMEOUT "1" afr_child_up_status $V0 0 EXPECT_WITHIN $PROCESS_UP_TIMEOUT "Y" glustershd_up_status |
