beautypg.com

Configuring vpn instances – H3C Technologies H3C S12500-X Series Switches User Manual

Page 166

background image

155

[PE1] bgp 100

[PE1-bgp] ip vpn-instance vpn1

[PE1-bgp-vpn1] peer 10.1.1.1 as-number 65001

[PE1-bgp-vpn1] address-family ipv4 unicast

[PE1-bgp-ipv4-vpn1] peer 10.1.1.1 enable

[PE1-bgp-ipv4-vpn1] import-route direct

[PE1-bgp-ipv4-vpn1] quit

[PE1-bgp-vpn1] quit

[PE1-bgp] quit

# Configure CE 2.

[CE2] bgp 65002

[CE2-bgp] peer 10.2.1.2 as-number 200

[CE2-bgp] address-family ipv4 unicast

[CE2-bgp-ipv4] peer 10.2.1.2 enable

[CE2-bgp-ipv4] import-route direct

[CE2-bgp-ipv4] quit

[CE2-bgp] quit

# Configure PE 2.

[PE2] bgp 200

[PE2-bgp] ip vpn-instance vpn1

[PE2-bgp-vpn1] peer 10.2.1.1 as-number 65002

[PE2-bgp-vpn1] address-family ipv4 unicast

[PE2-bgp-ipv4-vpn1] peer 10.2.1.1 enable

[PE2-bgp-ipv4-vpn1] import-route direct

[PE2-bgp-ipv4-vpn1] quit

[PE2-bgp-vpn1] quit

[PE2-bgp] quit

5.

Establish an MP-IBGP peer relationship between each PE and the ASBR-PE in the same AS, and an
EBGP peer relationship between the ASBR-PEs:
# Configure PE 1.

[PE1] bgp 100

[PE1-bgp] peer 2.2.2.9 as-number 100

[PE1-bgp] peer 2.2.2.9 connect-interface loopback 0

[PE1-bgp] address-family vpnv4

[PE1-bgp-vpnv4] peer 2.2.2.9 enable

[PE1-bgp-vpnv4] peer 2.2.2.9 next-hop-local

[PE1-bgp-vpnv4] quit

[PE1-bgp] quit

# Configure ASBR-PE 1.

[ASBR-PE1] bgp 100

[ASBR-PE1-bgp] ip vpn-instance vpn1

[ASBR-PE1-bgp-vpn1] peer 192.1.1.2 as-number 200

[ASBR-PE2-bgp-vpn1] address-family ipv4 unicast

[ASBR-PE2-bgp-ipv4-vpn1] peer 192.1.1.2 enable

[ASBR-PE2-bgp-ipv4-vpn1] quit

[ASBR-PE1-bgp-vpn1] quit

[ASBR-PE1-bgp] peer 1.1.1.9 as-number 100