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 94FFCA0093; Tue, 8 Nov 2022 17:40:26 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 716DF400D7; Tue, 8 Nov 2022 17:40:26 +0100 (CET) Received: from mail-pg1-f175.google.com (mail-pg1-f175.google.com [209.85.215.175]) by mails.dpdk.org (Postfix) with ESMTP id 3F053400D4 for ; Tue, 8 Nov 2022 17:40:25 +0100 (CET) Received: by mail-pg1-f175.google.com with SMTP id o13so4554728pgu.7 for ; Tue, 08 Nov 2022 08:40:25 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20210112.gappssmtp.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:subject:cc:to:from:date:from:to:cc:subject:date :message-id:reply-to; bh=fhpxGcIK/VbAPn4UdKCuspcs9kZumE9AtnMSWofevBI=; b=cjabg43xZ/STP+lbjz/QxtPhOVedGBM/nwXra1liiHxowrO/nMuahIww+joPZdv1aU /QL+g4Xk//r//qJwwdYDOa+JX11+uQ57FpakOmzWEfaIuuVHF00iQOSpr6YqFura10ub 5p80TzkFjzDeVvJyn3Z+QR9JAW7IMk53Y0AbknWM6U+Uw7FjHyWJuv/6IXTta4Ny8Os4 eeRSLmYmnWKa3Zt2rSt0BYE2sVcP4mr/k7acaB/iGzAzr7zPFeJk+mfhhqwjSkQmHG60 XjcxD/H77oX5VhDacQsO5jEI26l0sQNs1btpw/cJ38fLQ+XFlNqN8TaUlbS5gzMWHvfO LvsA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:subject:cc:to:from:date:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=fhpxGcIK/VbAPn4UdKCuspcs9kZumE9AtnMSWofevBI=; b=IoFId71PY9M2t0XNe1MtUwWo4lfDTHjfE4t9Gqb0mmUJIW5ksbiDSFdNY/pzijKdWd 4dNf628TNjykof71BeE5aJA/EMee9GTKyNu3NwlHfR1R3bH1nmxP673ESclJMmFzNlrp R/aLgbvZMqclUU9WIZBOvLjNmblZvV2kAuYIuiakOBicPnXJ6jE3VyCvSUuZGYqYpy+f TklVxRNTz7mHPgGl+il/BzRlfYxG3eMXbuzkMGg+XESYTHImkm7XoqIaRp0yU/aE6iSX SO7v+LDCA9IYbiHOITWVj58JkidsrieB+nqL6/SGUTmcbkSQv0VdBZpK0g/qHl6sLL+b g7/w== X-Gm-Message-State: ACrzQf1PbxQwtTU4Xb0aeJ3GknCXMU/QQgzhYL+dcUctBGDPYTSQ1v2s TAeFpe0KWTVqhmProZmwjGoKUQ== X-Google-Smtp-Source: AMsMyM6XTjwDidsm8fi1fIIPVf8U3mnlzhngswt/IE75N6I0vmj8a9jmVV6jKAjDvQlcTZPemQNg+A== X-Received: by 2002:aa7:9ece:0:b0:56c:5afe:67f7 with SMTP id r14-20020aa79ece000000b0056c5afe67f7mr56880561pfq.55.1667925624340; Tue, 08 Nov 2022 08:40:24 -0800 (PST) Received: from hermes.local (204-195-120-218.wavecable.com. [204.195.120.218]) by smtp.gmail.com with ESMTPSA id ij22-20020a170902ab5600b0017f36638010sm7094382plb.276.2022.11.08.08.40.23 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 08 Nov 2022 08:40:23 -0800 (PST) Date: Tue, 8 Nov 2022 08:40:21 -0800 From: Stephen Hemminger To: Owen Hilyard Cc: Honnappa Nagarahalli , "thomas@monjalon.net" , Aman Singh , Yuying Zhang , "david.marchand@redhat.com" , "dev@dpdk.org" , Lijuan Tu , Juraj =?UTF-8?B?TGlua2U=?= =?UTF-8?B?xaE=?= , nd Subject: Re: testpmd logging Message-ID: <20221108084021.251b85ac@hermes.local> In-Reply-To: References: <11915083.eQLIkvUDd3@thomas> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit 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 On Tue, 8 Nov 2022 11:24:53 -0500 Owen Hilyard wrote: > On Tue, Nov 8, 2022 at 9:37 AM Honnappa Nagarahalli < > Honnappa.Nagarahalli@arm.com> wrote: > > > + Lijuan, Owen, Juraj > > > > > -----Original Message----- > > > From: Thomas Monjalon > > > Sent: Tuesday, November 8, 2022 7:02 AM > > > To: Aman Singh ; Yuying Zhang > > > > > > Cc: david.marchand@redhat.com; dev@dpdk.org > > > Subject: testpmd logging > > > > > > Hello, > > > > > > I see testpmd is doing log with EAL entity. Example: > > > RTE_LOG(ERR, EAL, "The device: %s has been added!\n" > > > We could also discuss the log level. > > > > > > Please can we work on replacing these logs? > > > > If we want to revisit logging in testpmd, even though I know I'm invoking a > case of second system syndrome here, I would love to see some form of > structured logging output. Even just writing out records to a CSV file with > proper escaping would work great, or doing a json object per log record as > a backup. JSON might be easier since libjansson is already in DPDK, and we > could disable the json logging flag if libjansson was not present at > compile time. > > > > DTS uses some of the logs from testpmd to validate the results. I am not > > sure what all logs are used. > > > The old version of dts (the one with its own repository) is fairly tightly > bound to testpmd's logging. > > > We need to choose how to log (printf or registered log entity) and be > > > consistent. > > > What do you think? > > > > Registered log entries are much better in my opinion since they provide a > more machine-friendly format and DTS has to parse testpmd output. My thoughts. 1. testpmd should use its own log level, not EAL 2. testpmd could easily have an option "--json" to format output in JSON 3. testpmd is a mess some logs use RTE_LOG() some go to stdout, some to stderr.