291
Configure BGP AS number substitution:
# Configure BGP AS number substitution on PE 1, PE 2, and PE 3. For more information about
the configuration, see "
818H
Configuring BGP AS number substitution
."
# Display routing information on CE 2. The output shows that CE 2 has learned the route for
100.1.1.1/32 from CE 1. A routing loop has occurred because CE1 and CE 2 reside in the same
site.
<CE2> display bgp routing-table ipv4 peer 10.2.1.2 received-routes
Total number of routes: 6
BGP local router ID is 1.1.1.9
Status codes: * - valid, > - best, d - dampened, h - history,
s - suppressed, S - stale, i - internal, e - external
Origin: i - IGP, e - EGP, ? - incomplete
Network NextHop MED LocPrf PrefVal Path/Ogn
* >e 10.1.1.0/24 10.2.1.2 0 100?
* 10.2.1.0/24 10.2.1.2 0 0 100?
* 10.2.1.1/32 10.2.1.2 0 0 100?
* >e 10.3.1.0/24 10.2.1.2 0 100?
* >e 100.1.1.1/32 10.2.1.2 0 100 100?
* >e 200.1.1.1/32 10.2.1.2 0 100 100?
3.
Configure BGP SoO attribute:
# On PE 1, configure the SoO attribute as 1:100 for CE 1.
<PE1> system-view
[PE1] bgp 100
[PE1-bgp-default] ip vpn-instance vpn1
[PE1-bgp-default-vpn1] address-family ipv4
[PE1-bgp-default-ipv4-vpn1] peer 10.1.1.1 soo 1:100
# On PE 2, configure the SoO attribute as 1:100 for CE 2.
<PE2> system-view
[PE2] bgp 100
[PE2-bgp-default] ip vpn-instance vpn1
[PE2-bgp-default-vpn1] address-family ipv4
[PE2-bgp-default-ipv4-vpn1] peer 10.2.1.1 soo 1:100
509B
Verifying the configuration
# PE 2 does not advertise routes received from CE 1 to CE 2 because the same SoO attribute has
been configured for the CEs. Display the routing table of CE 2. The output shows that the route
100.1.1.1/32 has been removed.
<CE2> display ip routing-table
Destinations : 14 Routes : 14
Destination/Mask Proto Pre Cost NextHop Interface
0.0.0.0/32 Direct 0 0 127.0.0.1 InLoop0
10.2.1.0/24 Direct 0 0 10.2.1.1 Vlan2
10.2.1.0/32 Direct 0 0 10.2.1.1 Vlan2