[All About Switches] 14 VLAN Assignment Highlighted

Latest reply: Aug 12, 2018 06:16:43 7717 5 1 0

[All About Switches] 14 VLAN Assignment-1335171-1VLAN assignment modes:

?  Port-based VLAN assignment: VLAN IDs are assigned based on switch ports. The configuration is simple, and this mode applies to various scenarios.

?  MAC address-based VLAN assignment: VLAN IDs are assigned based on source MAC addresses of packets. This mode applies to scenarios where users' positions change frequently.

?  IP subnet-based VLAN assignment: VLAN IDs are assigned based on source IP addresses of packets. This mode applies to scenarios where hosts on the same network segment are managed uniformly.

?  Protocol-based VLAN assignment: VLAN IDs are assigned based on protocol types of packets. This mode applies to scenarios where hosts with the same applications or services are managed uniformly.

?  Policy-based VLAN assignment: VLAN IDs are assigned based on policies such as source MAC addresses, source IP addresses, and port number of packets. This mode applies to scenarios demanding high security.

[All About Switches] 14 VLAN Assignment-1335171-2Among the preceding VLAN assignment modes, port-based VLAN assignment is often used and its configuration is the most simplest. How do we configure and use this mode?

Before configure port-based VLAN assignment, let's review common link types of ports.

Access port: connects a switch to a PC.

Trunk port: connects switches.

Hybrid port: connects a switch to a PC or connects switches. The hybrid port is often used when a switch connects to a PC through a hub or switches are connected through a hub.

Let's move to port-based VLAN assignment configuration.

[All About Switches] 14 VLAN Assignment-1335171-3Scenario 1: Two PCs connect to a switch. How the hosts are isolated using port-based VLAN assignment?

[All About Switches] 14 VLAN Assignment-1335171-4

?  Check whether the two PCs on the same network segment can be pinged successfully when the two PCs directly connect to the switch and no VLAN is assigned. [All About Switches] 14 VLAN Assignment-1335171-5

The ping operation is successful. Why?

By default, ports on a Huawei switch join VLAN 1. As long as the two PCs connected to the switch belong to the same network segment, the two PCs can communicate.

?  How are PCs isolated using VLAN assignment? Add ports to different VLANs. For example, GE0/0/1 and GE0/0/2 as access ports join VLAN 10 and VLAN 20 respectively.

[All About Switches] 14 VLAN Assignment-1335171-6

?  The two PCs in different VLANs cannot communicate with each other.

[All About Switches] 14 VLAN Assignment-1335171-7

[All About Switches] 14 VLAN Assignment-1335171-8Scenario 2: Four PCs connect to switches. How do we implement isolation and interworking of the PCs using port-based VLAN assignment?

By default, the four PCs belong to the same network segment and can be pinged mutually. Assume that PC1 and PC2 belong to the same department, and PC3 and PC4 belong to the same department. How do we implement interworking of the same department and between departments using port-based VLAN assignment?

[All About Switches] 14 VLAN Assignment-1335171-9

?  PC1 and PC2 of the same department are added to VLAN 100. GE0/0/1 ports on Switch 1 and Switch 2 join VLAN 100 as access ports.

[All About Switches] 14 VLAN Assignment-1335171-10

[All About Switches] 14 VLAN Assignment-1335171-11

?  PC3 and PC4 of the same department are added to VLAN 200.

[All About Switches] 14 VLAN Assignment-1335171-12

[All About Switches] 14 VLAN Assignment-1335171-13

?  GE0/0/3 ports on Switch 1 and Switch 2 join VLAN 200 as trunk ports.

[All About Switches] 14 VLAN Assignment-1335171-14

[All About Switches] 14 VLAN Assignment-1335171-15

?  PC1 and PC2 in the same department can communicate, and PC3 and PC4 in different departments cannot communicate.

 

[All About Switches] 14 VLAN Assignment-1335171-16

[All About Switches] 14 VLAN Assignment-1335171-17

 

[All About Switches] 14 VLAN Assignment-1335171-18In the preceding two scenarios, fewer VLANs and ports are configured. In practice, many VLANs and ports need to be configured. Which measure can be taken to complete the configuration rapidly? I will describe how to perform the configuration in a batch and rapidly restore the default VLAN configuration of ports?

1. Create VLANs in a batch.

< Huawei > system-view

[Huawei]vlan batch 2 to 100

2. Add ports to VLANs in a batch.

[Huawei] port-group group-member GigabitEthernet 0/0/10 to

GigabitEthernet 0/0/20

[Huawei-port-group]port link-type access

[Huawei-port-group]port default vlan 100

3. Rapidly restore the default VLAN configuration of ports.

What is the default VLAN configuration? All ports on Huawei switches join only VLAN 1 by default.

How is the default configuration of three ports rapidly restored?

?  Access port: Run the undo port default vlan command.

?  Trunk and hybrid ports:

Restore the default PVID, delete all VLANs from ports, and add ports to VLAN 1.

trunk

hybrid

undo port trunk pvid vlan
undo port trunk allow-pass vlan all
port trunk allow-pass vlan 1

undo port hybrid pvid vlan
undo port hybrid vlan all
port hybrid untagged vlan 1

 

This issue describes VLAN assignment. For more information about VLAN technology, see the next issue.

To be continued...

[All About Switches] 14 VLAN Assignment-1335171-19

Name

Description

[All About Switches - Beginner] VLAN Basics

This issue describes the definition and purpose of VLAN technology and modes in which interfaces are added to VLANs.

[All About Switches - Beginner] VLAN Assignment

This issue describes VLAN assignment modes and applicable scenarios, and mainly describes the configuration and scenario of interface-based assignment.

[All About Switches - Beginner] VLAN Communication

This issue describes main technologies and applicable scenarios of inter-VLAN communication, including the VLANIF interface, sub-interface, and super-VLAN. This issue also describes common VLANIF configuration.

[All About Switches - Beginner]

VLAN Isolation

This issue describes main technologies and applicable scenarios of VLAN isolation, such as MUX VLAN and ACL.

★★★Summary★★★ All About Huawei Switch Features and Configurations

 

This article contains more resources

You need to log in to download or view. No account?Register

x
  • x
  • convention:

Created Aug 10, 2015 17:23:43 Helpful(0) Helpful(0)

good,studying
  • x
  • convention:

Created Jun 25, 2015 12:25:12 Helpful(0) Helpful(0)

Thank you.
  • x
  • convention:

Created Sep 7, 2016 16:05:09 Helpful(0) Helpful(0)

THANK YOU

  • x
  • convention:

Created Mar 8, 2017 00:31:35 Helpful(0) Helpful(0)

This is outstanding and am loving it!!! great work guys....:D:D
  • x
  • convention:

Created Aug 12, 2018 06:16:43 Helpful(0) Helpful(0)

*** offf Huawei switch configuration waste nothing make possible
  • x
  • convention:

Reply

Reply
You need to log in to reply to the post Login | Register

Notice: To protect the legitimate rights and interests of you, the community, and third parties, do not release content that may bring legal risks to all parties, including but are not limited to the following:
  • Politically sensitive content
  • Content concerning pornography, gambling, and drug abuse
  • Content that may disclose or infringe upon others ' commercial secrets, intellectual properties, including trade marks, copyrights, and patents, and personal privacy
Do not share your account and password with others. All operations performed using your account will be regarded as your own actions and all consequences arising therefrom will be borne by you. For details, see " Privacy."
If the attachment button is not available, update the Adobe Flash Player to the latest version!

Login and enjoy all the member benefits

Login
Fast reply Scroll to top