日韩性视频-久久久蜜桃-www中文字幕-在线中文字幕av-亚洲欧美一区二区三区四区-撸久久-香蕉视频一区-久久无码精品丰满人妻-国产高潮av-激情福利社-日韩av网址大全-国产精品久久999-日本五十路在线-性欧美在线-久久99精品波多结衣一区-男女午夜免费视频-黑人极品ⅴideos精品欧美棵-人人妻人人澡人人爽精品欧美一区-日韩一区在线看-欧美a级在线免费观看

歡迎訪問 生活随笔!

生活随笔

當前位置: 首頁 > 编程资源 > 编程问答 >内容正文

编程问答

路由器VRF多个虚拟路由器测试

發布時間:2023/12/20 编程问答 28 豆豆
生活随笔 收集整理的這篇文章主要介紹了 路由器VRF多个虚拟路由器测试 小編覺得挺不錯的,現在分享給大家,幫大家做個參考.

一.測試拓撲:
??
參考鏈接:
A.Configuring VRF Tables-思科MPLS教程
http://www.doc88.com/p-085712708378.html
B.如何利用VRF在單臺路由器上創建多份路由表
http://net.zdnet.com.cn/files/all-2081627.htm
C.在Cisco路由器上配置VRF-aware IPsec VPN
http://networking.ctocio.com.cn/76/12336576.shtml
二.基本配置:
A.SW1:
①創建VLAN
vlan database?
vlan 11
vlan 12
?exit
②接口劃入VLAN
interface FastEthernet0/1
?switch mode access
?switchport access vlan 11
?no shut
interface FastEthernet0/2
?switch mode access
?switchport access vlan 12
?no shut
③trunk接口配置
interface FastEthernet0/0
?sw trunk encapsulation dot1q?
?switchport mode trunk
?no shut
B.R1:
①創建VRF
ip vrf vd01
?rd 1:1
ip vrf vd02
?rd 2:2
②劃分子接口,并將子接口劃分到vrf中
---處于不同vrf的子接口IP可以相同
interface FastEthernet0/0
?no shut
interface FastEthernet0/0.11
?encapsulation dot1Q 11
?ip vrf forwarding vd01
?ip address 10.1.1.1 255.255.255.0
interface FastEthernet0/0.12
?encapsulation dot1Q 12
?ip vrf forwarding vd02
?ip address 10.1.1.1 255.255.255.0
interface FastEthernet1/0
?no shut
interface FastEthernet1/0.21
?encapsulation dot1Q 21
?ip vrf forwarding vd01
?ip address 202.100.1.1 255.255.255.0
interface FastEthernet1/0.22
?encapsulation dot1Q 22
?ip vrf forwarding vd02
?ip address 202.100.1.1 255.255.255.0
③測試:
1.路由器能ping通VRF的接口地址
R1#ping vrf vd01 10.1.1.1

Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 10.1.1.1, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 1/3/4 ms
R1#
R1#ping vrf vd02 10.1.1.1

Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 10.1.1.1, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 1/2/4 ms
R1#
R1#ping vrf vd01 202.100.1.1

Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 202.100.1.1, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 1/2/4 ms
R1#ping vrf vd02 202.100.1.1

Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 202.100.1.1, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 1/3/4 ms
R1#
2.兩個VPC配置相同的地址,都能ping通路由器的子接口地址
?
C.R2:
①創建VRF
ip vrf vd01
?rd 1:1
ip vrf vd02
?rd 2:2
②劃分子接口,并將子接口劃分到vrf中
---處于不同vrf的子接口IP可以相同
interface FastEthernet0/0
?no shut
interface FastEthernet0/0.11
?encapsulation dot1Q 11
?ip vrf forwarding vd01
?ip address 20.1.1.1 255.255.255.0
interface FastEthernet0/0.12
?encapsulation dot1Q 12
?ip vrf forwarding vd02
?ip address 20.1.1.1 255.255.255.0
interface FastEthernet1/0
?no shut
interface FastEthernet1/0.21
?encapsulation dot1Q 21
?ip vrf forwarding vd01
?ip address 202.100.1.2 255.255.255.0
interface FastEthernet1/0.22
?encapsulation dot1Q 22
?ip vrf forwarding vd02
?ip address 202.100.1.2 255.255.255.0
③測試:
R2#ping vrf vd01 202.100.1.1

Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 202.100.1.1, timeout is 2 seconds:
.!!!!
Success rate is 80 percent (4/5), round-trip min/avg/max = 20/42/80 ms
R2#ping vrf vd02 202.100.1.1

Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 202.100.1.1, timeout is 2 seconds:
.!!!!
Success rate is 80 percent (4/5), round-trip min/avg/max = 36/53/80 ms
R2#
---R2能ping通R2的相連的子接口地址
D.SW2:
①創建VLAN
vlan database?
vlan 11
vlan 12
?exit
②接口劃入VLAN
interface FastEthernet0/1
?switch mode access
?switchport access vlan 11
?no shut
interface FastEthernet0/2
?switch mode access
?switchport access vlan 12
?no shut
③trunk接口配置
interface FastEthernet0/0
?sw trunk encapsulation dot1q?
?switchport mode trunk
?no shut
④測試:
VPC3和VPC4配置相同ip地址能ping通路由器的子接口地址
?
三.VRF靜態路由配置:
A.R1:
ip route vrf vd01 20.1.1.0 255.255.255.0 202.100.1.2
ip route vrf vd02 20.1.1.0 255.255.255.0 202.100.1.2
B.R2:
ip route vrf vd01 10.1.1.0 255.255.255.0 202.100.1.1
ip route vrf vd02 10.1.1.0 255.255.255.0 202.100.1.1
四.效果測試:
VPC1能ping通VPC3,VPC2能ping通VPC4




本文轉自 碧云天 51CTO博客,原文鏈接:http://blog.51cto.com/333234/1107107,如需轉載請自行聯系原作者

總結

以上是生活随笔為你收集整理的路由器VRF多个虚拟路由器测试的全部內容,希望文章能夠幫你解決所遇到的問題。

如果覺得生活随笔網站內容還不錯,歡迎將生活随笔推薦給好友。