1,目的:为了了解BGP的概念
2,搭建环境: Cisco Packet Tracer 6.0
3,拓扑图:
4,拓扑解释
1), 上述拓扑使用1841路由器.
2),R1,R2,R3,R4各有两个百兆网卡(f0/0 f0/1)并宣告了一个lo0;
Router # lo0 f0/0 f0/1 R1 10.1.1.1/24 NA 10.1.12.1/24 R2 10.1.2.2/24 10.1.12.2/24 10.1.23.2/24 R3 10.1.3.3/24 10.1.23.3/24 10.1.34.3/24 R4 10.1.4.4/24 10.1.34.4/24 NA
3),将R2,R3,R4设定为eigrp100 R4 是可以ping到R2的
4)在R1 和 R2上分别设置BGP 并指定 as 然后在R2是可以ping到10.1.1.1,但是R3ping不到101.1.1
5,配置指令
R1:
hostname R1
interface Loopback0
ip address 10.1.1.1 255.255.255.0
interface FastEthernet0/1
ip address 10.1.12.1 255.255.255.0
no shut
router bgp 1
neighbor 10.1.12.2 remote-as 234
network 10.1.1.0 mask 255.255.255.0
R2:
hostname R2
interface Loopback0
ip address 10.1.2.2 255.255.255.0
interface FastEthernet0/0
ip address 10.1.12.2 255.255.255.0
interface FastEthernet0/1
ip address 10.1.23.2 255.255.255.0
no shut
router eigrp 100
network 10.1.2.0 0.0.0.255
network 10.1.23.0 0.0.0.255
router bgp 234
neighbor 10.1.12.1 remote-as 1
network 10.1.2.0 mask 255.255.255.0
R3:
hostname R3
interface Loopback0
ip address 10.1.3.3 255.255.255.0
interface FastEthernet0/0
ip address 10.1.23.3 255.255.255.0
interface FastEthernet0/1
ip address 10.1.34.3 255.255.255.0
no shut
router eigrp 100
network 10.1.3.0 0.0.0.255
network 10.1.23.0 0.0.0.255
network 10.1.34.0 0.0.0.255
R4:
hostname R4
interface Loopback0
ip address 10.1.4.4 255.255.255.0
interface FastEthernet0/0
ip address 10.1.34.4 255.255.255.0
no shut
router eigrp 100
network 10.1.4.0 0.0.0.255
network 10.1.34.0 0.0.0.255