ip route 0 & metric?

Discussion in 'Cisco' started by Christoph Gartmann, Mar 14, 2007.

  1. Hello,

    will the following two statements work?
    ip route 0.0.0.0 0.0.0.0 1.2.3.4 10
    ip route 0.0.0.0 0.0.0.0 5.6.7.8 128
    The idea is to have a normal default route to 1.2.3.4 but in case the interface
    is down use 5.6.7.8 as a default route. The router accepts both commands. But
    a "sho ip route" doesn't list the second default route.

    Regards,
    Christoph Gartmann

    --
    Max-Planck-Institut fuer Phone : +49-761-5108-464 Fax: -452
    Immunbiologie
    Postfach 1169 Internet: gartmann@immunbio dot mpg dot de
    D-79011 Freiburg, Germany
    http://www.immunbio.mpg.de/home/menue.html
    Christoph Gartmann, Mar 14, 2007
    #1
    1. Advertising

  2. Christoph Gartmann

    Trendkill Guest

    On Mar 14, 8:07 am, (Christoph
    Gartmann) wrote:
    > Hello,
    >
    > will the following two statements work?
    > ip route 0.0.0.0 0.0.0.0 1.2.3.4 10
    > ip route 0.0.0.0 0.0.0.0 5.6.7.8 128
    > The idea is to have a normal default route to 1.2.3.4 but in case the interface
    > is down use 5.6.7.8 as a default route. The router accepts both commands. But
    > a "sho ip route" doesn't list the second default route.
    >
    > Regards,
    > Christoph Gartmann
    >
    > --
    > Max-Planck-Institut fuer Phone : +49-761-5108-464 Fax: -452
    > Immunbiologie
    > Postfach 1169 Internet: gartmann@immunbio dot mpg dot de
    > D-79011 Freiburg, Germany
    > http://www.immunbio.mpg.de/home/menue.html


    How will the first route ever 'go down'? The ip route command doesn't
    inherently know anything about interface status if you have a next hop
    IP, so the second route will never be used. You need to use a ip
    route 0.0.0.0 ethernet1 and ip route 0.0.0.0 ethernet2 200 or
    something like that. Then it should work if an interface fails. The
    problem with that solution starts if the interface is up, but there is
    another problem. For example, if this is a dsl internet connection,
    it is very likely that ethernet1 will be up but the DSL router could
    be hosed.

    This may help:
    http://www.macroscape.com/pdf/isp_ha.pdf
    Trendkill, Mar 14, 2007
    #2
    1. Advertising

  3. On 14.03.2007 13:07 Christoph Gartmann wrote

    > Hello,
    >
    > will the following two statements work?
    > ip route 0.0.0.0 0.0.0.0 1.2.3.4 10
    > ip route 0.0.0.0 0.0.0.0 5.6.7.8 128
    > The idea is to have a normal default route to 1.2.3.4 but in case the interface
    > is down use 5.6.7.8 as a default route. The router accepts both commands. But
    > a "sho ip route" doesn't list the second default route.
    >


    That's ok, isn't it? AS long as 1.2.3.4 is up and working default route
    is to that gateway. Only when 1.2.3.4 fails the 2nd route should kick in.

    If both routes were shown, you would have *two* active default routes. I
    guess that's not what you want.

    Did you test what happens if you unplug 1.2.3.4?



    Arnold
    --
    AN45
    Arnold Nipper, Mar 14, 2007
    #3
  4. In article <>, "Trendkill" <> writes:
    >On Mar 14, 8:07 am, (Christoph
    >Gartmann) wrote:
    >> Hello,
    >>
    >> will the following two statements work?
    >> ip route 0.0.0.0 0.0.0.0 1.2.3.4 10
    >> ip route 0.0.0.0 0.0.0.0 5.6.7.8 128
    >> The idea is to have a normal default route to 1.2.3.4 but in case the interface
    >> is down use 5.6.7.8 as a default route. The router accepts both commands. But
    >> a "sho ip route" doesn't list the second default route.

    >
    >How will the first route ever 'go down'?


    The local router has an interface with an ip address of 1.2.3.3 connected via
    a direct link to 1.2.3.4. So there is a static route for the first default
    route as long as the interface is up. I assume that the route will disappear
    as soon as the cable from the interface is unplugged.

    Regards,
    Christoph Gartmann

    --
    Max-Planck-Institut fuer Phone : +49-761-5108-464 Fax: -452
    Immunbiologie
    Postfach 1169 Internet: gartmann@immunbio dot mpg dot de
    D-79011 Freiburg, Germany
    http://www.immunbio.mpg.de/home/menue.html
    Christoph Gartmann, Mar 14, 2007
    #4
  5. In article <>, Arnold Nipper <> writes:
    >On 14.03.2007 13:07 Christoph Gartmann wrote
    >
    >> Hello,
    >>
    >> will the following two statements work?
    >> ip route 0.0.0.0 0.0.0.0 1.2.3.4 10
    >> ip route 0.0.0.0 0.0.0.0 5.6.7.8 128
    >> The idea is to have a normal default route to 1.2.3.4 but in case the interface
    >> is down use 5.6.7.8 as a default route. The router accepts both commands. But
    >> a "sho ip route" doesn't list the second default route.
    >>

    >
    >That's ok, isn't it? AS long as 1.2.3.4 is up and working default route
    >is to that gateway. Only when 1.2.3.4 fails the 2nd route should kick in.
    >
    >If both routes were shown, you would have *two* active default routes. I
    >guess that's not what you want.
    >
    >Did you test what happens if you unplug 1.2.3.4?


    No, not yet. The thing is in use. That's why I am asking before.

    Regards,
    Christoph Gartmann

    --
    Max-Planck-Institut fuer Phone : +49-761-5108-464 Fax: -452
    Immunbiologie
    Postfach 1169 Internet: gartmann@immunbio dot mpg dot de
    D-79011 Freiburg, Germany
    http://www.immunbio.mpg.de/home/menue.html
    Christoph Gartmann, Mar 14, 2007
    #5
  6. Christoph Gartmann

    Trendkill Guest

    On Mar 14, 10:09 am, (Christoph
    Gartmann) wrote:
    > In article <>, Arnold Nipper <> writes:
    > >On 14.03.2007 13:07 Christoph Gartmann wrote

    >
    > >> Hello,

    >
    > >> will the following two statements work?
    > >> ip route 0.0.0.0 0.0.0.0 1.2.3.4 10
    > >> ip route 0.0.0.0 0.0.0.0 5.6.7.8 128
    > >> The idea is to have a normal default route to 1.2.3.4 but in case the interface
    > >> is down use 5.6.7.8 as a default route. The router accepts both commands. But
    > >> a "sho ip route" doesn't list the second default route.

    >
    > >That's ok, isn't it? AS long as 1.2.3.4 is up and working default route
    > >is to that gateway. Only when 1.2.3.4 fails the 2nd route should kick in.

    >
    > >If both routes were shown, you would have *two* active default routes. I
    > >guess that's not what you want.

    >
    > >Did you test what happens if you unplug 1.2.3.4?

    >
    > No, not yet. The thing is in use. That's why I am asking before.
    >
    > Regards,
    > Christoph Gartmann
    >
    > --
    > Max-Planck-Institut fuer Phone : +49-761-5108-464 Fax: -452
    > Immunbiologie
    > Postfach 1169 Internet: gartmann@immunbio dot mpg dot de
    > D-79011 Freiburg, Germany
    > http://www.immunbio.mpg.de/home/menue.html


    Again, you need to put a next hop interface instead of an address or
    your router will never equate the interface being down with the next
    hop IP being unavailable.
    Trendkill, Mar 14, 2007
    #6
  7. Trendkill wrote:

    >Again, you need to put a next hop interface instead of an address or
    >your router will never equate the interface being down with the next
    >hop IP being unavailable.


    But how will a packet ever reach the next hop if the mentioned interface is
    not a point-to-point link?

    fw
    Frank Winkler, Mar 14, 2007
    #7
  8. Christoph Gartmann

    Trendkill Guest

    On Mar 14, 10:20 am, Frank Winkler <>
    wrote:
    > Trendkill wrote:
    >
    > >Again, you need to put a next hop interface instead of an address or
    > >your router will never equate the interface being down with the next
    > >hop IP being unavailable.

    >
    > But how will a packet ever reach the next hop if the mentioned interface is
    > not a point-to-point link?
    >
    > fw


    He said its a direct connection..............just going off of the
    information I have.
    Trendkill, Mar 14, 2007
    #8
  9. Trendkill wrote:

    >He said its a direct connection..............just going off of the
    >information I have.


    You're right, sorry. But your statement would have also applied if this
    wasn't the case (you made it before the OP mentioned the direct link) or
    did I get that wrong?

    Regards

    fw
    Frank Winkler, Mar 14, 2007
    #9
  10. Christoph Gartmann

    Trendkill Guest

    On Mar 14, 10:33 am, Frank Winkler <>
    wrote:
    > Trendkill wrote:
    >
    > >He said its a direct connection..............just going off of the
    > >information I have.

    >
    > You're right, sorry. But your statement would have also applied if this
    > wasn't the case (you made it before the OP mentioned the direct link) or
    > did I get that wrong?
    >
    > Regards
    >
    > fw


    I made the assumption that this is a dual internet connection and that
    is the purpose...so yes you are correct, although my assumption would
    still put me in the clear. If this is not a direct connection and is
    not for two internet links, then you need to turn up a routing
    protocol because the solution he suggests will not work.
    As much as text doesn't convey it, I do appreciate the check &
    balance. :)

    I don't remember the name of the concept, but there is also a way to
    turn up policy-based routing based on the results of a ping test.
    Aka, if the first next-hop router is up, forward traffic there, else
    forward to next hop router 2. I'll see what I can find but this would
    work as well presuming there is something you can ping. It still
    doesn't negate problems associated with hung dsl routers...but I
    haven't officially heard that is the case or not.
    Trendkill, Mar 14, 2007
    #10
  11. In article <>, "Trendkill" <> writes:
    >On Mar 14, 10:33 am, Frank Winkler <>
    >wrote:
    >> Trendkill wrote:
    >>
    >> >He said its a direct connection..............just going off of the
    >> >information I have.

    >>
    >> You're right, sorry. But your statement would have also applied if this
    >> wasn't the case (you made it before the OP mentioned the direct link) or
    >> did I get that wrong?
    >>
    >> Regards
    >>
    >> fw

    >
    >I made the assumption that this is a dual internet connection and that
    >is the purpose...so yes you are correct, although my assumption would
    >still put me in the clear. If this is not a direct connection and is
    >not for two internet links, then you need to turn up a routing
    >protocol because the solution he suggests will not work.


    It is a direct connection for both ways.

    >As much as text doesn't convey it, I do appreciate the check &
    >balance. :)
    >
    >I don't remember the name of the concept, but there is also a way to
    >turn up policy-based routing based on the results of a ping test.
    >Aka, if the first next-hop router is up, forward traffic there, else
    >forward to next hop router 2. I'll see what I can find but this would
    >work as well presuming there is something you can ping. It still
    >doesn't negate problems associated with hung dsl routers...but I
    >haven't officially heard that is the case or not.


    It is nothing with DSL, both connections are single-mode fiber.

    Regards,
    Christoph Gartmann


    --
    Max-Planck-Institut fuer Phone : +49-761-5108-464 Fax: -452
    Immunbiologie
    Postfach 1169 Internet: gartmann@immunbio dot mpg dot de
    D-79011 Freiburg, Germany
    http://www.immunbio.mpg.de/home/menue.html
    Christoph Gartmann, Mar 14, 2007
    #11
  12. On 14.03.2007 17:04 Christoph Gartmann wrote

    >
    > It is nothing with DSL, both connections are single-mode fiber.
    >


    Single-mode fibre really does not mean too much ;-) Why don't you tell
    us how your setup us. Or do you want us to do a quiz?





    Arnold
    Arnold Nipper, Mar 14, 2007
    #12
  13. Christoph Gartmann

    Trendkill Guest

    On Mar 14, 1:59 pm, Arnold Nipper <> wrote:
    > On 14.03.2007 17:04 Christoph Gartmann wrote
    >
    >
    >
    > > It is nothing with DSL, both connections are single-mode fiber.

    >
    > Single-mode fibre really does not mean too much ;-) Why don't you tell
    > us how your setup us. Or do you want us to do a quiz?
    >
    > Arnold


    If these are not point to point links, you need to run a routing
    protocol to get the gateway to failover properly. The configuration
    you have proposed will not failover as the router does not equate an
    interface going down as taking away the first default route, because
    you have specified a next hop IP address and not an interface. If
    this was point to point, you can do a <ip route 0.0.0.0 fe0/1> and <ip
    route 0.0.0.0 fe0/2 200> or something like that, that will do what you
    expect. Else turn up the default routes on the next hops and
    advertise them via a routing protocol.
    Trendkill, Mar 14, 2007
    #13
  14. On 14.03.2007 20:08 Trendkill wrote

    > On Mar 14, 1:59 pm, Arnold Nipper <> wrote:
    >> On 14.03.2007 17:04 Christoph Gartmann wrote
    >>
    >>
    >>
    >> > It is nothing with DSL, both connections are single-mode fiber.

    >>
    >> Single-mode fibre really does not mean too much ;-) Why don't you tell
    >> us how your setup us. Or do you want us to do a quiz?
    >>
    >> Arnold

    >
    > If these are not point to point links, you need to run a routing
    > protocol to get the gateway to failover properly. The configuration
    > you have proposed will not failover as the router does not equate an
    > interface going down as taking away the first default route, because
    > you have specified a next hop IP address and not an interface. If
    > this was point to point, you can do a <ip route 0.0.0.0 fe0/1> and <ip
    > route 0.0.0.0 fe0/2 200> or something like that, that will do what you
    > expect. Else turn up the default routes on the next hops and
    > advertise them via a routing protocol.
    >


    well even with ethernet imho this should work as after some time 1.2.3.4
    will be unreachable.




    Arnold
    Arnold Nipper, Mar 14, 2007
    #14
  15. In article <>,
    Frank Winkler <> wrote:

    > Trendkill wrote:
    >
    > >He said its a direct connection..............just going off of the
    > >information I have.

    >
    > You're right, sorry. But your statement would have also applied if this
    > wasn't the case (you made it before the OP mentioned the direct link) or
    > did I get that wrong?


    If it's not a direct connection, the scheme of having two static routes
    with different metrics won't work at all, because the primary route will
    never go away when the interface goes down.

    --
    Barry Margolin,
    Arlington, MA
    *** PLEASE post questions in newsgroups, not directly to me ***
    *** PLEASE don't copy me on replies, I'll read them in the group ***
    Barry Margolin, Mar 15, 2007
    #15
  16. Christoph Gartmann

    Trendkill Guest

    On Mar 14, 9:12 pm, Barry Margolin <> wrote:
    > In article <>,
    > Frank Winkler <> wrote:
    >
    > > Trendkill wrote:

    >
    > > >He said its a direct connection..............just going off of the
    > > >information I have.

    >
    > > You're right, sorry. But your statement would have also applied if this
    > > wasn't the case (you made it before the OP mentioned the direct link) or
    > > did I get that wrong?

    >
    > If it's not a direct connection, the scheme of having two static routes
    > with different metrics won't work at all, because the primary route will
    > never go away when the interface goes down.
    >
    > --
    > Barry Margolin,
    > Arlington, MA
    > *** PLEASE post questions in newsgroups, not directly to me ***
    > *** PLEASE don't copy me on replies, I'll read them in the group ***


    Agreed. The posted originally said its a direct point to point
    link...but then said it was fiber. He needs to turn up routing.
    Trendkill, Mar 15, 2007
    #16
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Ben Low
    Replies:
    2
    Views:
    7,659
    Ben Low
    Dec 28, 2003
  2. Daniel Eyholzer

    Backup route with better eigrp metric

    Daniel Eyholzer, Dec 3, 2004, in forum: Cisco
    Replies:
    3
    Views:
    5,267
    Hansang Bae
    Dec 6, 2004
  3. Daniel Eyholzer

    explicitly set metric for one static route

    Daniel Eyholzer, Dec 6, 2004, in forum: Cisco
    Replies:
    10
    Views:
    23,346
    Bob by the Bay
    Dec 8, 2004
  4. phil41
    Replies:
    11
    Views:
    13,480
    Thomas Sulkiewicz
    Feb 23, 2010
  5. pvarulkumar
    Replies:
    0
    Views:
    927
    pvarulkumar
    Oct 14, 2008
Loading...

Share This Page