Huawei Switch configuration command details Huawei QuidWay Switch configuration command manual, Huawei quidway

Source: Internet
Author: User
Tags passthrough

Huawei Switch configuration command details Huawei QuidWay Switch configuration command manual, Huawei quidway
1. Start

Establish a local configuration environment and connect the serial port of the host to the Console port of the Ethernet switch through the configuration cable.

Run the terminal simulation program (such as a Windows Super Terminal) on the host and set the communication parameters of the terminal: the baud rate is 9600bit/s, 8-Bit Data bit, 1-bit stop bit, no checksum and no traffic control, and the terminal type is VT100.

When the Ethernet switch is powered on, the terminal displays the self-check information of the Ethernet switch. After the self-check is completed, the user is prompted to press Enter. a command line prompt (such).

Type a command to configure the Ethernet switch or view the running status of the Ethernet switch. You can enter "? "

2. Command View

(1) User View (view the simple operation status and statistical information of the switch): Connect to the vswitch.

(2) system view (configure system parameters) [Quidway]: In the user view, type system-view

(3) ethernet port view (configuring ethernet port parameters) [Quidway-Ethernet0/1]: type interface ethernet 0/1 in System View

(4) VLAN view (configure VLAN parameters) [Quidway-Vlan1]: in the System View, type vlan 1

(5) VLAN interface view (configure the IP interface parameters corresponding to VLAN and VLAN aggregation) [Quidway-Vlan-interface1]: in the System View, type interface vlan-interface 1

(6) local user View (configure local user parameters) [Quidway-luser-user1]: type local-user user1 in System View

(7) user interface view (configure user interface parameters) [Quidway-ui0]: type user-interface in System View

3. Other commands

Set system time and time zoneClock time Beijing add 8

Clock datetime 12:00:00 2005/01/23

Set the vswitch name [Quidway] sysname TRAIN-3026-1 [TRAIN-3026-1]

Configure user logon to [Quidway] user-interface vty 0 4

[Quidway-ui-vty0] authentication-mode scheme

Create a local user [Quidway] local-user huawei

[Quidway-luser-huawei] password simple huawei

[Quidway-luser-huawei] service-type telnet level 3

4. VLAN configuration method

"Configure Environment Parameters 』

SwitchA port E0/1 belongs to VLAN2, and E0/2 belongs to VLAN3

"Networking requirements 』

Add vswitch ports E0/1 to VLAN2 and E0/2 To VLAN3

Data configuration steps

"VLAN configuration process 』

(1) by default, all ports belong to VLAN 1 and the port is an access port. One access port can only belong to one vlan;

(2) If the port is an access port, when the port is added to another vlan, the system automatically deletes the port from the original vlan;

(3) Except for VLAN1, if vlan xx does not exist, type vlan xx in the System View to create vlan xx and enter the VLAN view. If vlan xx already exists, enter the VLAN view.

[SwitchA configuration]

Method 1:

(1) Create (enter) vlan2

[SwitchA] vlan 2

(2) Add port E0/1 to vlan2

A [SwitchA-vlan2] port ethernet 0/1

(3) create (enter) vlan3

[SwitchA-vlan2] vlan 3

(4) add Port E0/2 To vlan3

A [SwitchA-vlan3] port ethernet 0/2

Method 2:

(1) Create (enter) vlan2

[SwitchA] vlan 2

(2) Go to port E0/1.

[SwitchA] API ethernet 0/1

(3) the specified port E0/1 belongs to vlan2.

A [SwitchA-Ethernet1] port access vlan 2

(4) Create (enter) vlan3

[SwitchA] vlan 3

(5) Go to port E0/2.

[SwitchA] API ethernet 0/2

(6) the specified port E0/2 belongs to vlan3.

A [SwitchA-Ethernet2] port access vlan 3

Test and verification

(1) run the disp cur command to check that port E0/1 belongs to vlan2 and E0/2 belongs to vlan3;

(2) using display interface Ethernet 0/1, we can see that the port is access port, and the PVID is 2;

(3) using display interface Ethernet 0/2, we can see that the port is access port, and the PVID is 3.

5. vswitch IP Address Configuration

Functional requirements and networking description

"Configure Environment Parameters 』

The layer-3 Switch SwitchA has two ports: ethetnet 0/1 and ethernet 0/2, which respectively belong to vlan 2 and vlan 3;

Use the layer-3 interface address 1.0.0.1/24 of vlan 2 as the PC1 gateway;

Use the layer-3 interface address 2.0.0.1/24 of vlan 3 as the gateway of pc2;

"Networking requirements 』

PC1 and PC2 communicate with each other through layer-3 Interfaces

[SwitchA configuration]

(1) Create (enter) vlan2

