NBMA实验

NBMA实验:

NBMA实验_第1张图片

NBMA实验_第2张图片

NBMA实验_第3张图片

NBMA实验步骤:

一、配置地址

R4(config)#int s2/0

R4(config-if)#ip add 192.168.1.1 255.255.255.0

R4(config-if)#no shu

R4(config-if)#int l 1

R4(config-if)#ip add 172.16.1.1 255.255.255.0

 

R1(config)#int s2/0

R1(config-if)#ip add 192.168.1.2 255.255.255.0

R1(config-if)#no shu

R1(config)#int s2/1

R1(config-if)#ip add 15.1.1.1 255.255.255.0

R1(config-if)#no shu

 

R5(config)#int s2/0

R5(config-if)#ip add 15.1.1.2 255.255.255.0

R5(config-if)#no shu

R5(config)#int s2/1

R5(config-if)#ip add 25.1.1.2 255.255.255.0

R5(config-if)#no shu

R5(config)#int s2/2

R5(config-if)#ip add 35.1.1.2 255.255.255.0

R5(config-if)#no shu

R5(config)#int l 1

R5(config-if)#ip add 5.5.5.5 255.255.255.0

 

R2(config)#int s2/1

R2(config-if)#ip add 25.1.1.1 255.255.255.0

R2(config-if)#no shu

R2(config)#int l 1

R2(config-if)#ip add 192.168.2.1 255.255.255.0

 

R3(config)#int s2/1

R3(config-if)#ip add 35.1.1.1 255.255.255.0

R3(config-if)#no shu

R3(config)#int l 1

R3(config-if)#ip add 192.168.3.1 255.255.255.0

 

二、缺省路由

R1(config)#ip route 0.0.0.0 0.0.0.0 15.1.1.2

R2(config)#ip route 0.0.0.0 0.0.0.0 25.1.1.2

R3(config)#ip route 0.0.0.0 0.0.0.0 35.1.1.2

R3(config)#do ping 15.1.1.2

R3(config)#do ping 25.1.1.2

(公网环境通)

 

三、配置隧道

R1(config)#int tunnel 0

R1(config-if)#ip add 10.1.1.1 255.255.255.0

R1(config-if)#tunnel source 15.1.1.1

R1(config-if)#tunnel mode gre multipoint

R1(config-if)#ip nhrp map multicast dynamic

R1(config-if)#ip nhrp network-id 100

 

R2(config)#int tunnel 0

R2(config-if)#ip add 10.1.1.2 255.255.255.0

R2(config-if)#tunnel source s2/1

R2(config-if)#tunnel mode gre multipoint

R2(config-if)#ip nhrp nhs 10.1.1.1

R2(config-if)#ip nhrp map 10.1.1.1 15.1.1.1

R2(config-if)#ip nhrp network-id 100

 

R3(config)#int t 0

R3(config-if)#ip add 10.1.1.3 255.255.255.0

R3(config-if)#tunnel source s2/1

R3(config-if)#tunnel mode gre multipoint

R3(config-if)#ip nhrp nhs 10.1.1.1

R3(config-if)#ip nhrp map 10.1.1.1 15.1.1.1

R3(config-if)#ip nhrp network-id 100

R3(config-if)#do ping 10.1.1.1(隧道成功)

 

四、配置eigrp进行通信

R1(config)#router ei 90

R1(config-router)#no au

R1(config-router)#network 192.168.1.0

R1(config-router)#network 10.0.0.0 

 

R2(config)#router ei 90

R2(config-router)#no au

R2(config-router)#net 192.168.2.0

R2(config-router)#net 10.0.0.0

 

R3(config)#router ei 90

R3(config-router)#no au

R3(config-router)#net 192.168.3.0

R3(config-router)#net 10.0.0.0

 

开启伪广播

R2(config-if)#int t 0

R2(config-if)#ip nh map mu 15.1.1.1

 

R3(config)#int tunnel 0

