Discussion:
Interested in {Create an in-kernel API for "packet classes"}
(too old to reply)
Indradip Ghosh
2008-03-31 10:04:57 UTC
Permalink
Hello Mentors,
This is Indradip, a Grad student at University of Texas at Arlington.
I am interested to work on the project {Create an in-kernel API for
"packet classes"} .
My proposal is as follows:


Project Goal:

To create an in-kernel API for registering "packet classes" and for
labeling packets
with their class, for special treatment by traffic shapers (ALTQ) and
by network
interface drivers. Such an approach would entitle network devices support varies
class of service (CoS) based on pre-determined packet transmission priority.


Approach

(a) PF Packet Filter (PF) is a software program for
manipulating actions on packets being
transmitted and received by the NetBSD kernel. PF uses a
configuration file (pf.conf(5))
for reading in the rules that it needs to apply to the network packets.

Among its many abilities, PF allows a packet to be tagged or
marked based on the input
ruleset. Additionally, tags are sticky; implying once a packet
is tagged, the tag can
only be replaced by a subsequent ruleset but can never be
removed. Thus, the flow of
packets inside the kernel can be represented as:

apps_data -> kernel packet -> { PF rules -> tagged packets ->
Actions} -> packets (!dropped)

(b) However, as clear from the above action, the meaning of the
tag is lost as soon the packet
exits the PF environment. Thus, PF has no knowledge of the
device driver queue capabilities.
The only exception is the ALTQ implementation which is
integrated with the PF subsystem.
This allows the PF to implement various interface queuing policies.

(c) One way to handle such 'lost information' is to translate
PF tags to languages understood
by the device driver. The glue for such an approach is the
packet class framework (PCF) being
proposed in this project.

(d) (i) Packet Class Framework (PCF): The object of PCF is to
mark packets with tokens as they leave the
PF subsystem. Tokens are the driver capabilities that are
registered during driver_init ().
For example, an ethernet NIC with high and low-priority
transmit rings may register
classes called 'hipri'(2) and 'lopri' (1). These will
generate tokens t0 and t1 corresponding to
'hipri' and 'lopri'.

Note that these tokens are predefined data structure that
the driver simply
needs to instantiate.
typedef struct all_tokens {
char *drivername; // filled by the driver
char *interface; // filled by the kernel
struct token driver_token; // list of
all tokens with priority
}
(ii) Once the PCF knows the token names and their
corresponding priority, it needs to
match these with the PC tags. Note that tags are
defined based on rulesets.
However, there is a catch. Since the tokens are
driver specific, there appers to be
standard way of defining the tag-token matching grammar.

(iii) To solve this dilemma, whenever the deriver
initializes, the PCF will write the
tokens with priorities under /dev/pcf/<if_name>.
These tokens must be used in the
ruleset of PF.

(iv) Since packets generated from the kernel are mbuf
structures, packets matching the
rulesets will have the tokenens inserted in the
"token" field of the mbuf. This token
field is new and will enable the driver to
associate priority with the token type.

Please let me know if you have some clarifications/ comments/
suggestions in this respect and would
greatly appreciate if you could throw light on any issue that I have
failed to address.


Best Regards,
Indradip.

--
Posted automagically by a mail2news gateway at muc.de e.V.
Please direct questions, flames, donations, etc. to news-***@muc.de
Darren Reed
2008-04-10 06:35:32 UTC
Permalink
Post by Indradip Ghosh
Hello Mentors,
This is Indradip, a Grad student at University of Texas at Arlington.
I am interested to work on the project {Create an in-kernel API for
"packet classes"} .
...

See my comments to Anish's idea...and to summarise...

To validate the project accomplishing a packet class API that is independant
of pf, it needs to be used by another consumer - ipfilter is a good
candidate -
to prove that you've got the API right and not just a divided API for pf.

Darren


--
Posted automagically by a mail2news gateway at muc.de e.V.
Please direct questions, flames, donations, etc. to news-***@muc.de
Ermal Luçi
2008-04-10 16:12:48 UTC
Permalink
Post by Darren Reed
Post by Indradip Ghosh
Hello Mentors,
This is Indradip, a Grad student at University of Texas at Arlington.
I am interested to work on the project {Create an in-kernel API for
"packet classes"} .
...
See my comments to Anish's idea...and to summarise...
To validate the project accomplishing a packet class API that is independant
of pf, it needs to be used by another consumer - ipfilter is a good
candidate -
to prove that you've got the API right and not just a divided API for pf.
One thing that i struggle with. Does this mean that you need to modify
all the drivers to tag/label their packets?!

Or does it mean resurrecting old ALTQ classifier to have a generic way
of doing this and extend it to handle 802.11 or other classes?!

Ermal
Post by Darren Reed
Darren
--
Posted automagically by a mail2news gateway at muc.de e.V.
Please direct questions, flames, donations, etc. to news-***@muc.de
David Young
2008-04-10 19:09:23 UTC
Permalink
Post by Ermal Luçi
Post by Darren Reed
Post by Indradip Ghosh
Hello Mentors,
This is Indradip, a Grad student at University of Texas at Arlington.
I am interested to work on the project {Create an in-kernel API for
"packet classes"} .
...
See my comments to Anish's idea...and to summarise...
To validate the project accomplishing a packet class API that is independant
of pf, it needs to be used by another consumer - ipfilter is a good
candidate -
to prove that you've got the API right and not just a divided API for pf.
One thing that i struggle with. Does this mean that you need to modify
all the drivers to tag/label their packets?!
Or does it mean resurrecting old ALTQ classifier to have a generic way
of doing this and extend it to handle 802.11 or other classes?!
A packet filter is the label producer: PF or IP Filter will classify
packets and apply labels. ALTQ and the network interfaces (PPP,
ethernets, et cetera) are label consumers: they examine the labels, which
help them to decide which traffic category/queue to place the packets in.