[Quidway] vlan 2

(2) Add port E0/1 to vlan2

A [Quidway-vlan2] port ethernet 0/1

(3) virtual interfaces entering vlan2

[Quidway-vlan2] interface vlan 2

(4) configure the IP address on the Virtual Interface of vlan2

[Quidway-Vlan-interface2] ip address 1.0.0.1 255.255.255.0

(5) Create (enter) vlan3

[Quidway] vlan 3

(6) Add E0/2 To vlan3

A [Quidway-vlan3] port ethernet 0/2

(7) virtual interfaces entering vlan3

The [Quidway-vlan3] interface vlan 3

(8) configure the IP address on the Virtual Interface of vlan3

[Quidway-Vlan-interface3] ip address 2.0.0.1 255.255.255.0

Test and verification

(1) Both PC1 and PC2 can PING their own gateways.

(2) PC1 and PC2 can PING each other

6. Port trunk Configuration

"Configure Environment Parameters 』

(1) SwitchA port E0/1 belongs to vlan10, E0/2 belongs to vlan20, E0/3 is connected to SwitchB port E0/3

(2) SwitchB port E0/1 belongs to vlan10, E0/2 belongs to vlan20, E0/3 and SwitchA port E0/3

"Networking requirements 』

(1) interconnection between SwitchA vlan10 PC and SwitchB vlan10 PC

(2) interconnection between SwitchA vlan20 PC and SwitchB vlan20 PC

Data configuration steps

[SwitchA configuration]

(1) Create (enter) vlan10

[SwitchA] vlan 10

(2) Add E0/1 to vlan10

A [SwitchA-vlan10] port Ethernet 0/1

(3) create (enter) vlan20

[SwitchA] vlan 20

(4) Add E0/2 To vlan20

A [SwitchA-vlan20] port Ethernet 0/2

(5) In practice, the uplink port is generally set to the trunk attribute, allowing vlan passthrough

[SwitchA-Ethernet0/3] port link-type trunk

(6) Allow all VLANs to pass through E0/3, or specify specific vlan values

[SwitchA-Ethernet0/3] port trunk permit vlan all

[SwitchB configuration]

(1) Create (enter) vlan10

[SwitchB] vlan 10

(2) Add E0/1 to vlan10

A [SwitchB-vlan10] port Ethernet 0/1

(3) create (enter) vlan20

[SwitchB] vlan 20

(4) Add E0/2 To vlan20

A [SwitchB-vlan20] port Ethernet 0/2

(5) In practice, the uplink port is generally set to the trunk attribute, allowing vlan passthrough

[SwitchB-Ethernet0/3] port link-type trunk

(7) Allow all VLANs to pass through E0/3, or specify specific vlan values

[SwitchB-Ethernet0/3] port trunk permit vlan all

[Additional description]

(1) If a port is a trunk port, the port can belong to multiple VLANs;

(2) by default, the PVID of the trunk port is 1. You can use the port trunk pvid vlan vlanid command in port mode to modify the PVID of the port;

(3) If the vlan id of the data packet forwarded from the trunk is the same as the PVID of the port, the VLAN information in the packet will be removed. This should be noted when configuring the trunk port.

(4) If a port has been set as the hybrid port on a vswitch, you cannot set another port as the trunk port.

(5) In general, it is best to specify the specific VLANs allowed by the port. Do not set to allow all VLANs to pass through.

Test and verification

(1) The PC in SwitchA vlan10 can communicate with the PC in SwitchB vlan10.

(2) The PC in SwitchA vlan20 can communicate with the PC in SwitchB vlan20.

(3) The PC in SwitchA vlan10 cannot communicate with the PC in SwitchB vlan20.

(4) The PC in SwitchA vlan20 cannot communicate with the PC in SwitchB vlan10.

7. Port aggregation configuration

"Configure Environment Parameters 』

(1) SwitchA and SwitchB are interconnected through Ethernet ports.

(2) SwitchA ports used for interconnection are e0/1 and e0/2, and SwitchB ports used for interconnection are e0/1 and e0/2.

"Networking requirements 』

Increase the bandwidth of SwitchB interconnection links of SwitchA, and implement link backup and use port aggregation.

Data configuration steps

SwitchA Switch configuration]

(1) enter port E0/1

[SwitchA] API Ethernet 0/1

(2) The aggregation port must work in full duplex mode.

[SwitchA-Ethernet0/1] duplex full

(3) The aggregation port speed must be the same, but cannot be adaptive.

[SwitchA-Ethernet0/1] speed 100

(4) enter port E0/2

[SwitchA] API Ethernet 0/2

(5) The aggregation port must work in full duplex mode.

[SwitchA-Ethernet0/2] duplex full

