Huawei Switch Port Configuration Guide

Source: Internet
Author: User

Port Configuration Guide for Huawei switches 1. ethernet Port Link Type S2000-HI series Ethernet switches support three Ethernet Port Link types :.. access type: the port can only belong to one VLAN and is generally used to connect to a computer ;.. trunk type: the port can belong to multiple VLANs and can receive and send packets from multiple VLANs. It is generally used for connection between switches; www.2cto.com .. hybrid: A port can belong to multiple VLANs. It can receive and send packets from multiple VLANs. It can be used to connect switches or to users' computers. Note: The Hybrid port allows messages of multiple VLANs to be sent without being tagged, however, the Trunk port only allows three types of ports that are not tagged when messages are sent by default VLAN. However, the Trunk port and the Hybrid port cannot be directly switched, you can only set it to an Access port and another type of port. For example, the Trunk port cannot be directly set to the Hybrid port, but can only be set to the Access port and then to the Hybrid port. 2. the default VLAN IDAccess port for configuring an Ethernet port can belong to only one VLAN. Therefore, its default VLAN is the VLAN where it is located. You do not need to set it. The Hybrid and Trunk ports can belong to multiple VLANs, therefore, you need to set the default vlan id for the port. After the default vlan id of the Ethernet port is configured, the port can process packets in different ways. For details, see the following description. When the received packets do not contain tags, the Access port receives the packets and adds the default VLAN Tag to the packets. When the received packets contain tags: when the vlan id is the same as the default vlan id, the vlan id receives the packet. When the vlan id and the default vlan id are different, the process for discarding the packet sending message is as follows: because the vlan id is the default vlan id, no need to set it. Remove the Tag and send the Trunk port. When the received packet does not contain a Tag, the packet is received, add the default VLAN Tag for the packet. When the received packet has a Tag: When the vlan id and the default vlan id are the same: when the vlan id is different from the default vlan id, but the vlan id is the vlan id allowed by the Port: when the vlan id is different from the default vlan id, and the vlan id is the vlan id that is not allowed to pass through the port, the processing for discarding the packet is as follows :.. when the vlan id is the same as the default vlan id, remove the Tag and send the packet .. When the vlan id is different from the default vlan id: keep the original Tag, send the packet to the Hybrid port. When the received packet does not contain a Tag, the packet is received, add the default VLAN Tag for the packet. When the received packet has a Tag: When the vlan id and the default vlan id are the same: when the vlan id is different from the default vlan id, but the vlan id is the vlan id allowed by the Port: when the vlan id is different from the default vlan id, and the vlan id is the vlan id that is not allowed to pass through the port, the processing for discarding the packet is as follows :.. when the vlan id is the same as the default vlan id, remove the Tag and send the packet .. when the vlan id is different from the default vlan id, you can use the command port hybrid vlan-id-list {tagged | untagged} to configure whether the port carries a Tag. Note: local Hybrid port or Trunk Port The default vlan id of the port must be the same as the default vlan id of the connected peer switch's Hybrid port or Trunk port. Otherwise, the port cannot forward packets normally. 3. Add the current port to the specified VLAN. You can add the current Ethernet port to the specified VLAN. After this configuration is executed, the Ethernet port can forward packets of the specified VLAN, so that the VLAN on the switch can communicate with the same VLAN on the peer switch. The Access port can only be added to one VLAN. The Hybrid port and the Trunk port can be added to multiple VLANs. Note: The VLAN to be added to the port must already exist. After the above configuration is performed, the Ethernet port can forward packets of the specified VLAN, so that packets of the same VLAN on the switch can communicate with those of the Peer switch. 4. set VLAN port configuration Access port properties to go to system view system-view to enter Ethernet port view interface-type interface-number the link type of the configured port is Accessport link-type access by default, the link type of the port is Access. Add the current Access port to the specified VLANport access vlan-id configuration Trunk port. Enter the system view system-view to enter the Ethernet port view interface-type interface- the link type of the number Configuration Port is Trunkport link-type trunk. The default VLAN IDport of the Trunk port is trunk pvid vlan-id (optional, the default VLAN of the Trunk port is the default VLAN of the system that adds the current Trunk port to the specified VLAN. Port trunk permit vlan {vlan-id-list | all} configure Hybrid port attributes to enter the system view system-view to enter the Ethernet port view interface-type interface-number configure the port Link type required for Hybridport link-type hybrid, the default VLAN of the Hybrid port is the default VLAN used by the system to add the current Hybrid port to the specified VLANport. The vlan-id-list {tagged | untagged} is optional, the Hybrid port can be set to label packets of the specified VLAN, laying the foundation for implementing different processing procedures for packets of different VLANs. enter the system View for the basic configuration of the Ethernet port W: Enter Ethernet port View interface-type interface-number enable the Ethernet port undo shutdown. By default, the port is open. If you want to disable the port, you can use the shutdown command to set the Ethernet port description string description text by default. The port description string is a Null String. Set the duplex mode of the Ethernet port duplex {auto | full | half} by default, port duplex mode: auto (self-negotiation) sets the Ethernet Port speed {10 | 100 | 1000 | auto} by default, the port speed is in auto (self-negotiation) by default, the MDI attribute of the Ethernet port is related to the port type. interface [command] interface-type interface-n Umber [view] System View [parameter] interface-type: Port type, which can be Aux, Ethernet, GigabitEthernet, LoopBack, NULL, or Vlan-interface. Interface-number: port number, in the format of Unit ID/Slot number/port number, where :.. the Unit ID value can only be 1 ;.. if the port type is Ethernet, the slot number is 0. If the port type is GigabitEthernet, the slot number is 1 or 2 ;.. the port number is related to the number of ports supported by the device. [Description] The interface command is used to enter the view of the corresponding port. For example, to configure parameters for an Ethernet port, you must first use this command to enter the Ethernet port view. [Example] # enter the Ethernet port view of Ethernet1/0/1. <Sysname> system-viewSystem View: return to User View with Ctrl + Z. [Sysname] interface ethernet 1/0/1 [Sysname-Ethernet1/0/1] 7. display interface [command] display interface [interface-type | interface-type interface-number] [view] any view [parameter] interface-type: Port type. Interface-number: port number. For more information about the parameters, see parameter description in the interface command. [Description] The display interface command is used to display the port configuration information. When the port information is displayed, if no port type and port number are specified, all port information on the vswitch is displayed. If only the port type is specified, all port information of the port type is displayed; if both the port type and port number are specified, the specified port information is displayed. 8. duplex [command] duplex {auto | full | half} undo duplex [view] Ethernet port view [parameter] auto: the port is in the Self-negotiation state. Full: the port is in full duplex status. Half: the port is in the half-duplex state. [Description] the duplex command is used to set the duplex attribute of the Ethernet port. The undo duplex command is used to restore the port duplex attribute to the default self-negotiation state. By default, the port is in the Self-negotiation status. [Example] # Set the duplex attribute of the Ethernet port Ethernet1/0/1 to the self-negotiation status. <Sysname> system-viewSystem View: return to User View with Ctrl + Z. [Sysname] interface ethernet 1/0/1 [Sysname-Ethernet1/0/1] duplex auto9.speed [command] speed {10 | 100 | 1000 | auto} undo speed [view] ethernet port view [parameter] 1st chapter port basic configuration command Quidway S2000-HI series Ethernet switch command manual port basic configuration 1-26 Huawei all and confidential All Rights Reserved (c) huawei Technology Co., Ltd. 10: The specified port speed is 10 Mbps. 100: The specified port speed is 100 Mbps. 1000: the specified port speed is 1000 Mbps (this parameter is only supported by Gigabit ports ). Auto: the speed of the specified port is in the Self-negotiation state. [Description] The speed command is used to set the port speed. The undo speed command is used to restore the port speed to the default value. By default, the port rate is in the Self-negotiation state. Note that a gigabit port can only be configured as 1000 Mbps or auto. For more information about the configuration, see duplex. [Example] # Set the Ethernet port Ethernet1/0/1 to 10 Mbps. <Sysname> system-viewSystem View: return to User View with Ctrl + Z. [Sysname] interface ethernet 1/0/1 [Sysname-Ethernet1/0/1] speed 1010, sub-vlan hybrid port configuration hybrid port receiving packet: receive a packet, determine whether there is VLAN information: if no port exists, the PVID of the port is configured, and the switch is forwarded. If yes, the hybrid port determines whether the VLAN data is allowed to enter. If yes, the port is forwarded, otherwise, discard (the untag configuration on the port does not need to be considered at this time, and the untag configuration only takes effect when sending packets) Note: The default pvid vlan is not tagged! Hybrid port sends packets: 1. Determine the attributes of the VLAN on the current port (disp interface can see which VLAN is untag and which VLAN is tag) 2. If it is an untag, the VLAN information is stripped and then sent, if it is a tag, directly send the following case to help you understand the hybrid port mode of the Huawei switch [Switch-Ethernet0/1] int e0/1 [Switch-Ethernet0/1] port link-type hybrid [Switch-Ethernet0 /1] port hybrid pvid vlan 10 [Switch-Ethernet0/1] port hybrid vlan 10 20 untagged [Switch-Ethernet0/1] int e0/2 [Switch-Ethernet0/2] port link-type hybrid [Switch-Ethernet0 /2] port Hybrid pvid vlan 20 [Switch-Ethernet0/2] port hybrid vlan 10 20 untagged at this time inter e0/1 and inter e0/2 under the connected PC can be interconnected, however, the round-trip vlan used for data communication is different. The following example describes the data sent by pc1 when pc1 accesses pc2 under inter e0/2, the pvid vlan10 of inter0/1 encapsulates vlan10 and sends it to the switch. The switch finds that inter e0/2 allows vlan 10 Data to pass through, so the data is forwarded to inter e0/2, because vlan 10 on inter e0/2 is untagged, the switch removes the vlan10 mark on the data packet and sends it to pc2 as a normal package, in this case, pc1-> p2 uses vlan10 to analyze the pc2 packet return process and the data sent by pc2, the pvid vlan20 of inter0/2 encapsulates the vlan20 label and sends it to the switch. The switch finds that inter e0/1 allows vlan 20 Data to pass through, so the data is forwarded to inter e0/1, because vlan 20 on inter e0/1 is untagged, the switch removes the vlan20 mark on the data packet and sends it to pc1 as a normal package. In this case, pc2-> pc1 follows vlan20.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.