R3(config-if)#ip nhrp map multicast 15.1.1.1

 

R1邻居过来了

R1(config-router)#do show ip ei ne

IP-EIGRP neighbors for process 90

H   Address                 Interface       Hold Uptime   SRTT   RTO  Q  Seq

                                            (sec)         (ms)       Cnt Num

1   10.1.1.3                Tu0               14 00:00:50   67  1434  0  9

0   10.1.1.2                Tu0               12 00:02:07  674  4044  0  9

 

在隧道口关闭R1的水平分割

R1(config)#int tunnel 0

R1(config-if)#no ip sp

R1(config-if)#no ip split-horizon eigrp 90

 

在R2和R3 show 路由都正常了

R2(config-if)#do sho ip route

     25.0.0.0/24 is subnetted, 1 subnets

C       25.1.1.0 is directly connected, Serial2/1

     10.0.0.0/24 is subnetted, 1 subnets

C       10.1.1.0 is directly connected, Tunnel0

D    192.168.1.0/24 [90/27392000] via 10.1.1.1, 00:06:39, Tunnel0

C    192.168.2.0/24 is directly connected, Loopback1

D    192.168.3.0/24 [90/28288000] via 10.1.1.1, 00:00:43, Tunnel0

S*   0.0.0.0/0 [1/0] via 25.1.1.2

 

测试

R2(config-if)#do ping 192.168.1.2

R2(config-if)#do ping 192.168.3.1

R3(config)#do ping 192.168.1.2

 

R4(config)#router ei 90

R4(config-router)#no au

R4(config-router)#net 192.168.1.0

R4(config-router)#net 172.16.0.0

R4(config-router)#do ping 192.168.2.1

R4(config-router)#do ping 192.168.3.1

 

R4(config-router)#do sho ip route

     172.16.0.0/24 is subnetted, 1 subnets

C       172.16.1.0 is directly connected, Loopback1

     10.0.0.0/24 is subnetted, 1 subnets

D       10.1.1.0 [90/27392000] via 192.168.1.2, 00:03:15, Serial2/0

C    192.168.1.0/24 is directly connected, Serial2/0

D    192.168.2.0/24 [90/27520000] via 192.168.1.2, 00:03:15, Serial2/0

D    192.168.3.0/24 [90/27520000] via 192.168.1.2, 00:03:15, Serial2/0

 

到目前为止,整个网络跑了EIGRP,R4和R1是正常的EIGRP,而R1-3和中间的运营商R5用隧道跑EIGRP

私网环境通了

 

五、配置NAT

R1(config)#access-list 1 permit 192.168.1.0 0.0.0.255

R1(config)#access-list 1 permit 172.16.0.0 0.0.255.255

R1(config)#ip nat inside source list 1 interface s2/1

R1(config)#int s2/1

R1(config-if)#ip nat outside

R1(config-if)#int s2/1

R1(config-if)#ip nat inside

 

R1下发缺省

R1(config)#int s2/0

R1(config-if)#ip summary-address eigrp 90 0.0.0.0 0.0.0.0

 

R4#ping 5.5.5.5

R4#sho ip route

     172.16.0.0/24 is subnetted, 1 subnets

C       172.16.1.0 is directly connected, Loopback1

C    192.168.1.0/24 is directly connected, Serial2/0

D*   0.0.0.0/0 [90/2681856] via 192.168.1.2, 00:03:25, Serial2/0

 

或者:

R1(config)#router ei 90

R1(config-router)#redistribute static

 

六、chap 认证

R5(config)#int s2/0

R5(config-if)#encapsulation ppp

R5(config-if)#ppp authentication chap

 

R1(config)#int s2/1

R1(config-if)#encapsulation ppp

R1(config-if)#ppp chap hostname cuncun 

R1(config-if)#ppp chap password liuchunyu

 

R5(config)#username cuncun password liuchunyu

你可能感兴趣的:(NBMA实验)