(6) The aggregation port speed must be the same, but cannot be adaptive.

[SwitchA-Ethernet0/2] speed 100

(7) port selection aggregation Based on source and target MAC

[SwitchA] link-aggregation Ethernet 0/1 to Ethernet 0/2 both

SwitchB Switch configuration]

[SwitchB] API Ethernet 0/1

[SwitchB-Ethernet0/1] duplex full

[SwitchB-Ethernet0/1] speed 100

[SwitchB] API Ethernet 0/2

[SwitchB-Ethernet0/2] duplex full

[SwitchB-Ethernet0/2] speed 100

[SwitchB] link-aggregation Ethernet 0/1 to Ethernet 0/2 both

[Additional description]

(1) The link type of the member ports in the same aggregation group must be the same as that of the master port. That is, if the master port is a Trunk port, the member port is also a Trunk port; if the link type of the master port is changed to Access port, the link type of the member port is also changed to Access port.

(2) Different products have different requirements on the starting port numbers for port aggregation. Please configure the ports according to the operation manual.

8. Port image Configuration

"Environment configuration parameters 』

(1) PC1 is connected to port E0/1 of vswitch, IP address 1.1.1.1/24

(2) PC2 is connected to port E0/2 of vswitch, IP address 2.2.2.2/24

(3) E0/24 indicates the uplink port of the switch.

(4) The Server is connected to port E0/8 of the vswitch. This port serves as the mirror port.

"Networking requirements 』

(1) Monitor the service packets of two PCs using the switch port mirroring function.

The image is configured in different ways based on different models of the Quidway switch:

Port-based images-Port-based images completely copy incoming and outgoing data packets from the mirrored ports to the mirror ports for traffic observation or fault locating.

Stream-based image: A vswitch based on a stream image mirrors some streams. Each connection has two data streams. For a vswitch, these two data streams must be mirrored separately.

Vswitches such as S2008/S2016/S2026/S2403H/S3026 support port-based images.

8016 vswitch supports port-based images

3500/3026 E/3026F/3050 supports stream-based images

5516/6506/6503/6506 R supports mirroring inbound port traffic

Data configuration steps

Taking Quidway S3026C as an example, you can configure it using a layer-2 stream-based image:

(1) define an ACL

[SwitchA] acl num0 200

(2) define a rule to send data packets from E0/1 to all other ports.

[SwitchA] rule 0 permit ingress interface Ethernet0/1 egress interface Ethernet0/2

(3) define a data packet from all other ports to E0/1.

[SwitchA] rule 1 permit ingress interface Ethernet0/2 egress interface Ethernet0/1

(4) mirror data packets that comply with the preceding ACL to E0/8

[SwitchA] mirrored-to link-group 200 interface e0/8

9. Spanning Tree STP Configuration

"Configure Environment Parameters 』

(1) SwitchA, SwitchB, and SwitchC are interconnected through GE interfaces.

(2) SwitchB and SwitchC switches are core switches and must be active/standby.

"Networking requirements 』

Require the entire network to run the STP protocol

Data configuration steps

(1) [SwitchA Switch configuration]

Enable Spanning Tree Protocol: [SwitchA] stp enable

(1) [SwitchB Switch configuration]

Enable Spanning Tree Protocol: [SwitchB] stp enable

(3) configure the local bridge as the root bridge

[SwitchB] stp root primary

(4) [SwitchC Switch configuration]

A starts Spanning Tree Protocol [SwitchC] stp enable

B. Configure the local bridge as the backup root bridge [SwitchC] stp root secondary

(5) [SwitchD Switch configuration]

A. enable Spanning Tree Protocol [SwitchD] stp enable

[Additional description]

(1) by default, the priority of a vswitch is 32768. If you want to manually specify a vswitch as the root switch, you can also modify the priority;

(2) After the Spanning Tree is enabled by default, the Spanning Tree Protocol is enabled for all ports. Change the port connected to the PC to the edge port mode;

(3) to control the status of a link, you can set the cost value of the port.

Test and verification

(1) view the stp running status of the switch using display STP

(2) check whether the display STP interface Ethernet XX is correct in the stp status of the port.

10. Maintenance of the Quidway Switch

Display System version: display version

Display diagnostic information: display diagnostic-information

Display current system configuration: display current-configuration

Display System save configuration: display saved-configuration

Display interface Information: display interface

Display route information: display ip routing-table

Display VLAN information: display vlan

Display spanning tree information: display stp

Display MAC address Table: display mac-address

Show ARP table information: display arp

Display System CPU usage: display cpu

Display System memory usage: display memory

Display System log: display log

Display system clock: display clock

After verifying that the configuration is correct, run the save configuration command: save

To delete a command, run the following command: undo.


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.