[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[altq:1838] Re: [Q]about CBQ_MAX_CLASSES variable
soyoung@taonetworks.com
> Hi, I have a question about CBQ_MAX_CLASSES variable.
>
> cbq_state_t structure has a 'cbq_class_tbl' member and it is allocated an
> array of size 'CBQ_MAX_CLASSES' in the 'cbq_ifattach' function.
> Currently, CBQ_MAX_CLASSES is defined as 256 in the 'sys/altq/altq_cbq.h',
> and I think this variable shows the 'maximum number of effective simultaneous
> classes for the accuracy in bandwidth allocation' about altq mechanism..
> Am I right?
>
> I need more classes for the CBQ configuration. According to the kernel code,
> if I change the CBQ_MAX_CLASSES to the number greater than 256,
> it doesn't seem to have any problem in compile,
> but I'm not sure all those classes still show the same accuracy
> about their allocated bandwidth.
>
> I think if altq is run on the higher performance system, it doesn't affect
> the accuracy about bandwidth allocation to change CBQ_MAX_CLASSES.
> Is there any recommendation or guide for setting CBQ_MAX_CLASSES variables?
It should be ok to increase CBQ_MAX_CLASSES. (I've never tried it,
though.)
The algorithms used in ALTQ are not optimized for a large number of
classes. But, as you said, today's CPUs are 10 times faster than
the CPU I used for developing altq-0.2 in 1997. So, it won't be a
problem if you double or triple the number of classes.
-Kenjiro