Note that ALTQ may be both a consumer and a producer of labels, since
it both classifies and queues.

Dave
--
David Young OJC Technologies
***@ojctech.com Urbana, IL * (217) 278-3933 ext 24

--
Posted automagically by a mail2news gateway at muc.de e.V.
Please direct questions, flames, donations, etc. to news-***@muc.de
Ermal Luçi
2008-04-10 19:55:11 UTC
Permalink
Post by David Young
Post by Ermal Luçi
Post by Darren Reed
Post by Indradip Ghosh
Hello Mentors,
This is Indradip, a Grad student at University of Texas at Arlington.
I am interested to work on the project {Create an in-kernel API for
"packet classes"} .
...
See my comments to Anish's idea...and to summarise...
To validate the project accomplishing a packet class API that is independant
of pf, it needs to be used by another consumer - ipfilter is a good
candidate -
to prove that you've got the API right and not just a divided API for pf.
One thing that i struggle with. Does this mean that you need to modify
all the drivers to tag/label their packets?!
Or does it mean resurrecting old ALTQ classifier to have a generic way
of doing this and extend it to handle 802.11 or other classes?!
A packet filter is the label producer: PF or IP Filter will classify
packets and apply labels. ALTQ and the network interfaces (PPP,
ethernets, et cetera) are label consumers: they examine the labels, which
help them to decide which traffic category/queue to place the packets in.
Note that ALTQ may be both a consumer and a producer of labels, since
it both classifies and queues.
Oh i thought it as applying some default labels that could be matched
in firewalls/filterers/classifiers. Like wireless drivers labeling
their standard priorities and you could match those on the
filterer/classifier or extracting by default 802.1p classes as labels.

So this is the case of unifying the tagging/labeling way across the kernel.
As a note, i really would like if it could be done as pf does it with
strings since it is more natural to be configured. Furthermore, it is
ready and just needs to be extracted from pf and applied to anything
else consuming tags.
The only problem is optimizing the tags zone to have some fast
matching on strings.

Ermal
Post by David Young
Dave
--
David Young OJC Technologies
--
Posted automagically by a mail2news gateway at muc.de e.V.
Please direct questions, flames, donations, etc. to news-***@muc.de
aswani kumar
2008-10-15 20:17:00 UTC
Permalink
Is somebody still working on this project? I searched for the
webpages of gsoc 2008 but couldnt find any useful information. I am
interested in working on this project.
Post by Ermal Luçi
Post by Indradip Ghosh
Post by Ermal Luçi
Post by Darren Reed
Post by Indradip Ghosh
Hello Mentors,
This is Indradip, a Grad student at University of Texas at
Arlington.
Post by Ermal Luçi
Post by Darren Reed
Post by Indradip Ghosh
I am interested to work on the project {Create an in-kernel API
for
Post by Ermal Luçi
Post by Darren Reed
Post by Indradip Ghosh
"packet classes"} .
...
See my comments to Anish's idea...and to summarise...
To validate the project accomplishing a packet class API that is independant
of pf, it needs to be used by another consumer - ipfilter is a good
candidate -
to prove that you've got the API right and not just a divided API
for pf.
Post by Ermal Luçi
One thing that i struggle with. Does this mean that you need to modify
all the drivers to tag/label their packets?!
Or does it mean resurrecting old ALTQ classifier to have a generic way
of doing this and extend it to handle 802.11 or other classes?!
A packet filter is the label producer: PF or IP Filter will classify
packets and apply labels. ALTQ and the network interfaces (PPP,
ethernets, et cetera) are label consumers: they examine the labels, which
help them to decide which traffic category/queue to place the packets in.
Note that ALTQ may be both a consumer and a producer of labels, since
it both classifies and queues.
Oh i thought it as applying some default labels that could be matched
in firewalls/filterers/classifiers. Like wireless drivers labeling
their standard priorities and you could match those on the
filterer/classifier or extracting by default 802.1p classes as labels.
So this is the case of unifying the tagging/labeling way across the kernel.
As a note, i really would like if it could be done as pf does it with
strings since it is more natural to be configured. Furthermore, it is
ready and just needs to be extracted from pf and applied to anything
else consuming tags.
The only problem is optimizing the tags zone to have some fast
matching on strings.
Ermal
Post by Indradip Ghosh
Dave
--
David Young OJC Technologies
--
Nerella, Venkata Aswani Kumar
MS Computer Science

--
Posted automagically by a mail2news gateway at muc.de e.V.
Please direct questions, flames, donations, etc. to news-***@muc.de
Herb Peyerl
2008-10-15 20:22:31 UTC
Permalink
Post by aswani kumar
Is somebody still working on this project? I searched for the
webpages of gsoc 2008 but couldnt find any useful information. I am
interested in working on this project.
as far as I know; no one is working on this. The GSoC project failed.



--
Posted automagically by a mail2news gateway at muc.de e.V.
Please direct questions, flames, donations, etc. to news-***@muc.de
Manuel Bouyer
2008-10-19 13:37:18 UTC
Permalink
Post by Herb Peyerl
Post by aswani kumar
Is somebody still working on this project? I searched for the
webpages of gsoc 2008 but couldnt find any useful information. I am
interested in working on this project.
as far as I know; no one is working on this. The GSoC project failed.
But we still want this, isn't it ?
--
Manuel Bouyer <***@antioche.eu.org>
NetBSD: 26 ans d'experience feront toujours la difference
--

--
Posted automagically by a mail2news gateway at muc.de e.V.
Please direct questions, flames, donations, etc. to news-***@muc.de
Loading...