思科交换机端口模式
交换机 的 端口 工作 模式 一般可以分为三种:Access,Multi,Trunk。 cisco网络中, 交换机 在局域网中最终稳定状态的接口类型主要有四种:access、trunk、 multi、dot1q-tunnel。 1、access: 主要用来接入终端设备,如PC机、服务器、打印服务器等。 2、tru
交换机的端口工作模式一般可以分为三种:Access,Multi,Trunk。
cisco网络中,交换机在局域网中最终稳定状态的接口类型主要有四种:access、trunk、 multi、dot1q-tunnel。
1、access: 主要用来接入终端设备,如PC机、服务器、打印服务器等。
2、trunk: 主要用在连接其它交换机,以便在线路上承载多个vlan。
-----------------------------------------------------------------------------------------------------------
Cisco支持多种Trunk方式(即对VLAN帧标识):
2.1. ISL――Cisco专有封装协议,也是默认的。前面加26字节,后面加4字节FCS。 帧长度1518/1548。可支持的VLAN数为1-1046。
2.2. IEEE 802.1Q――IEEE标准方法,在帧头写入VLAN信息,后面只增加4字节FCS。
帧长度为1518/1522。有12位的vlan标识,它可以支持到4096个VLAN。
802.1Q- trunk为转发未被标记的frame而定义了native VLAN(本地VLAN)。交换机能够从未被标记的trunk上的nativeVLAN转发2层frame,接受方将把所有的未标记frame转发到 native VLAN中 。VLAN1是默认的本地VLAN,也可以把其他的VLAN更改为本地VLAN。如果是ISL,则没被封装的frame将会丢弃,包括 nativeVLAN,所有的数据将被封装
2.3. 802.10――FDDI上传输VLAN信息的Cisco专有协议,把VLAN信息写入SAID安全关联标识符部分
2.4. LANE――基于ATM上传输VLAN信息的一种IEEE标准方法。
-------------------------------------------------------------------------------------------------------------
3、multi: 在一个线路中承载多个vlan,但不像trunk,它不对承载的数据打标签。主要用于接入支持多vlan的服务器或者一些网络分析设备。现在基本不使用此类接口,在cisco的网络设备中,也基本不支持此类接口了。
4、dot1q-tunnel: 用在Q-in-Q隧道配置中。
Cisco 网络设备支持动态协商端口的工作状态,这为网络设备的实施提供了一定的方便(但不建议使用动态方式)。cisco动态协商协议从最初的 DISL(Cisco私有协议)发展到DTP(公有协议)。根据动态协议的实现方式,Cisco网络设备接口主要分为下面几种模式:
1、switchport mode access: 强制接口成为access接口,并且可以与对方主动进行协商,诱使对方成为access模式。
2、 switchport mode dynamic desirable: 主动与对方协商成为Trunk接口的可能性,如果邻居接口模式为Trunk/desirable/auto之一,则接口将变成trunk接口工作。如果不 能形成trunk模式,则工作在access模式。这种模式是现在交换机的默认模式。
3、 switchport mode dynamic auto: 只有邻居交换机主动与自己协商时才会变成Trunk接口,所以它是一种被动模式,当邻居接口为Trunk/desirable之一时,才会成为 Trunk。如果不能形成trunk模式,则工作在access模式。
4、switchport mode trunk: 强制接口成为Trunk接口,并且主动诱使对方成为Trunk模式,所以当邻居交换机接口为trunk/desirable/auto时会成为Trunk接口。
5、 switchport nonegotiate: 严格的说,这不算是种接口模式,它的作用只是阻止交换机接口发出DTP数据包,即禁止端口向对方发送协商包,它必须与switchport mode trunk或者switchport mode access一起使用。
6、switchport mode dot1q-tunnel: 配置交换机接口为隧道接口(非Trunk),以便与用户交换机的Trunk接口形成不对称链路。
在思科4507交换机上查看端口的模式
cisco4507(config-if)#switchport ?
access Set access mode characteristics of the interface
block Disable forwarding of unknown uni/multi cast addresses
host Set port host
mode Set trunking mode of the interface
nonegotiate Device will not engage in negotiation protocol on this
interface
port-security Security related command
priority Set appliance 802.1p priority
private-vlan Set the private VLAN configuration
trunk Set trunking characteristics of the interface
voice Voice appliance attributes
cisco4507(config-if)#switchport mode access ?
cisco4507(config-if)#switchport mode trunk ?
cisco4507(config-if)#switchport mode ?
access Set trunking mode to ACCESS unconditionally
dot1q-tunnel set trunking mode to TUNNEL unconditionally
dynamic Set trunking mode to dynamically negotiate access or trunk mode
private-vlan Set the mode to private-vlan host or promiscuous
trunk Set trunking mode to TRUNK unconditionally
cisco4507(config-if)#switchport mode dynamic ?
auto Set trunking mode dynamic negotiation parameter to AUTO
desirable Set trunking mode dynamic negotiation parameter to DESIRABLE
配置交换机模式举例1
SW1:
interface FastEthernet0/1
switchport mode dynamic desirable
SW1#show interface fa0/1 switchport
Name: Fa0/1
Switchport: Enabled
Administrative Mode: dynamic desirable
Operational Mode: static access
Administrative Trunking Encapsulation: negotiate
Operational Trunking Encapsulation: native
Negotiation of Trunking: On
Access Mode VLAN: 1 (default)
Trunking Native Mode VLAN: 1 (default)
如果两个相连的交换机端口都配置为switchport mode dynamic desirable,首先会协商为trunk,并且封装为ISL
配置举例说明2:(假定SW1的f0/13 连接到SW2的F0/13上)
SW1(f0/13)--------(f0/13)SW2
SW1
interface FastEthernet0/13
switchport mode dynamic desirable
SW2
interface FastEthernet0/13
switchport mode dynamic desirable
SW1#show interface status | include (Port|Fa0/13)
Port Name Status Vlan Duplex Speed Type
Fa0/13 connected trunk a-full a-100 10/100BaseTX
注意加粗部分,最终协商的模式为trunk,并且封装的协议为ISL
SW1#show interface fa0/13 switchport
Name: Fa0/13
Switchport: Enabled
Administrative Mode: dynamic desirable
Operational Mode: trunk
Administrative Trunking Encapsulation: negotiate
Operational Trunking Encapsulation: isl
Negotiation of Trunking: On
Access Mode VLAN: 1 (default)
Trunking Native Mode VLAN: 1 (default)

Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

