Re: [LARTC] tc { class | filter } does not work

2002-11-16 Thread Stef Coene
> < snip <--< snip <--< snip <
> root@rana:~# tc filter show
> root@rana:~# tc class show
> root@rana:~# tc qdisc show
> qdisc cbq 1: dev eth0 rate 10Mbit (bounded,isolated) prio no-transmit
> root@rana:~#
> < snip <--< snip <--< snip <
>
> As you can see the qdisc is added, but the class and filter entries don't
> seem to work.
Try
tc filter show dev eth0
tc class show dev eth0
tc qdisc show dev eth0

Stef

-- 

[EMAIL PROTECTED]
 "Using Linux as bandwidth manager"
 http://www.docum.org/
 #lartc @ irc.oftc.net

___
LARTC mailing list / [EMAIL PROTECTED]
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/



Re: [LARTC] tc { class | filter } does not work

2002-11-16 Thread Abraham van der Merwe
Hi Stef!

> > I'm trying to use tc on linux 2.4.20-rc1aa with iproute 20010824-8 (latest
> > debian package), but I'm having no joy.
> The latest version is iproute2-2.4.7-now-ss020116.  I recommend using it.
> 
> > I've attached my kernel config in case you want to check whether I
> > configured the correct stuff (but I pretty much enabled everything - the
> > only odd thing is that I couldn't configure CONFIG_RTNETLINK and
> > CONFIG_NETLINK into the kernel since those options are not available
> > anymore (selected by default nowadays?))
> From your attached config :
> # CONFIG_NETLINK_DEV is not set
> I suggest enabling it and try again.

Ok, I tried a kernel with CONFIG_NETLINK_DEV compiled in and the tc from
iproute2-2.4.7-now-ss020116-try.tar.gz but I still can't see any entries in
the class or filter list. After adding these rules:

< snip <--< snip <--< snip <
tc qdisc add dev eth0 root handle 1: cbq bandwidth 10Mbit cell 8 avpkt 1000 \
mpu 64

tc class add dev eth0 parent 1:0 classid 1:1 cbq bandwidth 10Mbit rate 10Mbit \
allot 1514 cell 8 weight 1Mbit prio 8 maxburst 20 avpkt 1000

tc class add dev eth0 parent 1:1 classid 1:2 cbq bandwidth 10Mbit rate 3Mbit \
allot 1514 cell 8 weight 100Kbit prio 3 maxburst 20 avpkt 1000 split 1:0

tc class add dev eth0 parent 1:1 classid 1:3 cbq bandwidth 10Mbit rate 8Mbit \
allot 1514 cell 8 weight 800Kbit prio 7 maxburst 20 avpkt 1000 split 1:0

tc filter add dev eth0 parent 1:0 protocol ip prio 100 route
< snip <--< snip <--< snip <

I get:

< snip <--< snip <--< snip <
root@rana:~# tc filter show
root@rana:~# tc class show
root@rana:~# tc qdisc show
qdisc cbq 1: dev eth0 rate 10Mbit (bounded,isolated) prio no-transmit
root@rana:~#
< snip <--< snip <--< snip <

As you can see the qdisc is added, but the class and filter entries don't
seem to work.

If I type the same filter rule multiple times, it allows it so I don't think
it is added at all. The class entries seem to be added because I get EEXIST
if I add the same rule multiple times, but it does not show up in ``tc class
show'' - any ideas?

-- 

Regards
 Abraham

Beware of the Turing Tar-pit in which everything is possible but nothing of 
interest is easy.

___
 Abraham vd Merwe [ZR1BBQ] - Frogfoot Networks
 P.O. Box 3472, Matieland, Stellenbosch, 7602
 Cell: +27 82 565 4451 Http: http://www.frogfoot.net
 Email: [EMAIL PROTECTED]




msg02847/pgp0.pgp
Description: PGP signature


Re: [LARTC] tc { class | filter } does not work

