Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

话数通 #79

Open
Triment opened this issue May 3, 2023 · 5 comments
Open

话数通 #79

Triment opened this issue May 3, 2023 · 5 comments

Comments

@Triment
Copy link
Owner

Triment commented May 3, 2023

access一般用于终端设备,如路由器、服务器、pc等
trunk一般用于交换机

@Triment
Copy link
Owner Author

Triment commented May 3, 2023

802.1Q 中注入tag

@Triment
Copy link
Owner Author

Triment commented May 3, 2023

trunk,hybird的pvid不打标签,access的pvid就是vlan id,pvid缺省为1

@Triment
Copy link
Owner Author

Triment commented May 3, 2023

vlan创建

vlan batch xx xx xx

命名vlan

[vlan 10] name VlanName

在vlan中加入端口

[vlan 10] port G0/0/1

@Triment
Copy link
Owner Author

Triment commented May 3, 2023

access端口<- [数据包]逻辑

if(port.vlan_id == data.vlan_id) resolve
if(port.vlan_id == null) resolve
reject()

access端口->[数据包]逻辑
剥离vlanid tag后发送,电脑接到有tag的数据包时丢弃数据包

@Triment
Copy link
Owner Author

Triment commented May 3, 2023

trunk 无tag数据包接受
1、打pvid
2、过allow-pass vlan列表看该pvid是否在列表内,在接受,不在丢弃
有tag接受
1、过allow-pass vlan列表看该tag是否在列表内,在接受,不在丢弃

trunk发送数据包
有tag无就丢弃
1、判断在allow-pass列表中没,不在就丢弃
2、和pvid相等吗,相等就去tag
3、发送

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant