From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from us-smtp-delivery-44.mimecast.com (us-smtp-delivery-44.mimecast.com [207.211.30.44]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 087EA14830A for ; Mon, 13 May 2024 09:19:37 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=207.211.30.44 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715591980; cv=none; b=h1ejxEtySMztGrf3HUfJPTq3E9Qvf3hQdXjwlkTjQEshVQKFosUyJ3ddYYeYJPBB/tsSONqrlUlODrHZIDk/d2nq3ByQ6orrrUzAHiw34lxJFuh7QdT8iboaCZgjc10lsYd1pkLIZorrqzydews20exzgib6WpMBhmFbyaOsW6Q= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715591980; c=relaxed/simple; bh=BvfSL6a0BYXcbQI3thD0KVAe7Na93xx4QgVn60+W+IM=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: In-Reply-To:Content-Type:Content-Disposition; b=h3Fm0etUrBR6ByOrvnulOZGzGgpyPnCndKjpQeHQNnN3LLDrRU16CkuJRhyKvAC3Luh0GJLbhw/Mbv47zR5KmYFUEKJqN+ae/Npu1kMAAVMMXTfEvgBhWid05b1lDmz5CeSSPYxkNVq21IGhypSKmzjETzOimkvntpyrWU2+E+A= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=queasysnail.net; spf=none smtp.mailfrom=queasysnail.net; arc=none smtp.client-ip=207.211.30.44 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=queasysnail.net Authentication-Results: smtp.subspace.kernel.org; spf=none smtp.mailfrom=queasysnail.net Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-359--yO67p5hMdu01yAkMIFHFw-1; Mon, 13 May 2024 05:19:15 -0400 X-MC-Unique: -yO67p5hMdu01yAkMIFHFw-1 Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.rdu2.redhat.com [10.11.54.4]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 43DB28001F7; Mon, 13 May 2024 09:19:15 +0000 (UTC) Received: from hog (unknown [10.39.192.5]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 0F9772026D6E; Mon, 13 May 2024 09:19:13 +0000 (UTC) Date: Mon, 13 May 2024 11:19:12 +0200 From: Sabrina Dubroca To: Antonio Quartulli Cc: netdev@vger.kernel.org, Jakub Kicinski , Sergey Ryazanov , Paolo Abeni , Eric Dumazet , Andrew Lunn , Esben Haabendal Subject: Re: [PATCH net-next v3 12/24] ovpn: store tunnel and transport statistics Message-ID: References: <20240506011637.27272-1-antonio@openvpn.net> <20240506011637.27272-13-antonio@openvpn.net> Precedence: bulk X-Mailing-List: netdev@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 In-Reply-To: X-Scanned-By: MIMEDefang 3.4.1 on 10.11.54.4 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: queasysnail.net Content-Type: text/plain; charset=UTF-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable 2024-05-13, 09:25:29 +0200, Antonio Quartulli wrote: > On 12/05/2024 10:47, Sabrina Dubroca wrote: > > 2024-05-06, 03:16:25 +0200, Antonio Quartulli wrote: > > > Byte/packet counters for in-tunnel and transport streams > > > are now initialized and updated as needed. > > >=20 > > > To be exported via netlink. > > >=20 > > > Signed-off-by: Antonio Quartulli > > > --- > > > drivers/net/ovpn/Makefile | 1 + > > > drivers/net/ovpn/io.c | 10 ++++++++ > > > drivers/net/ovpn/peer.c | 3 +++ > > > drivers/net/ovpn/peer.h | 13 +++++++--- > > > drivers/net/ovpn/stats.c | 21 ++++++++++++++++ > > > drivers/net/ovpn/stats.h | 52 ++++++++++++++++++++++++++++++++++++= +++ > >=20 > > What I'm seeing in this patch are "success" counters. I don't see any > > stats for dropped packets that would help the user figure out why > > their VPN isn't working, or why their CPU is burning up decrypting > > packets that don't show up on the host, etc. You can guess there are > > issues by subtracting the link and vpn stats, but that's very limited. >=20 > This stats are just the bare minimum to make our current userspace happy = :-) >=20 > But we can always extend the stats reporting later on, no? >=20 > >=20 > > For example: > > - counter for packets dropped during the udp encap/decap > > - counter for failed encrypt/decrypt (especially failed decrypt) > > - counter for replay protection failures > > - counter for malformed packets > >=20 > > Maybe not a separate counter for each of the prints you added in the > > rx/tx code, but at least enough of them to start figuring out what's > > going on without enabling all the prints and parsing dmesg. >=20 > Definitely a good suggestion! I'd just postpone it for later, unless you > think it's a blocker. I'm not sure. It's not strictly necessary to make the driver work, but from a user/admin's point of view, I think counters would be really useful. Maybe at least increment the rx_dropped/rx_errors/etc counters from rtnl_link_stats on the netdevice? > indeed, darn. Juggling this many patches has been quite tedious > > >=20 > Yeah..I guess I'll write a small script to catch all these things..it's e= asy > to lose them across the whole patchset. >=20 > Thanks for spotting them! I will make sure they all go away Thanks. I know it's painful :( --=20 Sabrina