From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga14.intel.com (mga14.intel.com [192.55.52.115]) by dpdk.org (Postfix) with ESMTP id 1C2832A58 for ; Tue, 14 Jul 2015 09:22:24 +0200 (CEST) Received: from fmsmga001.fm.intel.com ([10.253.24.23]) by fmsmga103.fm.intel.com with ESMTP; 14 Jul 2015 00:22:13 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.15,470,1432623600"; d="scan'208";a="746679252" Received: from kmsmsx154.gar.corp.intel.com ([172.21.73.14]) by fmsmga001.fm.intel.com with ESMTP; 14 Jul 2015 00:22:04 -0700 Received: from shsmsx104.ccr.corp.intel.com (10.239.110.15) by KMSMSX154.gar.corp.intel.com (172.21.73.14) with Microsoft SMTP Server (TLS) id 14.3.224.2; Tue, 14 Jul 2015 15:19:13 +0800 Received: from shsmsx103.ccr.corp.intel.com ([169.254.4.46]) by SHSMSX104.ccr.corp.intel.com ([169.254.5.129]) with mapi id 14.03.0224.002; Tue, 14 Jul 2015 15:19:12 +0800 From: "Liu, Yong" To: "Xu, HuilongX" , "dts@dpdk.org" Thread-Topic: [dts] check dpdk process and hugepage status after kill dpdk process Thread-Index: AQHQvgBhWo8WqZaLnU+mX3hroVO5uJ3ajqKQ Date: Tue, 14 Jul 2015 07:19:12 +0000 Message-ID: <86228AFD5BCD8E4EBFD2B90117B5E81E10E612AD@SHSMSX103.ccr.corp.intel.com> References: <1436856144-14214-1-git-send-email-huilongx.xu@intel.com> In-Reply-To: <1436856144-14214-1-git-send-email-huilongx.xu@intel.com> Accept-Language: zh-CN, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.239.127.40] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Subject: Re: [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 07:22:25 -0000 Applied in 1.1 branch, removed those message that no process found. > -----Original Message----- > From: dts [mailto:dts-bounces@dpdk.org] On Behalf Of huilongx,xu > Sent: Tuesday, July 14, 2015 2:42 PM > To: dts@dpdk.org > Subject: [dts] check dpdk process and hugepage status after kill dpdk > process >=20 > From: huilong xu >=20 >=20 > Signed-off-by: huilong xu > --- > framework/crb.py | 19 +++++++++++++++++++ > 1 files changed, 19 insertions(+), 0 deletions(-) >=20 > 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 =3D "for i in `lsof /var/run/.rte_config /var/run/dpdk_confi= g \ > | awk '/config/ {print $2}'` ; do kill -9 $i; done" > self.alt_session.session.send_expect(cmd, "# ", 10) > + proce_cmd =3D "lsof /var/run/.rte_config /var/run/dpdk_config | = awk > '{print $2}'" > + hugepage_cmd =3D "lsof /var/run/.rte_hugepage_info | awk {print > $2}" > + out =3D 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 =3D 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) >=20 > def close(self): > -- > 1.7.4.4