From: Tarun Khanna <tkhanna@akamai.com>
To: Florian Westphal <fw@strlen.de>
Cc: <netfilter-devel@vger.kernel.org>
Subject: Re: per flow stats collection using libnetfilter_conntrack
Date: Mon, 27 Feb 2017 17:36:33 -0500 [thread overview]
Message-ID: <f64a7498-a68c-cc10-7adc-0df35fc60d96@akamai.com> (raw)
In-Reply-To: <20170227221258.GA30877@breakpoint.cc>
On 02/27/2017 05:12 PM, Florian Westphal wrote:
> Tarun Khanna <tkhanna@akamai.com> wrote:
>> Is it possible to register for callbacks so that a user application is
>> updated on a regular basis when the packet or bytes counts change for flows?
> No, update to packet/byte count doesn't trigger an event (it would
> trigger too often).
I was hoping if there was an option to set a timeout, so that an update
would trigger every 5 seconds for flows where the counters have changed.
>
>> I can poll the stats using something similar to "conntrack -L". However, I
>> was wondering if it's possible to be notified regularly on updates.
> No. What semantics would you be interested in?
>
> Dumping is quite fast, whats the problem you need to solve?
I have an application that needs to keep track of per flow stats for all
tcp flows destined to port 80. The best way I have found so far is to
call nfct_query regularly and to go through each flow returned to
retrieve the counters. Would that be the best way to do it?
Thank you for your assistance.
next prev parent reply other threads:[~2017-02-27 22:36 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-02-27 20:49 per flow stats collection using libnetfilter_conntrack Tarun Khanna
2017-02-27 22:12 ` Florian Westphal
2017-02-27 22:36 ` Tarun Khanna [this message]
2017-03-09 9:40 ` Florian Westphal
2017-03-09 15:52 ` Tarun Khanna
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=f64a7498-a68c-cc10-7adc-0df35fc60d96@akamai.com \
--to=tkhanna@akamai.com \
--cc=fw@strlen.de \
--cc=netfilter-devel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).