Description

This article provides information on how to export the EBGP routes that were learnt from remote peer via one VRF and advertise back to same peer on another VRF .

Symptoms

 

Topology :

 

SRX / SRX CLUSTER [ Virtual router RT1 ] [AS 12345 ] reth3.28 ————EBGP PEERING ———- MX [VRF-A ] [AS 11111 ] ae11.28

                                            < ----------- PREFIX A ---------- 

 

SRX / SRX CLUSTER [ Virtual router RT1 ] [AS 12345 ] reth3.143 ————EBGP PEERING ———- MX [VRF-B ] [AS 11111 ] ae11.143

                                            ----------- PREFIX A ---------- > 

 

 

  • The route is learned from MX VRF-A to the SRX Virtual router RT1 .

 

  • The same route is exported back to MX on differetn VRF i,e VRF-B

 

  • By default, MX will not accept the routes that are advertised by SRX , if it contains the same AS 1111 in the AS path.

 

  • This is the default behavior to prevent any kind of internal looping in the network.

Solution

On SRX Without using an as-override keyword, SRX advertises the route; but MX does not installs it. 

SRX configuration and outputs : 

{primary:node0}[edit routing-instances RT1 protocols bgp group GROUP1]

root@SRX# show

type external;

local-address 10.26.55.44;

Import GROUP1-V4-in;

export GROUP1-V4-out;

peer-as 11111;

local-as 12345;

multipath;

as-override;

neighbor 10.26.55.42 {

  bfd-liveness-detection {

    minimum-interval 300;

    multiplier 3;

  }

}

       

{primary:node0}[edit routing-instances RT1 protocols bgp group GROUP2 ]

root@SRX# show

type external;

local-address 10.24.94.64;

Import GROUP2-V4-in;

export GROUP2-V4-out;

peer-as 11111;

local-as 12345;

multipath;

as-override; <<<<<<<<<<<< This is required when exporting prefix back to MX 

neighbor 10.24.94.62 {

  bfd-liveness-detection {

    minimum-interval 1000;

    multiplier 6;

  }

}
 

 

policy-statement GROUP2-V4-out {

        term V4-ALLOW-SUBNETS {

            from {

                protocol bgp;

                prefix-list V4-SUBNETS;

            }

            then accept;

        }

        term REJECT {

            then reject;

        }

    }

 

prefix-list V4-SUBNETS {

        10.24.99.0/24;

}

 

root@SRX> show route protocol bgp table RT1.inet 10.24.99.0

 

RT1.inet.0: 202 destinations, 387 routes (202 active, 0 holddown, 0 hidden)

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

 

10.24.99.0/24  *[BGP/170] 46w6d 15:14:26, localpref 100, from 10.26.255.42

           AS path: 11111 I, validation-state: unverified

          > to 10.26.55.42 via reth3.28


root@SRX> show route advertising-protocol bgp 10.24.94.62

RT1.inet.0: 20 destinations, 38 routes (20 active, 0 holddown, 0 hidden)
  Prefix                  Nexthop              MED     Lclpref    AS path
* 10.24.99.0/24         Self                                    12345 I
 

MX configuration and outputs : 

 

root@MX> show configuration routing-instances VRF-A protocols bgp

group groupB {

  type external;

  local-address 10.26.55.42;

  import V4-VRFA-BGP-IN;

  export V4-VRFA-BGP-OUT;

  peer-as 12345;

  bfd-liveness-detection {

    minimum-interval 300;

    multiplier 3;

  }

  neighbor 10.26.55.44;

}

 

root@MX> show configuration routing-instances VRF-B protocols bgp

group groupB {

  type external;

  local-address 10.24.94.62;

  import V4-VRFB-BGP-IN;

  export V4-VRFB-BGP-OUT;

  peer-as 12345;

  bfd-liveness-detection {

    minimum-interval 1000;

    multiplier 6;

  }

  neighbor 10.24.94.64;

}




 

root@MX> show route 10.24.99.0/24 table VRF-B.inet

 

VRF-B.inet.0: 25 destinations, 50 routes (25 active, 0 holddown, 5 hidden)

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

 

10.24.99.0/24  *[BGP/170] 00:01:27, localpref 170

           AS path: 12345 12345 I, validation-state: unverified

          > to 10.24.94.64 via ae11.143

 

 

root@MX> show route advertising-protocol bgp 10.26.55.44 table VRF-A.inet

 

VRF-A.inet.0: 50 destinations, 70 routes (52 active, 0 holddown, 0 hidden)

 Prefix         Nexthop       MED  Lclpref  AS path

@ 10.24.96.0/24                Self                  I

@ 10.24.97.0/24             Self                  I

@ 10.24.99.0/24             Self                  I

 

root@MX> show route receive-protocol bgp 10.24.94.64 table VRF-B.inet

 

VRF-B.inet.0: 25 destinations, 30 routes (25 active, 0 holddown, 5 hidden)

  Prefix                  Nexthop              MED     Lclpref    AS path

* 10.24.99.0/24         10.24.94.64                         12345 12345 I

Modification History

V2