From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) by dpdk.org (Postfix) with ESMTP id 1F9B82A5E for ; Tue, 14 Jul 2015 08:42:44 +0200 (CEST) Received: from fmsmga001.fm.intel.com ([10.253.24.23]) by fmsmga102.fm.intel.com with ESMTP; 13 Jul 2015 23:42:31 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.15,469,1432623600"; d="scan'208";a="746659601" Received: from shvmail01.sh.intel.com ([10.239.29.42]) by fmsmga001.fm.intel.com with ESMTP; 13 Jul 2015 23:42:30 -0700 Received: from shecgisg003.sh.intel.com (shecgisg003.sh.intel.com [10.239.29.90]) by shvmail01.sh.intel.com with ESMTP id t6E6gSmF005439; Tue, 14 Jul 2015 14:42:28 +0800 Received: from shecgisg003.sh.intel.com (localhost [127.0.0.1]) by shecgisg003.sh.intel.com (8.13.6/8.13.6/SuSE Linux 0.8) with ESMTP id t6E6gPWJ014249; Tue, 14 Jul 2015 14:42:27 +0800 Received: (from huilongx@localhost) by shecgisg003.sh.intel.com (8.13.6/8.13.6/Submit) id t6E6gPUP014245; Tue, 14 Jul 2015 14:42:25 +0800 From: "huilongx,xu" To: dts@dpdk.org Date: Tue, 14 Jul 2015 14:42:24 +0800 Message-Id: <1436856144-14214-1-git-send-email-huilongx.xu@intel.com> X-Mailer: git-send-email 1.7.4.1 Subject: [dts] check dpdk process and hugepage status after kill dpdk process X-BeenThere: dts@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: test suite reviews and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Jul 2015 06:42:45 -0000 From: huilong xu Signed-off-by: huilong xu --- framework/crb.py | 19 +++++++++++++++++++ 1 files changed, 19 insertions(+), 0 deletions(-) diff --git a/framework/crb.py b/framework/crb.py index f6ac811..295988b 100644 --- a/framework/crb.py +++ b/framework/crb.py @@ -331,6 +331,25 @@ class Crb(object): cmd = "for i in `lsof /var/run/.rte_config /var/run/dpdk_config \ | awk '/config/ {print $2}'` ; do kill -9 $i; done" self.alt_session.session.send_expect(cmd, "# ", 10) + proce_cmd = "lsof /var/run/.rte_config /var/run/dpdk_config | awk '{print $2}'" + hugepage_cmd = "lsof /var/run/.rte_hugepage_info | awk {print $2}" + out = self.alt_session.session.send_expect(proce_cmd, "# ",10) + if "PID" in out: + self.logger.warning("There are same dpdk process not killed") + self.logger.warning("**************************************") + self.logger.warning(out) + self.logger.warning("**************************************") + else: + self.logger.info("not any dpdk process running") + + out = self.alt_session.session.send_expect(hugepage_cmd, "# ",10) + if "PID" in out: + self.logger.warning("There are some dpdk process not free hugepage") + self.logger.warning("**************************************") + self.logger.warning(out) + self.logger.warning("**************************************") + else: + self.logger.info("not any dpdk process used hugepage") time.sleep(.7) def close(self): -- 1.7.4.4