Video Face Swap
Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Article

Hot Tools

Notepad++7.3.1
Easy-to-use and free code editor

SublimeText3 Chinese version
Chinese version, very easy to use

Zend Studio 13.0.1
Powerful PHP integrated development environment

Dreamweaver CS6
Visual web development tools

SublimeText3 Mac version
God-level code editing software (SublimeText3)

Hot Topics

What does WeChat Do Not Disturb mode mean? Nowadays, with the popularity of smartphones and the rapid development of mobile Internet, social media platforms have become an indispensable part of people's daily lives. WeChat is one of the most popular social media platforms in China, and almost everyone has a WeChat account. We can communicate with friends, family, and colleagues in real time through WeChat, share moments in our lives, and understand each other’s current situation. However, in this era, we are also inevitably faced with the problems of information overload and privacy leakage, especially for those who need to focus or
![Soundbar detected as monitor screen on Windows PC [Fix]](https://img.php.cn/upload/article/000/465/014/170835733166289.jpg?x-oss-process=image/resize,m_fill,h_207,w_330)
On Windows PCs, some users have discovered that the Soundbar is recognized as a monitor when connected to the HDMI port. This may cause some confusion, but the solution is not the only one. How to Connect a Soundbar to a PC via HDMI Most soundbars use HDMI, optical, or 3.5mm audio connections. If your soundbar only supports HDMI connections, it must be connected to an HDMI port labeled HDMIARC. Many TVs or monitors are usually equipped with multiple HDMI ports, one of which should support the ARC protocol that complies with the HDMI standard. In other words, HDMI is an interface used to transmit audio and video. If the device does not have an HDMI port, consider using a monitor.

iOS devices have long been able to track your sleep patterns and more using the Health app. But isn’t it annoying when you’re disturbed by notifications while you’re sleeping? These notifications may be irrelevant and therefore disrupt your sleep patterns in the process. While Do Not Disturb mode is a great way to avoid distractions while sleeping, it can cause you to miss important calls and messages you receive during the night. Thankfully, this is where sleep mode comes in. Let’s learn more about it and how to use it on iPhone. What role does sleep mode play on the iPhone? Sleep mode is a dedicated focus mode in iOS that is automatically activated based on your sleep schedule in the "Health" App. It helps you set an alarm and then

What is the cause of iOS17 charging problem? There are several possible reasons why your iPhone may not be charging after updating to iOS17. One possibility is that there is a bug in the software update. Apple is usually quick to fix bugs in iOS updates, so if you're having charging issues it's worth checking to see if a new update is available. Another possibility is that there is a problem with the charging cable or adapter. If you're using a third-party charging cable or adapter, make sure it's certified by Apple. How to Fix iPhone Not Charging Issue Here are some tips on how to fix iPhone not charging issue after iOS17 update: Restart your Apple phone This usually resolves minor issues that may be the root cause of iOS17 charging issue

If you encounter an AHCI port 0 device error every time you start your computer, you need to follow the methods provided in this article to solve the problem. What is AHCI port 0 device error? AHCI device errors are reported by the BIOS. SMART has indicated that the hard drive on port 0 is faulty and may not be accessible. The hard drive may have problems at any time. If it is a desktop computer, it is recommended to try changing the hard drive connection port. If the problem persists, it may be a problem with the hard drive itself. You can run a disk check tool, disable the failed hard drive and check the ports to resolve this issue. Fixing AHCI Port 0 Device Errors on Windows Computers Typically, AHCI Port0 device errors do not originate from operating system issues, but rather from the hard drive failing on port 0.

Even answering calls in Do Not Disturb mode can be a very annoying experience. As the name suggests, Do Not Disturb mode turns off all incoming call notifications and alerts from emails, messages, etc. You can follow these solution sets to fix it. Fix 1 – Enable Focus Mode Enable focus mode on your phone. Step 1 – Swipe down from the top to access Control Center. Step 2 – Next, enable “Focus Mode” on your phone. Focus Mode enables Do Not Disturb mode on your phone. It won't cause any incoming call alerts to appear on your phone. Fix 2 – Change Focus Mode Settings If there are some issues in the focus mode settings, you should fix them. Step 1 – Open your iPhone settings window. Step 2 – Next, turn on the Focus mode settings

LSOF (ListOpenFiles) is a command line tool mainly used to monitor system resources similar to Linux/Unix operating systems. Through the LSOF command, users can get detailed information about the active files in the system and the processes that are accessing these files. LSOF can help users identify the processes currently occupying file resources, thereby better managing system resources and troubleshooting possible problems. LSOF is powerful and flexible, and can help system administrators quickly locate file-related problems, such as file leaks, unclosed file descriptors, etc. Via LSOF Command The LSOF command line tool allows system administrators and developers to: Determine which processes are currently using a specific file or port, in the event of a port conflict

On iPhone 15 Pro and iPhone 15 Pro Max models, Apple introduced a physically programmable action button that replaces the traditional ring/silent switch above the volume buttons. The action button can be programmed to perform several different functions, but the ability to switch between silent and ring modes isn't gone. By default, a long press on the action button will silence the device and the button's tactile feedback will pulse three times. Both iPhone 15 Pro models will display a crossed-out bell symbol next to the time in the status bar to indicate that silent/silent mode is activated, and it will remain so until you long-press the Action button again to unmute the device. If you prefer to put your iPhone in silent mode