2002-11-16 Thread Stef Coene
> I'm trying to use tc on linux 2.4.20-rc1aa with iproute 20010824-8 (latest
> debian package), but I'm having no joy.
The latest version is iproute2-2.4.7-now-ss020116.  I recommend using it.

> I've attached my kernel config in case you want to check whether I
> configured the correct stuff (but I pretty much enabled everything - the
> only odd thing is that I couldn't configure CONFIG_RTNETLINK and
> CONFIG_NETLINK into the kernel since those options are not available
> anymore (selected by default nowadays?))
From your attached config :
# CONFIG_NETLINK_DEV is not set
I suggest enabling it and try again.

Stef

-- 

[EMAIL PROTECTED]
 "Using Linux as bandwidth manager"
 http://www.docum.org/
 #lartc @ irc.oftc.net

___
LARTC mailing list / [EMAIL PROTECTED]
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/



[LARTC] tc { class | filter } does not work

2002-11-16 Thread Abraham van der Merwe
Hi!

I'm trying to use tc on linux 2.4.20-rc1aa with iproute 20010824-8 (latest
debian package), but I'm having no joy.

I can add queueing disciplines, but when I try to add classes or filters, I
just get "RTNETLINK answers: Invalid argument", e.g. when I try to do:

< snip <--< snip <--< snip <
tc qdisc del dev eth0 root
tc qdisc add dev eth0 root handle 1: cbq bandwidth 10Mbit cell 8 avpkt 1000 mpu 64
< snip <--< snip <--< snip <

it works fine and I can see the queueing discipline when I type ``tc qdisc
show'', but when I do:

< snip <--< snip <--< snip <
tc class add dev eth0 parent 1:1 classid 1:2 cbq bandwidth 10Mbit rate 3Mbit \
allot 1514 cell 8 weight 100Kbit prio 3 maxburst 20 avpkt 1000 split 1:0
< snip <--< snip <--< snip <

or

< snip <--< snip <--< snip <
tc class add dev eth0 parent 1:1 classid 1:3 cbq bandwidth 10Mbit rate 8Mbit \
allot 1514 cell 8 weight 800Kbit prio 7 maxburst 20 avpkt 1000 split 1:0
< snip <--< snip <--< snip <

I just get the EINVAL error message. Filters also does not seem to work. I
can add route filters, but ``tc filter show'' shows nothing and adding u32
filters fail with the same error messages as the classes.

I've attached my kernel config in case you want to check whether I
configured the correct stuff (but I pretty much enabled everything - the
only odd thing is that I couldn't configure CONFIG_RTNETLINK and
CONFIG_NETLINK into the kernel since those options are not available anymore
(selected by default nowadays?))

Any help would be appreciated.

-- 

Regards
 Abraham

Accordion, n.:
A bagpipe with pleats.

___
 Abraham vd Merwe [ZR1BBQ] - Frogfoot Networks
 P.O. Box 3472, Matieland, Stellenbosch, 7602
 Cell: +27 82 565 4451 Http: http://www.frogfoot.net
 Email: [EMAIL PROTECTED]


#
# Automatically generated by make menuconfig: don't edit
#
CONFIG_X86=y
# CONFIG_SBUS is not set
CONFIG_UID16=y

#
# Code maturity level options
#
CONFIG_EXPERIMENTAL=y

#
# Loadable module support
#
CONFIG_MODULES=y
# CONFIG_MODVERSIONS is not set
# CONFIG_KMOD is not set

