Path: utzoo!utgpu!jarvis.csri.toronto.edu!rutgers!tut.cis.ohio-state.edu!ucbvax!proteon.com!jnc From: jnc@proteon.com (J. Noel Chiappa) Newsgroups: comp.protocols.tcp-ip Subject: Re: [RAF%NIHCU.BITNET@CUNYVM.CUNY.EDU: Routing with redundant connections] Message-ID: <8905170240.AA09555@monk.proteon.com> Date: 17 May 89 02:40:16 GMT Sender: daemon@ucbvax.BERKELEY.EDU Organization: The Internet Lines: 46 This is a bit of a tricky subject. The specs as written say that a Redirect is only sent when the next hop is on the same net, not if there is a 'better' first hop. To make your case even more plain, assume that network A is something high speed like an FDDI backbone, so that it makes sense for the preferred path from Router 1 to Router 2 to be network A. RFC-1009 states that: "A gateway will generate an ICMP Redirect if and only if ... the next-hop gateway is on the same (sub-)network as the source host." The ICMP RFC (RFC 792) says more or less the same thing: "If [the next-hop gateway] and the [source host] are on the same network, a Redirect message is sent". However, the real intent of the Redirect was to handle cases "when the gateway can direct the host to send traffic on a shorter route", to use the RFC-792 language. As I recall (and my memory of this is dim, since it was 10 years ago now that we did ICMP :-), the algorithm specified above was added to provide a concrete example of what to do. It was definitely pointed out at the time that cases like the one you pointed out existed, but I don't think we were trying to outlaw that. One problem was that all the existing 'gateways' at that time had routing tables which couldn't *tell* you things like 'Oh, even though some other gateway is the best next hop for you, and on a different net, there's this gateway on the source host's net that would be a better first hop for it'. The case you listed is fairly simple, but suppose your Router 2 is actually several routers, one connected to network B, one connected tot he serial link to the destination, and one connected to A, connected in a row by links of various kinds. It might be legit for 1's best route to C to be over network A. Fixing this kind of thing in general for Vector Distance algorithms have required a separate routing table be kept per interface, using only routing info coming in through that interface. Doing it in Link State algorithms is also some work; you basically have to calculate separate trees with each attached network as the source node, and see if the first hop to a given destination is through you or not. Also, one nice thing about the way the spec is currently done is that it's cheap to do the Redirect test; you only need to check more thoroughly those packets which are being sent out the same interface they came in on, which should happen rarely and be fast to do. However, the next revision of the Router RFC might want to state that you can provide a Redirect to a host on the same net as the router if the best first hop for the final destination is not this router but another one on the same net, and give the more restrictive wording as the default algorithm. Noel