[dts] check dpdk process and hugepage status after kill dpdk process
Liu, Yong
yong.liu at intel.com
Tue Jul 14 09:19:12 CEST 2015
Applied in 1.1 branch, removed those message that no process found.
> -----Original Message-----
> From: dts [mailto:dts-bounces at dpdk.org] On Behalf Of huilongx,xu
> Sent: Tuesday, July 14, 2015 2:42 PM
> To: dts at dpdk.org
> Subject: [dts] check dpdk process and hugepage status after kill dpdk
> process
>
> From: huilong xu <huilongx.xu at intel.com>
>
>
> Signed-off-by: huilong xu <huilongx.xu at intel.com>
> ---
> 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
More information about the dts
mailing list