#
# Processor type and features
#
# CONFIG_M386 is not set
# CONFIG_M486 is not set
# CONFIG_M586 is not set
# CONFIG_M586TSC is not set
CONFIG_M586MMX=y
# CONFIG_M686 is not set
# CONFIG_MPENTIUMIII is not set
# CONFIG_MPENTIUM4 is not set
# CONFIG_MK6 is not set
# CONFIG_MK7 is not set
# CONFIG_MELAN is not set
# CONFIG_MCRUSOE is not set
# CONFIG_MWINCHIPC6 is not set
# CONFIG_MWINCHIP2 is not set
# CONFIG_MWINCHIP3D is not set
# CONFIG_MCYRIXIII is not set
CONFIG_X86_WP_WORKS_OK=y
CONFIG_X86_INVLPG=y
CONFIG_X86_CMPXCHG=y
CONFIG_X86_XADD=y
CONFIG_X86_BSWAP=y
CONFIG_X86_POPAD_OK=y
# CONFIG_RWSEM_GENERIC_SPINLOCK is not set
CONFIG_RWSEM_XCHGADD_ALGORITHM=y
CONFIG_X86_L1_CACHE_SHIFT=5
CONFIG_X86_USE_STRING_486=y
CONFIG_X86_ALIGNMENT_16=y
CONFIG_X86_HAS_TSC=y
CONFIG_X86_GOOD_APIC=y
CONFIG_X86_PPRO_FENCE=y
# CONFIG_X86_F00F_WORKS_OK is not set
CONFIG_X86_MCE=y
# CONFIG_TOSHIBA is not set
# CONFIG_I8K is not set
# CONFIG_MICROCODE is not set
# CONFIG_X86_MSR is not set
# CONFIG_X86_CPUID is not set
CONFIG_NOHIGHMEM=y
# CONFIG_HIGHMEM4G is not set
# CONFIG_HIGHMEM64G is not set
# CONFIG_HIGHMEM is not set
# CONFIG_MATH_EMULATION is not set
# CONFIG_MTRR is not set
# CONFIG_SMP is not set
# CONFIG_X86_UP_APIC is not set
# CONFIG_X86_UP_IOAPIC is not set
# CONFIG_X86_TSC_DISABLE is not set
CONFIG_X86_TSC=y

#
# General setup
#
CONFIG_NET=y
CONFIG_PCI=y
# CONFIG_PCI_GOBIOS is not set
# CONFIG_PCI_GODIRECT is not set
CONFIG_PCI_GOANY=y
CONFIG_PCI_BIOS=y
CONFIG_PCI_DIRECT=y
CONFIG_ISA=y
CONFIG_PCI_NAMES=y
# CONFIG_EISA is not set
# CONFIG_MCA is not set
# CONFIG_HOTPLUG is not set
# CONFIG_PCMCIA is not set
# CONFIG_HOTPLUG_PCI is not set
CONFIG_SYSVIPC=y
# CONFIG_BSD_PROCESS_ACCT is not set
CONFIG_SYSCTL=y
CONFIG_KCORE_ELF=y
# CONFIG_KCORE_AOUT is not set
# CONFIG_BINFMT_AOUT is not set
CONFIG_BINFMT_ELF=y
# CONFIG_BINFMT_MISC is not set
CONFIG_PM=y
# CONFIG_ACPI is not set
# CONFIG_APM is not set

#
# Memory Technology Devices (MTD)
#
# CONFIG_MTD is not set

#
# Parallel port support
#
# CONFIG_PARPORT is not set

#
# Plug and Play configuration
#
# CONFIG_PNP is not set
# CONFIG_ISAPNP is not set

#
# Block devices
#
# CONFIG_BLK_DEV_FD is not set
# CONFIG_BLK_DEV_XD is not set
# CONFIG_PARIDE is not set
# CONFIG_BLK_CPQ_DA is not set
# CONFIG_BLK_CPQ_CISS_DA is not set
# CONFIG_CISS_SCSI_TAPE is not set
# CONFIG_BLK_DEV_DAC960 is not set
# CONFIG_BLK_DEV_UMEM is not set
# CONFIG_BLK_DEV_LOOP is not set
# CONFIG_BLK_DEV_NBD is not set
# CONFIG_BLK_DEV_RAM is not set
# CONFIG_BLK_DEV_INITRD is not set
# CONFIG_BLK_STATS is not set

#
# Multi-device support (RAID and LVM)
#
# CONFIG_MD is not set
# CONFIG_BLK_DEV_MD is not set
# CONFIG_MD_LINEAR is not set
# CONFIG_MD_RAID