Router PEB
router bgp 4837
no synchronization
bgp log-neighbor-changes
neighbor 1.1.1.2 remote-as 4837
neighbor 1.1.1.2 update-source Loopback0
no auto-summary
!
address-family vpnv4
neighbor 1.1.1.2 activate
neighbor 1.1.1.2 send-community extended
exit-address-family
!
address-family ipv4 vrf vpn-b
neighbor 172.16.5.6 remote-as 65004
neighbor 172.16.5.6 activate
no synchronization
network 172.16.5.4 mask 255.255.255.252
exit-address-family
!
address-family ipv4 vrf vpn-a
neighbor 172.16.4.2 remote-as 65002
neighbor 172.16.4.2 activate
no synchronization
network 172.16.4.0 mask 255.255.255.0
exit-address-family
!
2、配置CE路由器
Router CED
!
interface Loopback0
ip address 192.168.100.1 255.255.255.0
!
interface Serial1/0
ip address 172.16.5.6 255.255.255.252
!
router bgp 65004
bgp log-neighbor-changes
neighbor 172.16.5.5 remote-as 4837
!
address-family ipv4
neighbor 172.16.5.5 activate
no auto-summary
no synchronization
network 192.168.100.0
exit-address-family
!
Router CEC
!
interface Loopback0
ip address 192.168.10.1 255.255.255.0
!
interface Serial1/1
ip address 172.16.5.2 255.255.255.252
!
router bgp 65003
bgp log-neighbor-changes
neighbor 172.16.5.1 remote-as 4837
!
address-family ipv4
neighbor 172.16.5.1 activate
no auto-summary
no synchronization
network 192.168.10.0
exit-address-family
!
Router CEA
!
interface Loopback0
ip address 10.10.0.1 255.255.0.0
!
interface Serial1/1
ip address 172.16.3.2 255.255.255.0
!
router bgp 65001
no synchronization
bgp log-neighbor-changes
network 10.10.0.0 mask 255.255.0.0
neighbor 172.16.3.1 remote-as 4837
no auto-summary
!
Router CEB
!
interface Loopback0
ip address 10.20.0.1 255.255.0.0
!