Whamcloud - gitweb
LU-2877 Add a roundtrip delay in sanity test 34h
authorOleg Drokin <green@whamcloud.com>
Fri, 29 Mar 2013 03:48:36 +0000 (23:48 -0400)
committerOleg Drokin <oleg.drokin@intel.com>
Wed, 1 May 2013 06:09:47 +0000 (02:09 -0400)
It seems we are still getting false failures in test 34h due to
overloaded server that takes longer than 2 seconds to process
a request.
To even things out - do another sync RPC to OST first before
starting the timeout.

Change-Id: I070345233398d7a15a105162523ef6dc81c1a929
Signed-off-by: Oleg Drokin <oleg.drokin@intel.com>
Reviewed-on: http://review.whamcloud.com/5882
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Jian Yu <jian.yu@intel.com>
Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com>
lustre/tests/sanity.sh

index c70826e..d5ce819 100644 (file)
@@ -2597,6 +2597,12 @@ test_34h() {
             # flush when getting the group lock
        $MULTIOP $DIR/$tfile OG${gid}T${sz}g${gid}c &
        MULTIPID=$!
             # flush when getting the group lock
        $MULTIOP $DIR/$tfile OG${gid}T${sz}g${gid}c &
        MULTIPID=$!
+
+       # Since just timed wait is not good enough, let's do a sync write
+       # that way we are sure enough time for a roundtrip + processing
+       # passed + 2 seconds of extra margin.
+       dd if=/dev/zero of=$DIR/${tfile}-1 bs=4096 oflag=direct count=1
+       rm $DIR/${tfile}-1
        sleep 2
 
        if [[ `ps h -o comm -p $MULTIPID` == "multiop" ]]; then
        sleep 2
 
        if [[ `ps h -o comm -p $MULTIPID` == "multiop" ]]; then