当前位置:网站首页>HCIP Fifteenth Day Notes (Three-layer Architecture of Enterprise Network, VLAN and VLAN Configuration)
HCIP Fifteenth Day Notes (Three-layer Architecture of Enterprise Network, VLAN and VLAN Configuration)
2022-08-03 13:36:00 【oranges love oranges】
一、企业网的三层架构(企业网搭建时的一个参考建议方案):

园区----工厂、政府机关、写字楼、商场、The network built in these public places such as campuses to realize data intercommunication is called the campus network(“城市,除了街道,都是园区”),不同园区搭建网络其侧重点不同,但是都可以参考三层架构来进行搭建.
1、接入层:
Provide terminal equipment(电脑等)接入网络------It is mainly composed of access layer switches----Access layer switches are mainly composed of layer 2 switches,
二层交换机指的是通过识别MAC地址查询MAC地址表来进行二层转发的设备.(//The Layer 2 switch itself is not requiredMAC地址)
“无线永远是有线的最后一公里”----The main reason is that the wireless transceiver device still needs to be connected to the wired network through the network cable,
AP-----无线接入点
WLAN(//家庭中WLANThe operator deployed in the access cell)------无线局域网------从广义上来讲,指以无线电波、激光,Infrared, etc. to replace the network composed of part or all of the transmission medium in the wired local area network.
无线的缺陷:
1、传输速率低于有线,并且信号强度存在波动,和信号发射点位置越远,信号越弱.
2、无线信号Penetration is poor(//信号越高,Penetration is poor,基站越多,比如5G)
以太网可以实现频分
3、上网用户数量增多,则网络卡顿严重
CSMA/CD----Carrier Sense Multiple Access/冲突检测(//类似于排队,Sort the signals in order,Then check whether the previous one has been sent,See if the previous one has a signal,If the previous signal is gone,Then post the second one)
There's a reason wireless networks don't use collision detection techniques:
1、无线网络本身信号强度动态范围非常大,往往收到的信号强度可能远小于发出时的强度,所以,检测冲突比较困难.
2、在无线网络的应用场景中,存在很多冲突无法检测的场景
CSMA/CA------载波侦听多路访问/冲突避免
1、Even when no signal is detected,也不立即发送信息,而是先执行避让动作,给自己设计一个随机的计时器,时间到了之后,sending information.
2、CSMA/CA技术,为了保证传输的数据的可靠性,
采用了停等式流控----每发一个数据包,要求对方回复ACK进行确认,否则重传.
2、汇聚层(//使用三层交换机)----- The traffic that will be collected by the access layer switch,Aggregation is required,Then the aggregation layer is formed.
Aggregation layer devices generally use Layer 3 switches to complete,Layer 3 switch features:The Layer 2 port used by the solid Layer 2 forwarding of the existing Layer 2 switch,There are also Layer 3 ports similar to routers that can implement Layer 3 forwarding.
The most direct difference between a Layer 3 port and a Layer 2 port:Layer 3 ports need to be configuredIP地址,则也需要具有MAC地址),所以,在三层 in the switch,即拥有MAC地址表以及路由表,相当于是二层交换机和路由器集成的产物.
企业网的三层架构-----核心思想------冗余(备份)------保证网络的稳定性
1、线路冗余
2、设备冗余
3、网关冗余
4、UPS冗余-----UPS-----不间断电源
3、核心层--------The main function is to complete the fast forwarding of data between the private network and the public network.
The core layer generally uses routers as core devices.
二、VLAN
V-----虚拟
LAN---局域网------广播域
虚拟局域网-------It can be understood as a virtual broadcast domain,交换机和路由器协同工作后,将原来一个广播域逻辑上划分成多个虚拟的广播域.

VLAN的配置:
step:
1、创建VLAN
[lsw]vlan 2
[lsw-vlan2]
[lsw]display vlan ------查看VLAN
[lsw]vlan batch 4 to 100----批量创建VLAN
[lsw]undo vlan batch 4 to 100----批量删除VLAN
VID-----VLAN ID-----用来区分和标定不同的VLAN-----IEEE组织在802.1Q标准中进行了规定,规定VID必须由12位二进制构成------0-4095,其中0和4095为保留----所以,VID取值范围为1-4094.
2、将接口划入到VLAN
将VID配置映射到交换机的接口上,实现VLAN的划分-----物理VLAN/一层VLAN.
将VID配置映射到数据包中的MAC地址,实现VLAN的划分------二层VLAN
将数据帧中的类型字段所标记的上层协议和VID进行映射,实现VLAN的划分-----三层VLAN

因为设备的层次叫法主要是根据其转发特性来决定的,并不代表设备没有处理上层的能力,所以VLAN也可以基于IP地址进行划分,也可以基于策略进行划分.
In the switch in order to distinguish differentVLAN的流量,需要给数据帧打上标签,于是有了802.1Q帧
,在普通的以太网Ⅱ型帧的基础上,在其源MAC和类型字段之间增加了4个字节的标签,称为TAG,里面包含12位的VID,Such frames are called tagged帧,没有打标签的帧也可以被称为untagged帧.
依靠802.1Q帧的特性,交换机和PC之间的链路称为Access链路,AccessThe interface on the switch side of the link is calledAccess接口,Access链路中,只能通过untagged帧,并且,这些帧一定属于某一个特定的VLAN;我们将交换机和交换机之间的链路称为trunk链路(trunk干道),trunk链路中交换机侧的接口被称为trunk接口.trunklink cantagged帧,并且这些帧可以属于多个VLAN.
3、配置trunk干道
1、 将接口划入VLAN
[lsw1]int g 0/0/1
[lsw1-GigabitEthernet0/0/1]port link-type access ------使用access链路
[lsw1-GigabitEthernet0/0/1]port default vlan 2----默认接口为VLAN2
[lsw1-GigabitEthernet0/0/1]
[lsw1-GigabitEthernet0/0/2]port link-type access
[lsw1-GigabitEthernet0/0/2]port default vlan 2
[lsw1-GigabitEthernet0/0/2]
[lsw1]port-group group-member GigabitEthernet 0/0/3 GigabitEthernet 0/0/4-----批量创建VLAN3
[lsw1-port-group]port link-type access
[lsw1-GigabitEthernet0/0/3]port link-type access
[lsw1-GigabitEthernet0/0/4]port link-type access
[lsw1-port-group]port default vlan 3
[lsw1-GigabitEthernet0/0/3]port default vlan 3
[lsw1-GigabitEthernet0/0/4]port default vlan 3
[lsw1-port-group]
2、trunk配置
[lsw1]int g 0/0/5
[lsw1-GigabitEthernet0/0/5]port link-type trunk ----使用trunk链路
[lsw1-GigabitEthernet0/0/5]port trunk allow-pass vlan ?
INTEGER<1-4094> VLAN ID
all All
[lsw1-GigabitEthernet0/0/5]port trunk allow-pass vlan 2 3-----允许trunk链路通过VLAN 2和VLAN 3
[lsw1-GigabitEthernet0/0/5]
[lsw2]int g 0/0/1
[lsw2-GigabitEthernet0/0/1]port link-type trunk
[lsw2-GigabitEthernet0/0/1]port trunk allow-pass vlan all ----允许通过所有VLAN
[lsw2-GigabitEthernet0/0/1]
Hybrid-—混杂接口
[lsw1]display port vlan active -----查看
在不做任何配置的情况下,华为交换机默认的接口类型为hybrid类型.
PVID-----代表接口所属的VID-----华为设备设定,All interfaces are without device configuration,其PVID为1,即其默认属于VLAN 1
华为设备规定,All data entering the switch through the interface must be tagged,If not labelled,需要打上进入接口PVID的标签.
VLAN list----允许列表,该接口允许那些VLAN的流量通过,则列表中就有他们的VID
这两个标记代表的是从该接口转出的数据是否允许带标签,T允许带标签,ULabels are not allowed:
U----untagged
T----tagged
注意:在trunk干道中,只有和trunk接口PVID相同的VLANTraffic can go out without labels
Access接口:
1、当Access接口从链路上收到一个untagged帧时,交换机首先会在数据帧中添加VID为PVID的标签,之后查看允许列表,If the allow list is in that dataframeVID号,则转发(Access接口因为允许列表中的VID 号和自己的PVID相同,所以,这种情况下,一定可以转发)
2、当一个tagged帧从交换机的其他端口到达一个Access端口后,交换机会检查这个帧中的tag的VID是否和允许列表中的VID相同,如果不同.则丢弃;如果相同,则需要先剥离标签后发出到链路上.
3、如果Access接口在链路上收到一个tagged帧,then the switch will check itVIDWhether it will be in the local allow list,如果在,则转发,不在,则丢弃.
trunk接口:
1、当trunkThe interface received one from the linkuntagged帧,交换机首先会在数据帧中添加VID为PVID的标签,之后,查看允许列表,如果允许列表中有该数据帧标签中的VID号,则转发,如果没有,则丢弃.
2、当一个tagged帧从交换机的其他接口到达一个trunk接口后,如果这个tag中的VID不在trunk接口中,Then the allow list will be discarded directly,如果在,则转发.如果VID和trunk接口的PVID相同,则剥离标签后发出,如果不相同,则不剥离标签,直接发出.
3、当trunk接口在链路上收到tagged帧,交换机将先查看这个tagged帧中的VID是否在允许列表中,如果在,则转发,如果不在,则丢弃.
Access----可以修改PVID,可以修改允许列表(但是PVID和允许列表必须相同且只能允许一个VLAN的流量通过),The packaging method for export can only be packaged without labels
trunk----可以修改PVID,可以修改允许列表,而且允许列表中可以通过多个VLAN的流量,出口封装方式仅为带标签封装(PVID若在允许列表中,The package is assumed to be unlabeled by default)
[lsw1-GigabitEthernet0/0/5]port trunk pvid ?-------修改trunk接口的PVID
vlan Virtual LAN
hybrid------可以修改PVID,可以修改允许列表,而且允许列表中可以通过多个VLAN的流量,而且可以修改出口的封装方式.
[lsw3]int g 0/0/1
[lsw3-GigabitEthernet0/0/1]port link-type hybrid ------Modify the type of the interface to promiscuous mode
[lsw3-GigabitEthernet0/0/1]port hybrid pvid vlan 2------修改混杂口的PVID
[lsw3-GigabitEthernet0/0/1]
[lsw3-GigabitEthernet0/0/1]port hybrid untagged vlan 2 3 4----修改允许列表,并且出去的时候不带标签
[lsw3-GigabitEthernet0/0/1]port hybrid tagged vlan 2 3 4-----带标签
4、VLAN间路由
子接口------路由器的虚拟接口-----路由器将一个物理接口逻辑上的切分为多个虚拟的子接口.
[R1]int g 0/0/0.1-----创建子接口
[R1-GigabitEthernet0/0/0.1]
[R1-GigabitEthernet0/0/0.1]ip address 192.168.1.254 24
[R1-GigabitEthernet0/0/0.1]dot1q termination vid 2-----识别VLAN 2
[R1-GigabitEthernet0/0/0.1]arp broadcast enable -----开启ARP广播-----开启后子接口才会进行ARP应答
边栏推荐
- 4年工作经验,多线程间的5种通信方式都说不出来,你信吗?
- 厨卫电器行业数字化集采管理系统:优化产业供应结构,实现采购业务流程集中管控
- Golang structs & methods
- “芯片法案”通过后,美光承诺在美国扩产
- An introduction to the skeleton tool
- c语言结构体知识总结
- JS get browser type
- Golang arrays and slices
- [Practical skills] APP video tutorial for updating APP in CANFD, I2C, SPI and serial port mode of single-chip bootloader (2022-08-01)
- An工具介绍之钢笔工具、铅笔工具与画笔工具
猜你喜欢

sessionStorage of BOM series

HCIP 第十六天笔记(SVI、生成树协议)

HCIP第十五天笔记(企业网的三层架构、VLAN以及VLAN 的配置)
![[OpenCV] Cascade classifier training model](/img/37/ba57190d3515432700ec97ad14d0b9.png)
[OpenCV] Cascade classifier training model

An introduction to the width tool, deformation tool and lasso tool

leetcode 11. The container that holds the most water

PyTorch构建分类网络模型(Mnist数据集,全连接神经网络)

TiFlash 计算层概览

An introduction to 3D tools

typedef关键字的用法
随机推荐
[Microservice] Multi-level cache
设计思维 | 详看设计工作坊Workshop的11个关键技巧
leetcode 11. 盛最多水的容器
ECCV 2022 | AirDet: 无需微调的小样本目标检测方法
使用百度EasyDL实现施工人员安全装备检测
d作者:d的新特性
有哪些好用的IT资产管理平台?
硬件业务收入下滑,为了赚钱,苹果暧昧对待流氓软件和增加广告了
JS get browser type
【框架】idea找不到xxx依赖项怎么办
Golang 通道 channel
保健用品行业B2B电子商务系统:供采交易全链路数字化,助推企业管理精细化
Nature, Cell都在用的Relia Tech 抗原亲和纯化LYVE1抗体
背后的力量 | 提升医疗服务“速度“和“温度” 华云数据助力上海国际医学中心加速智慧医院建设
TiFlash 计算层概览
北斗三号系统建成开通两周年:基础设施端核心技术已实现自主可控
客户:我们系统太多,能不能实现多账号互通?
The components of the basis of An animation movie clip animation between traditional filling
汉源高科G8032标准ERPS环网交换机千兆4光10电工业以太网交换机环网+WEB管理+SNMP划VLAN
An introduction to 3D tools