From mboxrd@z Thu Jan 1 00:00:00 1970 From: Lucas Meneghel Rodrigues Subject: Re: [Autotest] [KVM-AUTOTEST PATCH] KVM test: make use of tcpdump optional Date: Tue, 25 May 2010 20:47:25 -0300 Message-ID: <1274831245.2567.3.camel@freedom> References: <1274102975-32453-1-git-send-email-mgoldish@redhat.com> <1274102975-32453-2-git-send-email-mgoldish@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit Cc: autotest@test.kernel.org, kvm@vger.kernel.org, ryanh@us.ibm.com To: Michael Goldish Return-path: Received: from mx1.redhat.com ([209.132.183.28]:43007 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751024Ab0EYXra (ORCPT ); Tue, 25 May 2010 19:47:30 -0400 In-Reply-To: <1274102975-32453-2-git-send-email-mgoldish@redhat.com> Sender: kvm-owner@vger.kernel.org List-ID: On Mon, 2010-05-17 at 16:29 +0300, Michael Goldish wrote: > To disable tcpdump, set 'run_tcpdump = no' in a config file. > If 'run_tcpdump' isn't set at all, it defaults to 'yes'. > > (Currently TAP mode cannot be used without tcpdump.) Ok, I agree with your reasoning, commited as: http://autotest.kernel.org/changeset/4562 Copying Ryan. > Signed-off-by: Michael Goldish > --- > client/tests/kvm/kvm_preprocessing.py | 2 +- > client/tests/kvm/tests_base.cfg.sample | 1 + > 2 files changed, 2 insertions(+), 1 deletions(-) > > diff --git a/client/tests/kvm/kvm_preprocessing.py b/client/tests/kvm/kvm_preprocessing.py > index 50db65c..e11207a 100644 > --- a/client/tests/kvm/kvm_preprocessing.py > +++ b/client/tests/kvm/kvm_preprocessing.py > @@ -196,7 +196,7 @@ def preprocess(test, params, env): > if "tcpdump" in env and not env["tcpdump"].is_alive(): > env["tcpdump"].close() > del env["tcpdump"] > - if "tcpdump" not in env: > + if "tcpdump" not in env and params.get("run_tcpdump", "yes") == "yes": > command = "/usr/sbin/tcpdump -npvi any 'dst port 68'" > logging.debug("Starting tcpdump (%s)...", command) > env["tcpdump"] = kvm_subprocess.kvm_tail( > diff --git a/client/tests/kvm/tests_base.cfg.sample b/client/tests/kvm/tests_base.cfg.sample > index c9dfd0b..1276267 100644 > --- a/client/tests/kvm/tests_base.cfg.sample > +++ b/client/tests/kvm/tests_base.cfg.sample > @@ -46,6 +46,7 @@ nic_mode = user > #nic_mode = tap > nic_script = scripts/qemu-ifup > address_index = 0 > +run_tcpdump = yes > > # Misc > run_kvm_stat = yes