Bug#149897: The bug you reported about ip route ... equalize ...

2007-12-30 Thread Andras Korn
On Sat, Dec 29, 2007 at 03:15:08PM +0100, Andreas Henriksson wrote:

Hi,

> > Very good to hear this has resolved itself. The only thing that remains
> > is the false statement in the documentation about having to patch the
> > kernel. Lets treat this report as a bug against the documentation from
> > now on. I'll try to dig some and see if I can find it which kernel
> > version the support first appeared.
> 
> It seems like the required patch[1] which implements the feature is only
> available for 2.4.18. As far as I can tell it only /looks/ like it works
> with current kernels, because the kernel has the RTM_F_EQUALIZE flag
> (but no actual implementation). The flag has been there since atleast
> 2.4.0.
> 
> man 7 rtnetlink says:
> "RTM_F_EQUALIZE   a multicast equalizer (not yet implemented)"

This at least should be multipath, not multicast.

> So. Updating the documentation to state the fact that the required
> kernel patch doesn't exist (for kernels supported by Debian) doesn't
> seem very useful.

Oh, I think it would be useful. Maybe add a note to README.Debian to the
tune of "This version of iproute supports multipath route equalization, but
as of 2007-12-30 no kernel implements it. Routes that rely on the 'equalize'
keyword will not work as expected. See
http://www.ussg.iu.edu/hypermail/linux/kernel/0203.2/1314.html and e.g.
http://www.mail-archive.com/[EMAIL PROTECTED]/msg10038.html for more
information."

> Possibly the support for equalize in iproute should be dropped completely
> since it's never been part of any official kernel release, and since it
> hasn't been solved in all these years noone will probably ever implement
> this. I'll ask upstream

I don't know. I see the current situation as being halfway there; adding the
required support to the kernel would be a step forward, while also removing
it from iproute would be a step backward.

Also, removing equalize support from iproute may break scripts that use it,
so that e.g. after a reboot, a box would be unable to set its routing up and
become unreachable. Not good. Even if 'equalize' doesn't do what's expected,
it at least works to the extent that the routes are created.

The most I think could be done is make ip(8) print a warning when equalize
is used. This will, however, still annoy a lot of people because it'll cause
normally silent scripts to suddenly spew warnings.

Andras

-- 
 Andras Korn 
  QOTD:
  The Moon is covered with the results of astronomical odds.



-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]



Bug#149897: The bug you reported about ip route ... equalize ...

2007-12-29 Thread Andreas Henriksson
retitle 149897 equalize kernel patch not available for current kernels?
thanks

On lör, 2007-12-29 at 13:22 +0100, Andreas Henriksson wrote:
> Very good to hear this has resolved itself. The only thing that remains
> is the false statement in the documentation about having to patch the
> kernel. Lets treat this report as a bug against the documentation from
> now on. I'll try to dig some and see if I can find it which kernel
> version the support first appeared.

It seems like the required patch[1] which implements the feature is only
available for 2.4.18. As far as I can tell it only /looks/ like it works
with current kernels, because the kernel has the RTM_F_EQUALIZE flag
(but no actual implementation). The flag has been there since atleast
2.4.0.

man 7 rtnetlink says:
"RTM_F_EQUALIZE   a multicast equalizer (not yet implemented)"

grepping linux 2.6.22 source for RTM_F_EQUALIZE only gets a single hit,
the definition. It's not actually used anywhere.

./include/linux/rtnetlink.h:#define RTM_F_EQUALIZE  0x400   /* 
Multipath equalizer: NI  */

(I guess NI in the comment means "Not Implemented".)

I haven't found out why the patch hasn't been merged, but I did find
some discussion[2] between Guus Sliepen (original patch author?) and
Patrick McHardy which seems to mention some of the problems in it. One
of those might be the reason it never got merged in mainline.

So. Updating the documentation to state the fact that the required
kernel patch doesn't exist (for kernels supported by Debian) doesn't
seem very useful. Possibly the support for equalize in iproute should be
dropped completely since it's never been part of any official kernel
release, and since it hasn't been solved in all these years noone will
probably ever implement this. I'll ask upstream


[1] http://www.trash.net/~kaber/equalize/
[2] http://www.ussg.iu.edu/hypermail/linux/kernel/0203.2/1314.html


-- 
Regards,
Andreas Henriksson





Bug#149897: The bug you reported about ip route ... equalize ...

2007-12-29 Thread Andreas Henriksson
retitle 149897 documentation: no need to patch kernel for equalize.
tag 149897 =
severity wishlist
thanks


Hello Andras!

Thank you very much for getting back to me on this!

On lör, 2007-12-29 at 12:41 +0100, Andras Korn wrote:
> On Tue, Dec 25, 2007 at 02:08:16AM +0100, Andreas Henriksson wrote:
> 
> > I tried to reproduce the problem but when I tried to add a route with
> > "equalize" I got "Invalid argument".
> > The ip manpage told me "equalize only works if the kernel is patched."
> 
> What kernel version is that? I can add this route to a vanilla kernel (OK,
> it has the vserver patch but that doesn't really touch multipath routing).

I guess I must have done something else wrong. I tested this on Debian
Unstable with the regular packaged linux 2.6.22-3-amd64, but if I follow
the example you gave below it works for me too.

[...]
> If I then ifconfig dummy0 up again, the dead half of the route comes back.
> So I'd say this works as expected now.
[...]

Very good to hear this has resolved itself. The only thing that remains
is the false statement in the documentation about having to patch the
kernel. Lets treat this report as a bug against the documentation from
now on. I'll try to dig some and see if I can find it which kernel
version the support first appeared.


-- 
Regards,
Andreas Henriksson