From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 372CBA0A0C; Thu, 1 Jul 2021 16:43:52 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id EAA6E40141; Thu, 1 Jul 2021 16:43:51 +0200 (CEST) Received: from smartserver.smartsharesystems.com (smartserver.smartsharesystems.com [77.243.40.215]) by mails.dpdk.org (Postfix) with ESMTP id 719CB4003E for ; Thu, 1 Jul 2021 16:43:50 +0200 (CEST) Content-class: urn:content-classes:message MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Date: Thu, 1 Jul 2021 16:43:48 +0200 Message-ID: <98CBD80474FA8B44BF855DF32C47DC35C618D0@smartserver.smartshare.dk> In-Reply-To: <20210701093456.43426-1-bruce.richardson@intel.com> X-MimeOLE: Produced By Microsoft Exchange V6.5 X-MS-Has-Attach: X-MS-TNEF-Correlator: Thread-Topic: [dpdk-dev] [PATCH] eal: create runtime dir even when shared data is not used Thread-Index: AdduXGEk2epK7ZHmTgGMqpM9tm6U2gAKngSA References: <20210701093456.43426-1-bruce.richardson@intel.com> From: =?iso-8859-1?Q?Morten_Br=F8rup?= To: "Bruce Richardson" , Cc: Subject: Re: [dpdk-dev] [PATCH] eal: create runtime dir even when shared data is not used X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" > From: dev [mailto:dev-bounces@dpdk.org] On Behalf Of Bruce Richardson > Sent: Thursday, 1 July 2021 11.35 >=20 > When multi-process is not wanted and DPDK is run with the "no-shconf" > flag, the telemetry library still needs a runtime directory to place > the > unix socket for telemetry connections. Therefore, rather than not > creating the directory when this flag is set, we can change the code = to > attempt the creation anyway, but not error out if it fails. If it > succeeds, then telemetry will be available, but if it fails, the rest > of > DPDK will run without telemetry. This ensures that the "in-memory" = flag > will allow DPDK to run even if the whole filesystem is read-only, for > example. >=20 > Signed-off-by: Bruce Richardson > --- > lib/eal/linux/eal.c | 5 ++--- > 1 file changed, 2 insertions(+), 3 deletions(-) >=20 > diff --git a/lib/eal/linux/eal.c b/lib/eal/linux/eal.c > index ba19fc6347..1e05ba3847 100644 > --- a/lib/eal/linux/eal.c > +++ b/lib/eal/linux/eal.c > @@ -838,9 +838,8 @@ eal_parse_args(int argc, char **argv) > } > } >=20 > - /* create runtime data directory */ > - if (internal_conf->no_shconf =3D=3D 0 && > - eal_create_runtime_dir() < 0) { > + /* create runtime data directory. In no_shconf mode, skip any > errors */ > + if (eal_create_runtime_dir() < 0 && internal_conf->no_shconf =3D=3D > 0) { > RTE_LOG(ERR, EAL, "Cannot create runtime directory\n"); > ret =3D -1; > goto out; When internal_conf->no_shconf =3D=3D 1 and eal_create_runtime_dir() = fails, DPDK will run without telemetry. Shouldn't it then be logged that = telemetry is unavailable (and why it is unavailable)? > -- > 2.30.2 >=20