Routing

last person joined: 2 days ago 

Ask questions and share experiences about ACX Series, CTP Series, MX Series, PTX Series, SSR Series, JRR Series, and all things routing, including portfolios and protocols.
Expand all | Collapse all

Export default gateways RIP, OSPF

  • 1.  Export default gateways RIP, OSPF

    Posted 06-06-2011 08:06

    Hi all,

     

    I would like to know how to configured a RIP to export as a default gateway 0.0.0.0/0 and how to do with OSPF too.

     

     

    Rtoribio@SABAJUNIPER# show policy-options policy-statement RIP

    term 1 {    from protocol [ rip static direct ];   

    then accept;

    }

    Rtoribio@SABAJUNIPER# show protocols rip group PROPAGACION_RIP

    export RIP;

    neighbor fxp0.0;

     

     

    Local route:

                        

    Rtoribio@SABAJUNIPER> show route table inet.0

     

    inet.0: 9 destinations, 10 routes (9 active, 0 holddown, 0 hidden)

    + = Active Route, - = Last Active, * = Both


     0.0.0.0/0          *[Static/250] 00:00:32                   

    > to 10.0.0.2 via fxp0.0

    10.0.0.0/24        *[Direct/0] 4d 18:59:22

                        > via fxp0.0

    10.0.0.1/32        *[Local/0] 4d 19:03:44

                          Local via fxp0.0

    10.5.0.0/24        *[RIP/100] 2d 17:49:45, metric 2, tag 0

                        > to 10.0.0.2 via fxp0.0

    172.22.0.0/16      *[Static/250] 2d 18:01:23

                        > to 172.22.16.1 via fxp1.0

    172.22.16.0/24     *[Direct/0] 2d 20:17:46

                        > via fxp1.0

                        [Static/250] 2d 18:59:14

                        > to 172.22.16.1 via fxp1.0

    172.22.16.160/32   *[Local/0] 2d 20:18:14

                          Local via fxp1.0

    195.168.1.0/24     *[RIP/100] 2d 17:46:18, metric 3, tag 0

                        > to 10.0.0.2 via fxp0.0

    200.10.25.0/24     *[Static/250] 2d 23:16:07

                        > to 10.0.0.2 via fxp0.0

    224.0.0.9/32       *[RIP/100] 2d 18:01:23, metric 1

      MultiRecv

     

     

    at the router it can not see, the default last resort.

     

    LAB_TOC_R2#

     

    Gateway of last resort is not set ( is not set ???)

     

         172.22.0.0/16 is variably subnetted, 2 subnets, 2 masks

    R       172.22.16.0/24 [120/1] via 10.0.0.1, 00:00:09, FastEthernet0/0

    R       172.22.0.0/16 [120/1] via 10.0.0.1, 00:00:09, FastEthernet0/0

         10.0.0.0/24 is subnetted, 2 subnets

    C       10.0.0.0 is directly connected, FastEthernet0/0

    C       10.5.0.0 is directly connected, FastEthernet0/1

    R    195.168.1.0/24 [120/1] via 10.5.0.2, 00:00:22, FastEthernet0/1

     

    Regards,

    Raul Toribio



  • 2.  RE: Export default gateways RIP, OSPF

     
    Posted 06-06-2011 08:38
    Hi Raul,

    Can you please provide output of "show route 0/0 exact detail" on the local router from where you are trying to advertise this default?

    Regards
    Surya Prakash


  • 3.  RE: Export default gateways RIP, OSPF

    Posted 06-06-2011 08:49

    Hi surya,

     

    I want to advertised (juniper) 0.0.0.0/0 via fxp0 (next-hop 10.0.0.2) in the other router (cisco) it couldnt get default router.

     

     

    Rtoribio@SABAJUNIPER# show routing-options static

    defaults {

        readvertise;

        preference 250;

    }

    route 200.10.25.0/24 next-hop 10.0.0.2;

    route 172.22.16.0/24 {

        next-hop 172.22.16.1;

        passive;

    }

    route 172.22.0.0/16 {

        next-hop 172.22.16.1;

        passive;

    }

    route 0.0.0.0/0 next-hop 10.0.0.2;

     


    Rtoribio@SABAJUNIPER# run show route 0.0.0.0

     

    inet.0: 10 destinations, 11 routes (10 active, 0 holddown, 0 hidden)

    + = Active Route, - = Last Active, * = Both

     

    0.0.0.0/0          *[Static/250] 00:49:09

                        > to 10.0.0.2 via fxp0.0

     

     

    Regards,

    RT



  • 4.  RE: Export default gateways RIP, OSPF

     
    Posted 06-06-2011 09:07
    Hi Raul,

    I just wanted to confirm if the route state is in "no-advertise" mode, however from the configs it doesn't seem to be the case.

    To confirm what the router is advertising to other router, we may need "show route advertising-protocol rip <neighbor_ip> detail".

    Regards
    Surya Prakash


  • 5.  RE: Export default gateways RIP, OSPF

    Posted 06-06-2011 09:16

    Hi Surya,

     

    is clear went i showed with the next-hop 10.0.0.2

     

    [edit]

    Rtoribio@SABAJUNIPER# ...ing-protocol rip 10.0.0.2 detail

     

    [edit]

    Rtoribio@SABAJUNIPER# ...ing-protocol rip 10.0.0.2 detail

     

    with the local-ip 10.0.0.1 is

     

    [edit]

    Rtoribio@SABAJUNIPER# run show route advertising-protocol rip 10.0.0.1

     

    inet.0: 10 destinations, 11 routes (10 active, 0 holddown, 0 hidden)

    + =Active Route, - = Last Active, * = Both

     

    0.0.0.0/0          *[Static/250]01:13:47

                        > to 10.0.0.2 via fxp0.0

    172.22.0.0/16      *[Static/250] 2d19:28:29

                        > to 172.22.16.1 via fxp1.0

    172.22.16.0/24     *[Direct/0] 2d21:44:52

                        > via fxp1.0

                        [Static/250] 2d20:26:20

                        > to 172.22.16.1 via fxp1.0

    200.10.25.0/24     *[Static/250] 3d00:43:13

                        > to 10.0.0.2 via fxp0.0

     

    Regards,

    RT



  • 6.  RE: Export default gateways RIP, OSPF

     
    Posted 06-06-2011 09:25
    Hi Raul.

    My bad, actually the show command should had "local_ip" instead of "neighbor_ip".

    From this output, it is clear that juniper router is advertising default route 0/0 to the adjacent router.

    Regards
    Surya Prakash


  • 7.  RE: Export default gateways RIP, OSPF

    Posted 06-06-2011 11:22

    the other router (cisco) should had (accepted) the default router (on last resort) but isnt there. what i configured bad on my juniper-advertising?? if my advertising 0/0 to next-hop is ok, why i can not see it.

     

     

    LAB_TOC_R2#sho ip ro

    Codes: C - connected, S - static, R - RIP, M - mobile, B - BGP

           D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area

           N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2

           E1 - OSPF external type 1, E2 - OSPF external type 2

           i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area

           * - candidate default, U - per-user static route, o - ODR

           P - periodic downloaded static route

     

    Gateway of last resort is not set

     

         172.22.0.0/16 is variably subnetted, 2 subnets, 2 masks

    R       172.22.16.0/24 [120/1] via 10.0.0.1, 00:00:03, FastEthernet0/0

    R       172.22.0.0/16 [120/1] via 10.0.0.1, 00:00:03, FastEthernet0/0

         10.0.0.0/24 is subnetted, 2 subnets

    C       10.0.0.0 is directly connected, FastEthernet0/0

    C       10.5.0.0 is directly connected, FastEthernet0/1

    R    195.168.1.0/24 [120/1] via 10.5.0.2, 00:00:24, FastEthernet0/1

     

    LAB_TOC_R2#

     

    Regards,

    RT



  • 8.  RE: Export default gateways RIP, OSPF

    Posted 06-06-2011 13:59

    Your default route is pointing out of the fxp0.0 interface.  The fxp0.0 is a nontransitive interface, aka not in the forwarding path.  Even if the route is recieved it will be unuseable. 

     

    I'm a bit rusty on IOS, but you should be able to debug rip and see why the route is being rejected by the cisco router.



  • 9.  RE: Export default gateways RIP, OSPF

    Posted 06-06-2011 18:18

    i run the monitor traffic, and i recieved/send, could be related with?

     

    0.9.router: RIPv2, Response, length: 104

    21:06:04.251289 Out IP truncated-ip - 72 bytes missing! 10.0.0.1.router > 224.0.

    0.9.router: RIPv2, Response, length: 104

    21:06:06.719326  In

    21:06:16.719013  In

    21:06:26.499587  In IP truncated-ip - 12 bytes missing! 10.0.0.2.router > 224.0.

    0.9.router: RIPv2, Response, length: 44

    21:06:26.718712  In

    21:06:32.762727 Out IP truncated-ip - 72 bytes missing! 10.0.0.1.router > 224.0.

    0.9.router: RIPv2, Response, length: 104

    21:06:36.726270  In

    21:06:36.727325  In 0:d:ed:61:49:50 > 1:0:c:cc:cc:cc SNAP Unnumbered, ui, Flags

    [Command], length 60

    21:06:46.722216  In

    21:06:53.435771  In IP truncated-ip - 12 bytes missing! 10.0.0.2.router > 224.0.

    0.9.router: RIPv2, Response, length: 44

    21:06:56.721955  In

    21:07:01.789154 Out IP truncated-ip - 72 bytes missing! 10.0.0.1.router > 224.0.

     

    Regards,

    RT



  • 10.  RE: Export default gateways RIP, OSPF
    Best Answer

    Posted 06-06-2011 18:39

    We know that the Juniper is sending the route.  What we don't know is why the cisco is not processing/accepting the route.  We will need to run debug for RIP on the IOS device.

     

    I'm begining to think you may have a weird split-horizon problem - the debug will tell.  The next hop for the 0/0 route is 10.0.0.2.  The Cisco router knows about the 10.0.0.0/24 network - "C       10.0.0.0 is directly connected, FastEthernet0/0" - as directly connected.

     

    Again, debug will tell.  I'm pretty sure if you change the 0/0 route on the Juniper to have a next-hop of discard (for testing purposes), the Cisco will recieve the default route properly.  This would confirm my split-horizon suspisions (which can be confirmed by a cisco IOS debug).



  • 11.  RE: Export default gateways RIP, OSPF

    Posted 06-06-2011 19:06

    Hi Jwparks,

     

    i thougth at the begin, firts am gonna try to change with a next-hop dircard and then with a different Net between

    Juniper-----Cisco#1Cisco#1-------Cisco#2

    Network: 10.0.0.0/24Network: 10.5.0.0/24(they are different)

    10.0.0.1-----10.0.0.2 10.5.0.1--------10.5.0.2

     

    i tryed to debug ip rip, but my cisco router can't return anything.

     

    Regards,



  • 12.  RE: Export default gateways RIP, OSPF

    Posted 06-06-2011 19:28

    Hi Jwparks,

     

    Thank you,

    you were rigth, when i changed to discard, my ciscos could accept  a default route. even exist a split horizon it should accept the default however the packet can not go out on that interface.

     

    LAB_TOC_R1#sho ip ro

     

    Codes: C - connected, S - static, R - RIP, M - mobile, B - BGP

           D - EIGRP, EX - EIGRP external, O -OSPF,IA - OSPF inter area

           N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2

           E1 - OSPF external type 1, E2 - OSPF external type 2

           i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area

           * - candidate default, U - per-user static route, o - ODR

           P - periodic downloaded static route

     

    Gateway of last resort is 10.5.0.1 to network 0.0.0.0

     

         172.22.0.0/16 is variably subnetted, 2 subnets, 2 masks

    R       172.22.16.0/24 [120/2] via 10.5.0.1,00:00:22, FastEthernet0/0

    R       172.22.0.0/16 [120/2] via 10.5.0.1,00:00:22, FastEthernet0/0

         10.0.0.0/24 is subnetted, 2 subnets

    R       10.0.0.0 [120/1] via 10.5.0.1,00:00:22, FastEthernet0/0

    C       10.5.0.0 is directly connected, FastEthernet0/0

    C    195.168.1.0/24 is directly connected, FastEthernet0/1

    R*   0.0.0.0/0 [120/2] via 10.5.0.1,00:00:22, FastEthernet0/0

     

    LAB_TOC_R1#

     

    LAB_TOC_R2#sho ip ro

    Codes: C - connected, S - static, R - RIP, M - mobile, B - BGP

           D - EIGRP, EX - EIGRP external, O -OSPF,IA - OSPF inter area

           N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2

           E1 - OSPF external type 1, E2 - OSPF external type 2

           i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area

           * - candidate default, U - per-user static route, o - ODR

           P - periodic downloaded static route

     

    Gateway of last resort is 10.0.0.1 to network 0.0.0.0

     

         172.22.0.0/16 is variably subnetted, 2 subnets, 2 masks

    R       172.22.16.0/24 [120/1] via 10.0.0.1,00:00:16, FastEthernet0/0

    R       172.22.0.0/16 [120/1] via 10.0.0.1,00:00:16, FastEthernet0/0

         10.0.0.0/24 is subnetted, 2 subnets

    C       10.0.0.0 is directly connected, FastEthernet0/0

    C       10.5.0.0 is directly connected, FastEthernet0/1

    R    195.168.1.0/24 [120/1] via 10.5.0.2,00:00:29, FastEthernet0/1

    R*   0.0.0.0/0 [120/1] via 10.0.0.1,00:00:16, FastEthernet0/0

     

    LAB_TOC_R2#



  • 13.  RE: Export default gateways RIP, OSPF

    Posted 06-06-2011 20:58

    It is wierd, but I think that was the problem.  You can try disabling split-horizon on the Cisco by adding something like "no ip split-horizon"** in the interface pointing at the Juniper.  See if that works.

     

    **not sure of the exact command



  • 14.  RE: Export default gateways RIP, OSPF

    Posted 06-06-2011 22:41

    but what should be the correct way, to changed the networks ?? because those router has not summarization advertisment: 10.0.0.0/24 is different to 10.5.0.0/24



  • 15.  RE: Export default gateways RIP, OSPF

     
    Posted 06-07-2011 07:00

    Hi,

        What I understand so far is that, you want to export a RIP default route to adjacent cisco router, so that Juniper Router can act as a default gateway. Is that correct?

    In that case, you can have define a aggregate route and advertise the same using RIP export policy.

    [edit]
    regress@huntington# show routing-options aggregate
    route 0.0.0.0/0;

    [edit]
    regress@huntington# show policy-options policy-statement rip-export
    term 1 {
        from {
            protocol aggregate;
            route-filter 0.0.0.0/0 exact;
        }
        then accept;
    }


    Regards
    Surya Prakash



  • 16.  RE: Export default gateways RIP, OSPF

    Posted 06-07-2011 10:48

    Hi Surya,

     

    That's correct. i want to export default route from my juniper router. that is other way to do it ?? could solve the suspicious split horinzon, now.