CCNP-第十七篇-VXLAN(三)
今天主要有点点复习的效果,这篇内容会偏少一点点 今天主要演示VXLAN环境下的跨子网的vxlan
跨子网的VXLAN
部署方式 1.集中式GW部署,意味着内网里面就一个大网关 ==本次演示 2.分布式GW部署,这里面会涉及到MPLS+BGP,不过很多IDC都用这种.
建立VTEP的过程后面这里这个protocol,适用于分布式的,可以看到后面直接只能跟着bgp了
本章VS上章
1.上一章的环境是相同VNI以及左右的PC是同网段的情况下
2.这一章的环境乃是不同VNI+不同BD(其实无所谓,反正只能本地有效)+不同网段
3.本次同样会把dis current-configuration 公布以及注解
那么,就展开PK啦
网络环境
网络环境如图所示 最终需求:左右PC互通
开始配置
1.首先底层都配置起来先,这个就不截图了,一会dis-cu自己看 2.ce12800设备有点问题,他接口改三层不能互联,要用vlan做才能互通 2.开始配置VLXLAN
CE2 如果觉得眼花缭乱的可以去下面直接看dis cu 我这个只是配置过程
CE3
看到这会有人说跟上一篇不是一样吗,不就换了个源和目的地,这么简单?
VXLAN确实不难,但是没这么简单,切往下看
上一篇的环境是同网段,但是这一章是不同的vni不同的网段
采用集中式网关,所以这里需要把nve隧道指向中间CORE,而不是对端,一会会解释.
做bd和vni的时候尽量用100以内的,100以外有点问题的.我这里全改了,但是拓扑图没改
直接贴配置然后再解释了,
CE1:[CE1]dis arp
ARP Entry Types: D - Dynamic, S - Static, I - Interface, O - OpenFlow
EXP: Expire-time VLAN:VLAN or Bridge Domain
IP ADDRESS MAC ADDRESS EXP(M) TYPE/VLAN INTERFACE VPN-INSTA
NCE
------------------------------------------------------------------------------
10.1.1.2 707b-e889-6853 I Vlanif1500
10.1.1.1 707b-e813-6a77 12 D/1500 GE1/0/0
20.1.1.2 707b-e889-6853 I Vlanif2500
20.1.1.1 707b-e8cd-6e15 15 D/2500 GE1/0/1
192.168.1.1 707b-e889-6853 I Vbdif10
192.168.1.10 5489-9882-30ca 11 D/BD10 2.2.2.2
192.168.2.1 707b-e889-6853 I Vbdif20
192.168.2.10 5489-9839-5423 11 D/BD20 3.3.3.3
------------------------------------------------------------------------------
Total:8 Dynamic:4 Static:0 Interface:4 OpenFlow:0
[CE1]dis ip rou
[CE1]dis ip routing-table
Proto: Protocol Pre: Preference
Route Flags: R - relay, D - download to fib, T - to vpn-instance, B - black hole
route
------------------------------------------------------------------------------
Routing Table : _public_
Destinations : 21 Routes : 21
Destination/Mask Proto Pre Cost Flags NextHop Interface
1.1.1.0/24 Direct 0 0 D 1.1.1.1 LoopBack0
1.1.1.1/32 Direct 0 0 D 127.0.0.1 LoopBack0
1.1.1.255/32 Direct 0 0 D 127.0.0.1 LoopBack0
2.2.2.2/32 OSPF 10 1 D 10.1.1.1 Vlanif1500
3.3.3.3/32 OSPF 10 1 D 20.1.1.1 Vlanif2500
10.1.1.0/24 Direct 0 0 D 10.1.1.2 Vlanif1500
10.1.1.2/32 Direct 0 0 D 127.0.0.1 Vlanif1500
10.1.1.255/32 Direct 0 0 D 127.0.0.1 Vlanif1500
20.1.1.0/24 Direct 0 0 D 20.1.1.2 Vlanif2500
20.1.1.2/32 Direct 0 0 D 127.0.0.1 Vlanif2500
20.1.1.255/32 Direct 0 0 D 127.0.0.1 Vlanif2500
127.0.0.0/8 Direct 0 0 D 127.0.0.1 InLoopBack0
127.0.0.1/32 Direct 0 0 D 127.0.0.1 InLoopBack0
127.255.255.255/32 Direct 0 0 D 127.0.0.1 InLoopBack0
192.168.1.0/24 Direct 0 0 D 192.168.1.1 Vbdif10
192.168.1.1/32 Direct 0 0 D 127.0.0.1 Vbdif10
192.168.1.255/32 Direct 0 0 D 127.0.0.1 Vbdif10
192.168.2.0/24 Direct 0 0 D 192.168.2.1 Vbdif20
192.168.2.1/32 Direct 0 0 D 127.0.0.1 Vbdif20
192.168.2.255/32 Direct 0 0 D 127.0.0.1 Vbdif20
255.255.255.255/32 Direct 0 0 D 127.0.0.1 InLoopBack0
[CE1]
[CE1]
[CE1]
[CE1]
[CE1]
[CE1]
[CE1]
[CE1]
[CE1]
[CE1]
[CE1]
[CE1]
[CE1]dis cu
[CE1]dis current-configuration
!Software Version V800R013C00SPC560B560
!Last configuration was updated at 2022-02-24 23:22:21+00:00
#
sysname CE1
#
device board 17 board-type CE-MPUB
device board 1 board-type CE-LPUE
#
vlan batch 1500 2500
#
bridge-domain 10
vxlan vni 10
#
bridge-domain 20
vxlan vni 20
#
vni 10
#
vni 20
#
aaa
#
authentication-scheme default
#
authorization-scheme default
#
accounting-scheme default
#
domain default
#
domain default_admin
#
interface Vbdif10
ip address 192.168.1.1 255.255.255.0
#
interface Vbdif20
ip address 192.168.2.1 255.255.255.0
#
interface Vlanif1500
ip address 10.1.1.2 255.255.255.0
#
interface Vlanif2500
ip address 20.1.1.2 255.255.255.0
#
interface MEth0/0/0
undo shutdown
#
interface GE1/0/0
undo shutdown
port default vlan 1500
#
interface GE1/0/1
undo shutdown
port default vlan 2500
#
interface GE1/0/2
shutdown
#
interface GE1/0/3
shutdown
#
interface GE1/0/4
shutdown
#
interface GE1/0/5
shutdown
#
interface GE1/0/6
shutdown
#
interface GE1/0/7
shutdown
#
interface GE1/0/8
shutdown
#
interface GE1/0/9
shutdown
#
interface LoopBack0
ip address 1.1.1.1 255.255.255.0
#
interface Nve1
source 1.1.1.1
vni 10 head-end peer-list 2.2.2.2
vni 20 head-end peer-list 3.3.3.3
#
interface NULL0
#
ospf 1 router-id 1.1.1.1
area 0.0.0.0
network 1.1.1.0 0.0.0.255
network 10.1.1.0 0.0.0.255
network 20.1.1.0 0.0.0.255
#
ssh authorization-type default aaa
#
user-interface con 0
#
vm-manager
#
return
[CE1]
[CE1]
[CE1]
CE2
[CE2]dis arp
ARP Entry Types: D - Dynamic, S - Static, I - Interface, O - OpenFlow
EXP: Expire-time VLAN:VLAN or Bridge Domain
IP ADDRESS MAC ADDRESS EXP(M) TYPE/VLAN INTERFACE VPN-INSTA
NCE
------------------------------------------------------------------------------
10.1.1.1 707b-e813-6a77 I Vlanif1500
10.1.1.2 707b-e889-6853 11 D/1500 GE1/0/1
------------------------------------------------------------------------------
Total:2 Dynamic:1 Static:0 Interface:1 OpenFlow:0
[CE2]dis cu
[CE2]dis current-configuration
!Software Version V800R013C00SPC560B560
!Last configuration was updated at 2022-02-24 23:20:57+00:00
#
sysname CE2
#
device board 17 board-type CE-MPUB
device board 1 board-type CE-LPUE
#
vlan batch 1500
#
bridge-domain 10
vxlan vni 10
#
vni 10
#
aaa
#
authentication-scheme default
#
authorization-scheme default
#
accounting-scheme default
#
domain default
#
domain default_admin
#
interface Vlanif1500
ip address 10.1.1.1 255.255.255.0
#
interface MEth0/0/0
undo shutdown
#
interface GE1/0/0
undo shutdown
#
interface GE1/0/0.1 mode l2
encapsulation dot1q vid 10
bridge-domain 10
#
interface GE1/0/1
undo shutdown
port default vlan 1500
#
interface GE1/0/2
shutdown
#
interface GE1/0/3
shutdown
#
interface GE1/0/4
shutdown
#
interface GE1/0/5
shutdown
#
interface GE1/0/6
shutdown
#
interface GE1/0/7
shutdown
#
interface GE1/0/8
shutdown
#
interface GE1/0/9
shutdown
#
interface LoopBack0
ip address 2.2.2.2 255.255.255.0
#
interface Nve1
source 2.2.2.2
vni 10 head-end peer-list 1.1.1.1
#
interface NULL0
#
ospf 1 router-id 2.2.2.2
area 0.0.0.0
network 2.2.2.0 0.0.0.255
network 10.1.1.0 0.0.0.255
#
ssh authorization-type default aaa
#
user-interface con 0
#
vm-manager
#
return
[CE2]
[CE2]dis ip rou
[CE2]dis ip routing-table
Proto: Protocol Pre: Preference
Route Flags: R - relay, D - download to fib, T - to vpn-instance, B - black hole
route
------------------------------------------------------------------------------
Routing Table : _public_
Destinations : 13 Routes : 13
Destination/Mask Proto Pre Cost Flags NextHop Interface
1.1.1.1/32 OSPF 10 1 D 10.1.1.2 Vlanif1500
2.2.2.0/24 Direct 0 0 D 2.2.2.2 LoopBack0
2.2.2.2/32 Direct 0 0 D 127.0.0.1 LoopBack0
2.2.2.255/32 Direct 0 0 D 127.0.0.1 LoopBack0
3.3.3.3/32 OSPF 10 2 D 10.1.1.2 Vlanif1500
10.1.1.0/24 Direct 0 0 D 10.1.1.1 Vlanif1500
10.1.1.1/32 Direct 0 0 D 127.0.0.1 Vlanif1500
10.1.1.255/32 Direct 0 0 D 127.0.0.1 Vlanif1500
20.1.1.0/24 OSPF 10 2 D 10.1.1.2 Vlanif1500
127.0.0.0/8 Direct 0 0 D 127.0.0.1 InLoopBack0
127.0.0.1/32 Direct 0 0 D 127.0.0.1 InLoopBack0
127.255.255.255/32 Direct 0 0 D 127.0.0.1 InLoopBack0
255.255.255.255/32 Direct 0 0 D 127.0.0.1 InLoopBack0
[CE2]
[CE3]dis arp
ARP Entry Types: D - Dynamic, S - Static, I - Interface, O - OpenFlow
EXP: Expire-time VLAN:VLAN or Bridge Domain
IP ADDRESS MAC ADDRESS EXP(M) TYPE/VLAN INTERFACE VPN-INSTA
NCE
------------------------------------------------------------------------------
20.1.1.1 707b-e8cd-6e15 I Vlanif2500
20.1.1.2 707b-e889-6853 13 D/2500 GE1/0/0
------------------------------------------------------------------------------
Total:2 Dynamic:1 Static:0 Interface:1 OpenFlow:0
[CE3]dis ip rou
[CE3]dis ip routing-table
Proto: Protocol Pre: Preference
Route Flags: R - relay, D - download to fib, T - to vpn-instance, B - black hole
route
------------------------------------------------------------------------------
Routing Table : _public_
Destinations : 13 Routes : 13
Destination/Mask Proto Pre Cost Flags NextHop Interface
1.1.1.1/32 OSPF 10 1 D 20.1.1.2 Vlanif2500
2.2.2.2/32 OSPF 10 2 D 20.1.1.2 Vlanif2500
3.3.3.0/24 Direct 0 0 D 3.3.3.3 LoopBack0
3.3.3.3/32 Direct 0 0 D 127.0.0.1 LoopBack0
3.3.3.255/32 Direct 0 0 D 127.0.0.1 LoopBack0
10.1.1.0/24 OSPF 10 2 D 20.1.1.2 Vlanif2500
20.1.1.0/24 Direct 0 0 D 20.1.1.1 Vlanif2500
20.1.1.1/32 Direct 0 0 D 127.0.0.1 Vlanif2500
20.1.1.255/32 Direct 0 0 D 127.0.0.1 Vlanif2500
127.0.0.0/8 Direct 0 0 D 127.0.0.1 InLoopBack0
127.0.0.1/32 Direct 0 0 D 127.0.0.1 InLoopBack0
127.255.255.255/32 Direct 0 0 D 127.0.0.1 InLoopBack0
255.255.255.255/32 Direct 0 0 D 127.0.0.1 InLoopBack0
[CE3]dis cu
[CE3]dis current-configuration
!Software Version V800R013C00SPC560B560
!Last configuration was updated at 2022-02-24 23:21:13+00:00
#
sysname CE3
#
device board 17 board-type CE-MPUB
device board 1 board-type CE-LPUE
#
vlan batch 2500
#
bridge-domain 20
vxlan vni 20
#
vni 20
#
aaa
#
authentication-scheme default
#
authorization-scheme default
#
accounting-scheme default
#
domain default
#
domain default_admin
#
interface Vlanif2500
ip address 20.1.1.1 255.255.255.0
#
interface MEth0/0/0
undo shutdown
#
interface GE1/0/0
undo shutdown
port default vlan 2500
#
interface GE1/0/1
undo shutdown
#
interface GE1/0/1.1 mode l2
encapsulation dot1q vid 20
bridge-domain 20
#
interface GE1/0/2
shutdown
#
interface GE1/0/3
shutdown
#
interface GE1/0/4
shutdown
#
interface GE1/0/5
shutdown
#
interface GE1/0/6
shutdown
#
interface GE1/0/7
shutdown
#
interface GE1/0/8
shutdown
#
interface GE1/0/9
shutdown
#
interface LoopBack0
ip address 3.3.3.3 255.255.255.0
#
interface Nve1
source 3.3.3.3
vni 20 head-end peer-list 1.1.1.1
#
interface NULL0
#
ospf 1 router-id 3.3.3.3
area 0.0.0.0
network 3.3.3.0 0.0.0.255
network 20.1.1.0 0.0.0.255
#
ssh authorization-type default aaa
#
user-interface con 0
#
vm-manager
#
return
[CE3]
[CE3]
[CE3]
下面的就是接口做trunk
然后下面做对应的vlan就行了
电脑ip为.10
gw为.1两边互通
好的本次到这里就结束了,欢迎观看我的文章。我是CCIE-Yasuo,喜欢就关注我吧,下一期见。 欢迎新盟教育的同学一起来交流,我是41期的疾风剑豪 同时我也是一名18岁来自大专的学生在学校写的,如有写的不对或侵权请及时联系删除。
|