linux-lvm.redhat.com archive mirror
 help / color / mirror / Atom feed
From: Heming Zhao <heming.zhao@suse.com>
To: "linux-lvm@redhat.com" <linux-lvm@redhat.com>
Subject: [linux-lvm] It looks wrong for the timeout when lvm test running
Date: Mon, 9 Dec 2019 09:20:22 +0000	[thread overview]
Message-ID: <9fdc2f47-a4db-f472-e1eb-424f6a6b28d9@suse.com> (raw)

Hello List,

The lvm test default timeout (--timeout) default value is 180.
But I met below condition when running testcase (in virtual machine):
```
make check_local T=shell/snapshot-merge.sh
    ... ...
###       passed: [ndev-vanilla] shell/snapshot-merge.sh 665
    ... ...
```

Obviously, the timeout doesn't work normally.
If I change below code, the timeout work as expected. (in lib/brick-shelltest.h)
```
         if ( select( nfds, &set, NULL, NULL, &wait ) > 0 ) {
             silent_start = end; /* something happened */
             io.sync( false );
         }
```

And after change the code, some testcase will become timeout, which may pass before.


The whole patch as below:
```
 From bdbd569c2b9ab49d4a4246f203b1cd9f7049db97 Mon Sep 17 00:00:00 2001
From: Zhao Heming <heming.zhao@suse.com>
Date: Mon, 9 Dec 2019 17:09:17 +0800
Subject: [PATCH] test: fix timeout abnormal issue

---
  test/lib/brick-shelltest.h | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/test/lib/brick-shelltest.h b/test/lib/brick-shelltest.h
index b58f3d6843..12e08249f3 100644
--- a/test/lib/brick-shelltest.h
+++ b/test/lib/brick-shelltest.h
@@ -822,7 +822,7 @@ struct TestCase {
              }
          }
          if ( select( nfds, &set, NULL, NULL, &wait ) > 0 ) {
-            silent_start = end; /* something happened */
+            //silent_start = end; /* something happened */
              io.sync( false );
          }
  
-- 
2.24.0
```

Thanks.

             reply	other threads:[~2019-12-09  9:20 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-12-09  9:20 Heming Zhao [this message]
2019-12-09  9:40 ` [linux-lvm] It looks wrong for the timeout when lvm test running Zdenek Kabelac
2019-12-09 10:58   ` Heming Zhao
2019-12-09 11:36     ` Zdenek Kabelac
2019-12-10  3:23       ` Heming Zhao
2019-12-10  9:03         ` Zdenek Kabelac
2019-12-10  9:11           ` Heming Zhao

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=9fdc2f47-a4db-f472-e1eb-424f6a6b28d9@suse.com \
    --to=heming.zhao@suse.com \
    --cc=linux-lvm@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).