From: Changli Gao <xiaosuo@gmail.com>
To: Luciano Coelho <luciano.coelho@nokia.com>
Cc: "netfilter-devel@vger.kernel.org"
<netfilter-devel@vger.kernel.org>,
Patrick McHardy <kaber@trash.net>,
Pablo Neira Ayuso <pablo@netfilter.org>,
Samuel Ortiz <sameo@linux.intel.com>,
Jan Engelhardt <jengelh@medozas.de>
Subject: Re: [RFC] setting up throughput threshold indications to userspace
Date: Mon, 16 Aug 2010 22:13:13 +0800 [thread overview]
Message-ID: <AANLkTikd75p0UU-SVp2yXPHR4KJeZJxzbD4QYmNAUUMA@mail.gmail.com> (raw)
In-Reply-To: <1281967287.27200.37.camel@chilepepper>
On Mon, Aug 16, 2010 at 10:01 PM, Luciano Coelho
<luciano.coelho@nokia.com> wrote:
> On Mon, 2010-08-16 at 15:51 +0200, ext Changli Gao wrote:
>>
>> You can implement a daemon: which samples the statistics data of NIC
>> periodically, calculates the average bandwidth in a period, and change
>> the condition variables accordingly.
>
> We don't want to use polling from userspace. That's the reason why we
> decided to use iptables instead. The idea is that we will only notify
> the userspace when the throughput crosses the threshold line. And the
> rules I defined above are working rather well, except for this "detail"
> that the BELOW signal is not sent when there's no data flowing.
>
There is a daemon watching the ABOVE signal in any way. How about
staring a timer, which is used to check if there is no packet
transfered in a period, in this daemon when receiving the ABOVE
signal, and stopping this timer when receiving the BELOW signal? It is
like the implementation of IDLETIMER in user space.
--
Regards,
Changli Gao(xiaosuo@gmail.com)
--
To unsubscribe from this list: send the line "unsubscribe netfilter-devel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
next prev parent reply other threads:[~2010-08-16 14:13 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-07-16 8:20 [RFC] setting up throughput threshold indications to userspace Luciano Coelho
2010-07-16 13:01 ` Patrick McHardy
2010-07-16 13:10 ` Luciano Coelho
2010-07-16 19:27 ` Jan Engelhardt
2010-07-19 5:30 ` Luciano Coelho
2010-08-16 13:40 ` Luciano Coelho
2010-08-16 13:51 ` Changli Gao
2010-08-16 14:01 ` Luciano Coelho
2010-08-16 14:13 ` Changli Gao [this message]
2010-08-16 14:26 ` Luciano Coelho
2010-08-16 15:19 ` Jan Engelhardt
2010-08-17 5:27 ` Luciano Coelho
2010-08-16 14:26 ` Changli Gao
2010-08-16 14:32 ` Luciano Coelho
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=AANLkTikd75p0UU-SVp2yXPHR4KJeZJxzbD4QYmNAUUMA@mail.gmail.com \
--to=xiaosuo@gmail.com \
--cc=jengelh@medozas.de \
--cc=kaber@trash.net \
--cc=luciano.coelho@nokia.com \
--cc=netfilter-devel@vger.kernel.org \
--cc=pablo@netfilter.org \
--cc=sameo@linux.intel.com \
/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).