netdev
[Top] [All Lists]

Re: static routes and dead gateway detection

To: kuznet@xxxxxxxxxxxxx
Subject: Re: static routes and dead gateway detection
From: Julian Anastasov <ja@xxxxxx>
Date: Wed, 25 Jul 2001 20:52:31 +0300 (EEST)
Cc: netdev@xxxxxxxxxxx
In-reply-to: <200107251718.VAA08166@xxxxxxxxxxxxx>
Sender: owner-netdev@xxxxxxxxxxx
        Hello Alexey,

On Wed, 25 Jul 2001 kuznet@xxxxxxxxxxxxx wrote:

> Hello!
>
> >     Hm, I can't understand this trick. fib_flush always follows
> > fib_sync_down (where the DEAD flag is correctly set). But fib_flush
> > makes its decisions based on the same flag (fn_flush_list).
>
> We mark only nexthop as dead, the route itself is not marked dead.
> Currently this is used only for multipath, but it is easy to change,
> allowing routes without alive hops, if they are marked
> with proto static.

        Aha, you want:

- fib_sync_down not to set DEAD in fib_flags on dev down for
RTPROT_STATIC (change required)

- fib_semantic_match currently checks nh_flags for DEAD (no change here)

- fn_flush_list will flush only routes with DEAD flag set in
fib_flags (no change here)

- undef fib_sync_up, i.e. use it for single-path routes too

- Do we need changes in fn_hash_select_default? check for all nh_flags&DEAD ?
Like in my patch but now fib_flags&DEAD is not enough?

(sorry that I don't have test setup, the tested devices are in production)

> Note, I am ready to recommend patch doing this for 2.4 just because
> it is the best tool to fix bug, noticed by you earlier. And that bug
> is vaery bad, showstopper in fact...
>
>
> >     I understand, I only note that similar trick works for
> > ip rules :)
>
> Yes, policy rules are bound to names, like firewall rules.
> This is bad, but unavoidable, because no automatic systems to establish
> policy exist and it is even not clear how should it work, taking
> into account that "policy" in presence of dynamically changing picture
> is mostly impossible, so that using names remains the only way:
> bad, unreliable, but better than all the rest.
> As soon as such one is invented, using names becomes bug.
> Routes passed through this stage long ago, before linux appeared. :-)

        I understand ...

> Alexey


Regards

--
Julian Anastasov <ja@xxxxxx>


<Prev in Thread] Current Thread [Next in Thread>