public inbox for kvm@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] KVM Test: add -w parameter in nc command in kvm_utils.py
@ 2010-10-20  6:55 Feng Yang
  2010-10-20  9:11 ` Michael Goldish
  2010-10-27 20:26 ` Lucas Meneghel Rodrigues
  0 siblings, 2 replies; 8+ messages in thread
From: Feng Yang @ 2010-10-20  6:55 UTC (permalink / raw)
  To: autotest; +Cc: kvm

If a connection and stdin are idle for more than timeout seconds,
then the connection is silently closed. withou this paramter,
nc will listen forever for a connection. This may cause our test
hang. redmine issue:
http://redmine.englab.nay.redhat.com/issues/show/6947
Add -w parameter should fix this issue.

Signed-off-by: Feng Yang <fyang@redhat.com>
---
 client/tests/kvm/kvm_utils.py |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/client/tests/kvm/kvm_utils.py b/client/tests/kvm/kvm_utils.py
index a51c857..526d38d 100644
--- a/client/tests/kvm/kvm_utils.py
+++ b/client/tests/kvm/kvm_utils.py
@@ -733,7 +733,7 @@ def remote_login(client, host, port, username, password, prompt, linesep="\n",
     elif client == "telnet":
         cmd = "telnet -l %s %s %s" % (username, host, port)
     elif client == "nc":
-        cmd = "nc %s %s" % (host, port)
+        cmd = "nc %s %s -w %s" % (host, port, timeout)
     else:
         logging.error("Unknown remote shell client: %s" % client)
         return
-- 
1.6.5.2

^ permalink raw reply related	[flat|nested] 8+ messages in thread
[parent not found: <692004637.996981287569640055.JavaMail.root@zmail04.collab.prod.int.phx2.redhat.com>]
[parent not found: <816063419.1092631287625722129.JavaMail.root@zmail04.collab.prod.int.phx2.redhat.com>]

end of thread, other threads:[~2010-10-28  2:34 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-10-20  6:55 [PATCH] KVM Test: add -w parameter in nc command in kvm_utils.py Feng Yang
2010-10-20  9:11 ` Michael Goldish
2010-10-27 20:26 ` Lucas Meneghel Rodrigues
2010-10-28  2:34   ` [Autotest] " Feng Yang
     [not found] <692004637.996981287569640055.JavaMail.root@zmail04.collab.prod.int.phx2.redhat.com>
2010-10-20 10:18 ` Feng Yang
2010-10-20 10:48   ` Michael Goldish
     [not found] <816063419.1092631287625722129.JavaMail.root@zmail04.collab.prod.int.phx2.redhat.com>
2010-10-21  1:57 ` Feng Yang
2010-10-21  7:38   ` Michael Goldish

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox