All of lore.kernel.org
 help / color / mirror / Atom feed
* [LARTC] New Qdisc - How to
@ 2004-05-20 17:04 Ricardo Leite
  2004-05-20 18:08 ` Andreas Klauer
                   ` (6 more replies)
  0 siblings, 7 replies; 8+ messages in thread
From: Ricardo Leite @ 2004-05-20 17:04 UTC (permalink / raw)
  To: lartc


Hello Lartc's users,

This is my first contact.


I'm trying to implement a new queue discipline based on bfifo schedule.
I search on internet but there are some problem(s) that I don't Know how to 
solve them and that's why I'm here asking for your help.

Well,
These were my steps for the implementation:

- Put the new qdisc routine "sch_ric.c" into the directory 
"/usr/src/linux/net/sched/" ,

- Insert a new line on the file "/net/sched/Makefile",

- Insert a new line on the file "/net/sched/Config.in",

- Insert a new line on the file "/include/linux/pkt_sched.h",

- Insert a new line on the file "/net/sched/sch_api.c"


Then I created a new kernel, which include the new qdisc:

- make menuconfig
- make dep
- make clean
- make bzImage
- make modules
- make modules_install
- Change the lilo.conf

Reboot

when I tried to program my qdisc with the tc command

tc qdisc add dev eth0 root bric limit 10

the kernel (or the tc command) couldn't find the the bric qdisc.



I think that I shoud change more files, but I don't know which they are.
Do you know what am I doing wrong?


Cheers!
Para os Portistas...Saudações Dragonárias



Ricardo Leite

_________________________________________________________________
MSN Messenger: converse com os seus amigos online.  
http://messenger.msn.com.br

_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [LARTC] New Qdisc - How to
  2004-05-20 17:04 [LARTC] New Qdisc - How to Ricardo Leite
@ 2004-05-20 18:08 ` Andreas Klauer
  2004-05-20 18:18 ` Alessandro O. Ungaro
                   ` (5 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: Andreas Klauer @ 2004-05-20 18:08 UTC (permalink / raw)
  To: lartc

Am Thursday 20 May 2004 19:04 schrieb Ricardo Leite:
> - Put the new qdisc routine "sch_ric.c" into the directory
> "/usr/src/linux/net/sched/" ,
> - Insert a new line on the file "/net/sched/Makefile",
> - Insert a new line on the file "/net/sched/Config.in",
> - Insert a new line on the file "/include/linux/pkt_sched.h",
> - Insert a new line on the file "/net/sched/sch_api.c"

That's the kernel part.

> tc qdisc add dev eth0 root bric limit 10
>
> the kernel (or the tc command) couldn't find the the bric qdisc.

I haven't read the source, but I assume - seeing how tc needs to be patched 
in order to support HTB - that you need to add support for your scheduler 
to the tc program itself too.

Andreas
_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [LARTC] New Qdisc - How to
  2004-05-20 17:04 [LARTC] New Qdisc - How to Ricardo Leite
  2004-05-20 18:08 ` Andreas Klauer
