explicitly set metric for one static route

Discussion in 'Cisco' started by Daniel Eyholzer, Dec 6, 2004.

  1. Hi there


    How can I explicitly set the metric for one static route? I want one static
    route to get distributed by eigrp with a very high metric. There are other
    static routes on this router that should not be influenced.


    Thanks, Daniel
    Daniel Eyholzer, Dec 6, 2004
    #1
    1. Advertising

  2. Daniel Eyholzer

    Ivan Ostreš Guest

    In article <>,
    says...
    > Hi there
    >
    >
    > How can I explicitly set the metric for one static route? I want one static
    > route to get distributed by eigrp with a very high metric. There are other
    > static routes on this router that should not be influenced.
    >


    It is easy to do this using route-map in 'redistribute static' under
    eigrp routing protocol config. In mentioned route-map you can explicitly
    add metric that will route have when redistributed in routing protocols.

    There are some good examples on www.cisco.com.

    --
    -Ivan.

    *** Use Rot13 to see my eMail address ***
    Ivan Ostreš, Dec 6, 2004
    #2
    1. Advertising

  3. Ivan Ostreš <> wrote:
    > It is easy to do this using route-map in 'redistribute static' under
    > eigrp routing protocol config. In mentioned route-map you can explicitly
    > add metric that will route have when redistributed in routing protocols.


    I have tried to use route-map, but it does not work. I think I have
    missconfigured something.

    My configuration:
    !
    router eigrp 1
    redistribute connected
    redistribute static route-map myroute
    network 192.168.131.0
    network 192.168.134.0
    no auto-summary
    no eigrp log-neighbor-changes
    !
    ip route 192.168.139.48 255.255.255.248 Serial1
    !
    access-list 25 permit 192.168.139.48 0.0.0.7
    !
    route-map myroute permit 10
    match ip address 25
    set metric +1000000
    !
    route-map myroute permit 15
    !

    The route is distributet with the same metric like without the route-map.
    Any idea what is wrong in my configuration?


    Thanks, Daniel
    Daniel Eyholzer, Dec 6, 2004
    #3
  4. I believe the SET METRIC route-map subcommand is exclusively for BGP.

    However, you can use DEFAULT-METRIC under your EIGRP routing process or add
    the METRIC parameter onto the REDISTRIBUTE STATIC command.

    In either case, the metric is in the form bandwidth, delay, reliability,
    load, MTU.

    FWIW,
    Robert


    "Daniel Eyholzer" <> wrote in message
    news:...
    Ivan Ostres <> wrote:
    > It is easy to do this using route-map in 'redistribute static' under
    > eigrp routing protocol config. In mentioned route-map you can explicitly
    > add metric that will route have when redistributed in routing protocols.


    I have tried to use route-map, but it does not work. I think I have
    missconfigured something.

    My configuration:
    !
    router eigrp 1
    redistribute connected
    redistribute static route-map myroute
    network 192.168.131.0
    network 192.168.134.0
    no auto-summary
    no eigrp log-neighbor-changes
    !
    ip route 192.168.139.48 255.255.255.248 Serial1
    !
    access-list 25 permit 192.168.139.48 0.0.0.7
    !
    route-map myroute permit 10
    match ip address 25
    set metric +1000000
    !
    route-map myroute permit 15
    !

    The route is distributet with the same metric like without the route-map.
    Any idea what is wrong in my configuration?


    Thanks, Daniel
    Bob by the Bay, Dec 6, 2004
    #4
  5. "Bob by the Bay" <> wrote:
    > However, you can use DEFAULT-METRIC under your EIGRP routing process
    > or add the METRIC parameter onto the REDISTRIBUTE STATIC command.


    Then all static routes will have this same metric, or have I missed
    something? But what I want to do, is just to change the metric of one
    static route, not of all.


    Daniel
    Daniel Eyholzer, Dec 6, 2004
    #5
  6. OK, that clarifies things.

    I was mistaken that the SET METRIC route-map command is only for BGP. But
    it does work rather selectively. It works well with OSPF for instance doing
    exactly what you are trying to do. However I don't believe it works with
    EIGRP although it may have originally worked with IGRP.

    For instance, it doesn't appear to work at all when I try redistributing
    OSPF into EIGRP - exactly where it should work if it were going to work.

    But in case I'm running into a bug with my version of IOS, you might try the
    full compound metric per the example below:

    route-map mymap per 10
    match address 10
    set metric 1000000 250 200 100 1500

    FWIW,
    Robert

    "Daniel Eyholzer" <> wrote in message
    news:...
    > "Bob by the Bay" <> wrote:
    >> However, you can use DEFAULT-METRIC under your EIGRP routing process
    >> or add the METRIC parameter onto the REDISTRIBUTE STATIC command.

    >
    > Then all static routes will have this same metric, or have I missed
    > something? But what I want to do, is just to change the metric of one
    > static route, not of all.
    >
    >
    > Daniel
    Bob by the Bay, Dec 6, 2004
    #6
  7. It looks like EIGRP route-map support may not be fully functional until
    12.3(8)T.

    see
    http://www.cisco.com/en/US/products..._feature_guide09186a0080220721.html#wp1027265

    "Daniel Eyholzer" <> wrote in message
    news:...
    > "Bob by the Bay" <> wrote:
    >> However, you can use DEFAULT-METRIC under your EIGRP routing process
    >> or add the METRIC parameter onto the REDISTRIBUTE STATIC command.

    >
    > Then all static routes will have this same metric, or have I missed
    > something? But what I want to do, is just to change the metric of one
    > static route, not of all.
    >
    >
    > Daniel
    Bob by the Bay, Dec 6, 2004
    #7
  8. actually route-map support was enhanced for EIGRP in 12.3(8)T but even in
    this document, it states that the SET METRIC command is only supported for
    OSPF, BGP and RIP.

    see
    http://www.cisco.com/en/US/products/sw/iosswrel/ps5207/products_feature_guide09186a0080220721.html

    and find "set metric"

    "Daniel Eyholzer" <> wrote in message
    news:...
    > "Bob by the Bay" <> wrote:
    >> However, you can use DEFAULT-METRIC under your EIGRP routing process
    >> or add the METRIC parameter onto the REDISTRIBUTE STATIC command.

    >
    > Then all static routes will have this same metric, or have I missed
    > something? But what I want to do, is just to change the metric of one
    > static route, not of all.
    >
    >
    > Daniel
    Bob by the Bay, Dec 6, 2004
    #8
  9. "Bob by the Bay" <> wrote:
    > But in case I'm running into a bug with my version of IOS, you might try
    > the full compound metric per the example below:
    >
    > route-map mymap per 10
    > match address 10
    > set metric 1000000 250 200 100 1500


    Thanks Robert! Doing it this way it seems to work.


    Daniel
    Daniel Eyholzer, Dec 7, 2004
    #9
  10. Daniel Eyholzer

    Ben Guest

    Bob by the Bay wrote:
    > actually route-map support was enhanced for EIGRP in 12.3(8)T but even in
    > this document, it states that the SET METRIC command is only supported for
    > OSPF, BGP and RIP.
    >
    > see
    > http://www.cisco.com/en/US/products/sw/iosswrel/ps5207/products_feature_guide09186a0080220721.html
    >
    > and find "set metric"
    >
    > "Daniel Eyholzer" <> wrote in message
    > news:...
    >
    >>"Bob by the Bay" <> wrote:
    >>
    >>>However, you can use DEFAULT-METRIC under your EIGRP routing process
    >>>or add the METRIC parameter onto the REDISTRIBUTE STATIC command.

    >>
    >>Then all static routes will have this same metric, or have I missed
    >>something? But what I want to do, is just to change the metric of one
    >>static route, not of all.
    >>
    >>
    >>Daniel

    >
    >
    >

    FYI, the recommended method is to use the optional 'tag' switch on the
    static route and then match that in a route-map.
    Ben, Dec 8, 2004
    #10
  11. Ben,

    Excellent point as that method makes a more efficient match than matching
    for an ip address in an access-list.

    One of the problems encountered though was the assignment of the EIGRP
    metric using the SET METRIC route-map command, which doesn't appear to be
    supported for EIGRP in at least some IOS revisions as late as 12.2. If that
    SET METRIC command isn't available for EIGRP, then granularity of the metric
    assignment is greatly reduced.

    Robert

    "Ben" <> wrote in message news:...
    > Bob by the Bay wrote:
    >> actually route-map support was enhanced for EIGRP in 12.3(8)T but even in
    >> this document, it states that the SET METRIC command is only supported
    >> for OSPF, BGP and RIP.
    >>
    >> see
    >> http://www.cisco.com/en/US/products/sw/iosswrel/ps5207/products_feature_guide09186a0080220721.html
    >>
    >> and find "set metric"
    >>
    >> "Daniel Eyholzer" <> wrote in message
    >> news:...
    >>
    >>>"Bob by the Bay" <> wrote:
    >>>
    >>>>However, you can use DEFAULT-METRIC under your EIGRP routing process
    >>>>or add the METRIC parameter onto the REDISTRIBUTE STATIC command.
    >>>
    >>>Then all static routes will have this same metric, or have I missed
    >>>something? But what I want to do, is just to change the metric of one
    >>>static route, not of all.
    >>>
    >>>
    >>>Daniel

    >>
    >>
    >>

    > FYI, the recommended method is to use the optional 'tag' switch on the
    > static route and then match that in a route-map.
    Bob by the Bay, Dec 8, 2004
    #11
    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,695
    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,307
    Hansang Bae
    Dec 6, 2004
  3. Replies:
    9
    Views:
    4,878
    Scott Perry
    Aug 7, 2008
  4. Giuen
    Replies:
    0
    Views:
    725
    Giuen
    Sep 12, 2008
  5. pvarulkumar
    Replies:
    0
    Views:
    969
    pvarulkumar
    Oct 14, 2008
Loading...

Share This Page