@ 2004-05-20 18:18 ` Alessandro O. Ungaro
  2004-05-20 18:33 ` Damjan
                   ` (4 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: Alessandro O. Ungaro @ 2004-05-20 18:18 UTC (permalink / raw)
  To: lartc

Ricardo,

you need to change the tc source too

ps: saudações :)

[]'s

x-arnie

Ricardo Leite wrote:

>
> Hello Lartc's users,
>
> This is my first contact.
>
>
> I'm trying to implement a new queue discipline based on bfifo schedule.
> I search on internet but there are some problem(s) that I don't Know 
> how to solve them and that's why I'm here asking for your help.
>
> Well,
> These were my steps for the implementation:
>
> - Put the new qdisc routine "sch_ric.c" into the directory 
> "/usr/src/linux/net/sched/" ,
>
> - Insert a new line on the file "/net/sched/Makefile",
>
> - Insert a new line on the file "/net/sched/Config.in",
>
> - Insert a new line on the file "/include/linux/pkt_sched.h",
>
> - Insert a new line on the file "/net/sched/sch_api.c"
>
>
> Then I created a new kernel, which include the new qdisc:
>
> - make menuconfig
> - make dep
> - make clean
> - make bzImage
> - make modules
> - make modules_install
> - Change the lilo.conf
>
> Reboot
>
> when I tried to program my qdisc with the tc command
>
> tc qdisc add dev eth0 root bric limit 10
>
> the kernel (or the tc command) couldn't find the the bric qdisc.
>
>
>
> I think that I shoud change more files, but I don't know which they are.
> Do you know what am I doing wrong?
>
>
> Cheers!
> Para os Portistas...Saudações Dragonárias
>
>
>
> Ricardo Leite
>
> _________________________________________________________________
> MSN Messenger: converse com os seus amigos online.  
> http://messenger.msn.com.br
>
> _______________________________________________
> LARTC mailing list / LARTC@mailman.ds9a.nl
> http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/
>
>

_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [LARTC] New Qdisc - How to
  2004-05-20 17:04 [LARTC] New Qdisc - How to Ricardo Leite
  2004-05-20 18:08 ` Andreas Klauer
  2004-05-20 18:18 ` Alessandro O. Ungaro
@ 2004-05-20 18:33 ` Damjan
  2004-05-20 20:54 ` Ricardo Leite
                   ` (3 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: Damjan @ 2004-05-20 18:33 UTC (permalink / raw)
  To: lartc

> when I tried to program my qdisc with the tc command
> 
> tc qdisc add dev eth0 root bric limit 10
> 
> the kernel (or the tc command) couldn't find the the bric qdisc.

unfortunatelly the TC userspace program needs to be patched also.

(and that really sucks, I bet there's a more elegant sollution but its
not implemented ... maybe something like Radius Atribute-Value-Pairs so
that you only need to update a dictionary in order for the TC utility to
recognize the new features)

-- 
damjan | дамјан
This is my jabber ID --> damjan@bagra.net.mk <-- not my mail address!!!
_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [LARTC] New Qdisc - How to
  2004-05-20 17:04 [LARTC] New Qdisc - How to Ricardo Leite
                   ` (2 preceding siblings ...)
  2004-05-20 18:33 ` Damjan
@ 2004-05-20 20:54 ` Ricardo Leite
  2004-05-20 23:52 ` Andy Furniss
                   ` (2 subsequent siblings)
  6 siblings, 0 replies; 8+ messages in thread
From: Ricardo Leite @ 2004-05-20 20:54 UTC (permalink / raw)
  To: lartc

I already saw some messages...
And Thanks to all



Message from Andreas and completed by DamJan

I haven't read the source, but I assume - seeing how tc needs to be patched
in order to support HTB - that you need to add support for your scheduler
to the tc program itself too.

unfortunatelly the TC userspace program needs to be patched also

How can I do that?

******************

Message from X-Arnie

you need to change the tc source too


my tc source it's on /sbin/tc

I think this is the right place for the source, isn't it?

******************


I saw in the internet an example which someone change the file "tc_qdisc.c" 
on /iproute2/tc/
I've got /iproute2 but I can't find /iproute2/tc maybe this is the problem.

I don't know how to push tc into iproute2 and into the sbin/tc there isn't 
the file tc_qdisc.c







Hey,Ho! Ramones Let's Go...





>From: Andreas Klauer <Andreas.Klauer@metamorpher.de>
>To: lartc@mailman.ds9a.nl
>Subject: Re: [LARTC] New Qdisc - How to
>Date: Thu, 20 May 2004 20:08:31 +0200
>
>Am Thursday 20 May 2004 19:04 schrieb Ricardo Leite:
> > - Put the new qdisc routine "sch_ric.c" into the directory
> > "/usr/src/linux/net/sched/" ,
> > - Insert a new line on the file "/net/sched/Makefile",
> > - Insert a new line on the file "/net/sched/Config.in",
> > - Insert a new line on the file "/include/linux/pkt_sched.h",
> > - Insert a new line on the file "/net/sched/sch_api.c"
>
>That's the kernel part.
>
> > tc qdisc add dev eth0 root bric limit 10
> >
> > the kernel (or the tc command) couldn't find the the bric qdisc.
>
>I haven't read the source, but I assume - seeing how tc needs to be patched
>in order to support HTB - that you need to add support for your scheduler
>to the tc program itself too.
>
>Andreas
>_______________________________________________
>LARTC mailing list / LARTC@mailman.ds9a.nl
>http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/

_________________________________________________________________
MSN Messenger: converse com os seus amigos online. 
http://messenger.msn.com.br

_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [LARTC] New Qdisc - How to
  2004-05-20 17:04 [LARTC] New Qdisc - How to Ricardo Leite
                   ` (3 preceding siblings ...)
  2004-05-20 20:54 ` Ricardo Leite
@ 2004-05-20 23:52 ` Andy Furniss
  2004-05-21 15:55 ` Stephen Hemminger
  2004-05-22 20:25 ` Ricardo Leite
  6 siblings, 0 replies; 8+ messages in thread
From: Andy Furniss @ 2004-05-20 23:52 UTC (permalink / raw)
  To: lartc

Ricardo Leite wrote:
> I already saw some messages...
> And Thanks to all
> 
> 
> 
> Message from Andreas and completed by DamJan
> 
> I haven't read the source, but I assume - seeing how tc needs to be patched
> in order to support HTB - that you need to add support for your scheduler
> to the tc program itself too.
> 
> unfortunatelly the TC userspace program needs to be patched also
> 
> How can I do that?
> 
> ******************

Have a look at how esfq does it

www.jessingale.dsl.pipex.com/iproute2-2.2.4-now-ss001007-esfq.diff

The source code for TC is part of iproute2 at 
ftp://ftp.inr.ac.ru/ip-routing/ .

Andy.

_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [LARTC] New Qdisc - How to
  2004-05-20 17:04 [LARTC] New Qdisc - How to Ricardo Leite
                   ` (4 preceding siblings ...)
  2004-05-20 23:52 ` Andy Furniss
@ 2004-05-21 15:55 ` Stephen Hemminger
  2004-05-22 20:25 ` Ricardo Leite
  6 siblings, 0 replies; 8+ messages in thread
From: Stephen Hemminger @ 2004-05-21 15:55 UTC (permalink / raw)
  To: lartc

On Thu, 20 May 2004 20:08:31 +0200
Andreas Klauer <Andreas.Klauer@metamorpher.de> wrote:

> Am Thursday 20 May 2004 19:04 schrieb Ricardo Leite:
> > - Put the new qdisc routine "sch_ric.c" into the directory
> > "/usr/src/linux/net/sched/" ,
> > - Insert a new line on the file "/net/sched/Makefile",
> > - Insert a new line on the file "/net/sched/Config.in",
> > - Insert a new line on the file "/include/linux/pkt_sched.h",
> > - Insert a new line on the file "/net/sched/sch_api.c"
> 
> That's the kernel part.
> 
> > tc qdisc add dev eth0 root bric limit 10
> >
> > the kernel (or the tc command) couldn't find the the bric qdisc.
> 
> I haven't read the source, but I assume - seeing how tc needs to be patched 
> in order to support HTB - that you need to add support for your scheduler 
> to the tc program itself too.

Actually, the tc program supports adding disciplines w/o recompiling. 
Haven't tried it, but it looks for a shared library called q_XXX.so
(where XXX is the new queue name).  The shared object needs to define
a struct qdisc_util that defines the new disciplines handles.
_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [LARTC] New Qdisc - How to
  2004-05-20 17:04 [LARTC] New Qdisc - How to Ricardo Leite
                   ` (5 preceding siblings ...)
  2004-05-21 15:55 ` Stephen Hemminger
@ 2004-05-22 20:25 ` Ricardo Leite
  6 siblings, 0 replies; 8+ messages in thread
From: Ricardo Leite @ 2004-05-22 20:25 UTC (permalink / raw)
  To: lartc


Hello again,

The problem is almost solved (I thing)
I re-instaled the iproute2......this time with /tc into /iproute2 and 
modified three files:

- Makefile (modify)
- tc_qdisc.c (modify)
- q_bric.c (new)

Once more, the files are based on bfifo schedule

I compiled them with gcc and the only things I'd got were a lot of warnings 
and erros caused by others files.

the ggc line was:

gcc -c -O2 -fomit-frame-pointer -fno-strict-aliasing 
-I/usr/src/linux/include -DMODULE -DMODVERSION -D__KERNEL__ -Wall 
-Wstrict-prototypes -pipe -o file_out.o file_in.c

where file_in were tc_qdisc.c and q_bric.c


Do you have some idea where I failled?



Thanks on advance.
RIcardo Leite








>From: Stephen Hemminger <shemminger@osdl.org>
>To: Andreas Klauer <Andreas.Klauer@metamorpher.de>
>CC: lartc@mailman.ds9a.nl
>Subject: Re: [LARTC] New Qdisc - How to
>Date: Fri, 21 May 2004 08:55:08 -0700
>
>On Thu, 20 May 2004 20:08:31 +0200
>Andreas Klauer <Andreas.Klauer@metamorpher.de> wrote:
>
> > Am Thursday 20 May 2004 19:04 schrieb Ricardo Leite:
> > > - Put the new qdisc routine "sch_ric.c" into the directory
> > > "/usr/src/linux/net/sched/" ,
> > > - Insert a new line on the file "/net/sched/Makefile",
> > > - Insert a new line on the file "/net/sched/Config.in",
> > > - Insert a new line on the file "/include/linux/pkt_sched.h",
> > > - Insert a new line on the file "/net/sched/sch_api.c"
> >
> > That's the kernel part.
> >
> > > tc qdisc add dev eth0 root bric limit 10
> > >
> > > the kernel (or the tc command) couldn't find the the bric qdisc.
> >
> > I haven't read the source, but I assume - seeing how tc needs to be 
>patched
> > in order to support HTB - that you need to add support for your 
>scheduler
> > to the tc program itself too.
>
>Actually, the tc program supports adding disciplines w/o recompiling.
>Haven't tried it, but it looks for a shared library called q_XXX.so
>(where XXX is the new queue name).  The shared object needs to define
>a struct qdisc_util that defines the new disciplines handles.
>_______________________________________________
>LARTC mailing list / LARTC@mailman.ds9a.nl
>http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/

_________________________________________________________________
MSN Messenger: converse com os seus amigos online. 
http://messenger.msn.com.br

_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2004-05-22 20:25 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-05-20 17:04 [LARTC] New Qdisc - How to Ricardo Leite
2004-05-20 18:08 ` Andreas Klauer
2004-05-20 18:18 ` Alessandro O. Ungaro
2004-05-20 18:33 ` Damjan
2004-05-20 20:54 ` Ricardo Leite
2004-05-20 23:52 ` Andy Furniss
2004-05-21 15:55 ` Stephen Hemminger
2004-05-22 20:25 ` Ricardo Leite

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.