0% found this document useful (0 votes)
97 views10 pages

VLAN Configuration Guide

The document discusses configuring VLANs and trunk ports on Huawei switches. It provides configuration commands to: 1) Create VLANs 10 and 20 on switches SW1 and SW2; 2) Configure ports 1, 3 and 10 as access and trunk ports respectively, assigning them to the appropriate VLANs; 3) Verify the VLAN configuration using the "display vlan" command. The trunk port is configured to allow both VLANs 10 and 20, tagging VLAN 20 frames. This establishes connectivity between the VLANs on the different switches.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
97 views10 pages

VLAN Configuration Guide

The document discusses configuring VLANs and trunk ports on Huawei switches. It provides configuration commands to: 1) Create VLANs 10 and 20 on switches SW1 and SW2; 2) Configure ports 1, 3 and 10 as access and trunk ports respectively, assigning them to the appropriate VLANs; 3) Verify the VLAN configuration using the "display vlan" command. The trunk port is configured to allow both VLANs 10 and 20, tagging VLAN 20 frames. This establishes connectivity between the VLANs on the different switches.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 10

Instalação com quatro pacotes

Pacotes para instalar o eNSP (são necessários os quatro pacotes). Observar a versão do
VirtualBox.

eNSP
VirtualBox 5.2.44-139111-Win (observar a versão)
WinPcap_4_1_3
Wireshark

No Youtube - ver o Prof. Moacyr Regys - CEFET Ceará

Portas de acesso removem os tags.

Modo usuário e modo de configuração

Fase atual

Modo usuário para modo configuração.


Criação da VLAN 20 e da VLAN 10
COMANDOS no LSW1

<Huawei>
<Huawei>sys
Enter system view, return user view with Ctrl+Z.
[Huawei]sysname SW1
[SW1]
[SW1]vlan 20
[SW1-vlan20]
[SW1-vlan20]q
[SW1]vlan 10
[SW1-vlan10]
[SW1-vlan10]
disp vlan
The total number of vlans is : 3
--------------------------------------------------------------------------------
U: Up; D: Down; TG: Tagged; UT: Untagged;
MP: Vlan-mapping; ST: Vlan-stacking;
#: ProtocolTransparent-vlan; *: Management-vlan;
--------------------------------------------------------------------------------

VID Type Ports


--------------------------------------------------------------------------------
1 common UT:GE0/0/1(U) GE0/0/2(U) GE0/0/3(D) GE0/0/4(D)
GE0/0/5(D) GE0/0/6(D) GE0/0/7(D) GE0/0/8(D)
GE0/0/9(D) GE0/0/10(D) GE0/0/11(D) GE0/0/12(D)
GE0/0/13(D) GE0/0/14(D) GE0/0/15(D) GE0/0/16(D)
GE0/0/17(D) GE0/0/18(D) GE0/0/19(D) GE0/0/20(D)
GE0/0/21(D) GE0/0/22(D) GE0/0/23(D) GE0/0/24(D)

20 common
10 common

VID Status Property MAC-LRN Statistics Description


--------------------------------------------------------------------------------
1 enable default enable disable VLAN 0001
2 enable default enable disable VLAN 0020
10 enable default enable disable VLAN 0010
[SW1-vlan10]
[SW1-vlan10]q
[SW1]interface g0/0/1
[SW1-GigabitEthernet0/0/1]port link-type access
[SW1-GigabitEthernet0/0/1]port default vlan 10
[SW1-GigabitEthernet0/0/1]q
[SW1-GigabitEthernet0/0/3] port link-type access
[SW1-GigabitEthernet0/0/3]port default vlan 10
[SW1-GigabitEthernet0/0/3]q
[SW1]int g0/0/2
[SW1-GigabitEthernet0/0/2]port link-type access
[SW1-GigabitEthernet0/0/2]port default vlan 20

TESTES a partir do PC1 - command line no PC1


Welcome to use PC Simulator!

PC>ping 192.168.10.3

Ping 192.168.10.3: 32 data bytes, Press Ctrl_C to break


From 192.168.10.3: bytes=32 seq=1 ttl=128 time=62 ms
From 192.168.10.3: bytes=32 seq=2 ttl=128 time=47 ms
From 192.168.10.3: bytes=32 seq=3 ttl=128 time=47 ms
From 192.168.10.3: bytes=32 seq=4 ttl=128 time=47 ms
From 192.168.10.3: bytes=32 seq=5 ttl=128 time=63 ms

--- 192.168.10.3 ping statistics ---


5 packet(s) transmitted
5 packet(s) received
0.00% packet loss

round-trip min/avg/max = 47/53/63 ms

PC>ping 192.168.10.2

Ping 192.168.10.2: 32 data bytes, Press Ctrl_C to break


From 192.168.10.1: Destination host unreachable
From 192.168.10.1: Destination host unreachable
From 192.168.10.1: Destination host unreachable
From 192.168.10.1: Destination host unreachable
From 192.168.10.1: Destination host unreachable

--- 192.168.10.2 ping statistics ---


5 packet(s) transmitted
0 packet(s) received
100.00% packet loss

NOSSA PRÁTICA - Primeira Configuração - VLAN (portas access)

PROGRAMAÇÂO DA PRIMEIRA CONFIGURAÇÃO

<Huawei>
<Huawei>system-view
[Huawei]sysname SWA
[SWA]vlan batch 10 20
[SWA-GigabitEthernet0/0/1]port link-type access
[SWA-GigabitEthernet0/0/1]port default vlan 10
[SWA-GigabitEthernet0/0/1]int g0/0/2
[SWA-GigabitEthernet0/0/2]port link-type access
[SWA-GigabitEthernet0/0/2]port default vlan 20
int g0/0/3
[SWA-GigabitEthernet0/0/3]port link-type access
[SWA-GigabitEthernet0/0/3]port default vlan 10
int g0/0/4
[SWA-GigabitEthernet0/0/4]port link-type access
[SWA-GigabitEthernet0/0/4]port default vlan 10

[SWA-GigabitEthernet0/0/4]display vlan

The total number of vlans is : 3


--------------------------------------------------------------------------------
U: Up; D: Down; TG: Tagged; UT: Untagged;
MP: Vlan-mapping; ST: Vlan-stacking;
#: ProtocolTransparent-vlan; *: Management-vlan;
--------------------------------------------------------------------------------

VID Type Ports


--------------------------------------------------------------------------------
1 common UT:GE0/0/5(D) GE0/0/6(D) GE0/0/7(D) GE0/0/8(D)
GE0/0/9(D) GE0/0/10(D) GE0/0/11(D) GE0/0/12(D)
GE0/0/13(D) GE0/0/14(D) GE0/0/15(D) GE0/0/16(D)
GE0/0/17(D) GE0/0/18(D) GE0/0/19(D) GE0/0/20(D)
GE0/0/21(D) GE0/0/22(D) GE0/0/23(D) GE0/0/24(D)

10 common UT:GE0/0/1(U) GE0/0/3(U)


20 common UT:GE0/0/2(U) GE0/0/4(U)

VID Status Property MAC-LRN Statistics Description


--------------------------------------------------------------------------------
1 enable default enable disable VLAN 0001
10 enable default enable disable VLAN 0010
20 enable default enable disable VLAN 0020
[SWA-GigabitEthernet0/0/4]

VLAN no Huawei Packet Tracer (portas access e trunk)

Broadcast em uma LAN

Dois domínios de broadcast diferentes com VLAN no nível de enlace (Data Link Layer)
Um frame com Tag é adicionado para marcar a VLAN
Há dois tipos de links (Tronco e Acesso). Acesso: dispositivos finais para os switches. Tronco:
entre Switches (VLANs diferentes). Huawei tem porta híbrida.

Próxima configuração - Broadcast em VLAN


SW1
<Huawei>
<Huawei>system-view
[Huawei]sysname SW1
[SW1]vlan 10
[SW1-vlan10]q
[SW1]vlan 20
[SW1-vlan20]q
[SW1]int g0/0/1
[SW1-GigabitEthernet0/0/1]port link-type access
[SW1-GigabitEthernet0/0/1]port default vlan 10
[SW1-GigabitEthernet0/0/1]q
[SW1]int g0/0/3
[SW1-GigabitEthernet0/0/3]port link-type access
[SW1-GigabitEthernet0/0/3]port default vlan 20
[SW1-GigabitEthernet0/0/3]q
[SW1]int g0/0/10
[SW1-GigabitEthernet0/0/10]port link-type trunk
[SW1-GigabitEthernet0/0/10]port trunk pvid vlan 10
[SW1-GigabitEthernet0/0/10]port trunk allow-pass vlan 10 20
display vlan
The total number of vlans is : 3
--------------------------------------------------------------------------------
U: Up; D: Down; TG: Tagged; UT: Untagged;
MP: Vlan-mapping; ST: Vlan-stacking;
#: ProtocolTransparent-vlan; *: Management-vlan;
--------------------------------------------------------------------------------

VID Type Ports


--------------------------------------------------------------------------------
1 common UT:GE0/0/2(D) GE0/0/4(D) GE0/0/5(D) GE0/0/6(D)
GE0/0/7(D) GE0/0/8(D) GE0/0/9(D) GE0/0/11(D)
GE0/0/12(D) GE0/0/13(D) GE0/0/14(D) GE0/0/15(D)
GE0/0/16(D) GE0/0/17(D) GE0/0/18(D) GE0/0/19(D)
GE0/0/20(D) GE0/0/21(D) GE0/0/22(D) GE0/0/23(D)
GE0/0/24(D)
TG:GE0/0/10(U)

10 common UT:GE0/0/1(U) GE0/0/10(U)


20 common UT:GE0/0/3(U)
TG:GE0/0/10(U)
VID Status Property MAC-LRN Statistics Description
--------------------------------------------------------------------------------
1 enable default enable disable VLAN 0001
10 enable default enable disable VLAN 0010
20 enable default enable disable VLAN 0020

Notar que o caminho trunk PVID 10 foi alocado para a vlan 10 (untagged, UT) e o
caminho para a vlan 20 foi colocado pelo comando [SW1-GigabitEthernet0/0/10]port
trunk allow-pass vlan 10 20 e marcado como tagged, T.

SW2
<Huawei>
<Huawei>system-view
[Huawei]sysname SW2
[SW2]vlan batch 10 20 int g0/0/1
[SW2]int g0/0/1
[SW2-GigabitEthernet0/0/1]port link-type access
[SW2-GigabitEthernet0/0/1]port default vlan 10
[SW2]int g0/0/3
[SW2-GigabitEthernet0/0/3]port link-type access
[SW2-GigabitEthernet0/0/3]port default vlan 20
[SW2-GigabitEthernet0/0/1]q
[SW2]int g0/0/10
[SW2]int g0/0/10
[SW2-GigabitEthernet0/0/10]port link-type trunk
[SW2-GigabitEthernet0/0/10]port trunk pvid vlan 10
[SW2-GigabitEthernet0/0/10]port trunk allow-pass vlan 10 20
display vlan
The total number of vlans is : 3
--------------------------------------------------------------------------------
U: Up; D: Down; TG: Tagged; UT: Untagged;
MP: Vlan-mapping; ST: Vlan-stacking;
#: ProtocolTransparent-vlan; *: Management-vlan;
--------------------------------------------------------------------------------

VID Type Ports


--------------------------------------------------------------------------------
1 common UT:GE0/0/2(D) GE0/0/4(D) GE0/0/5(D) GE0/0/6(D)
GE0/0/7(D) GE0/0/8(D) GE0/0/9(D) GE0/0/11(D)
GE0/0/12(D) GE0/0/13(D) GE0/0/14(D) GE0/0/15(D)
GE0/0/16(D) GE0/0/17(D) GE0/0/18(D) GE0/0/19(D)
GE0/0/20(D) GE0/0/21(D) GE0/0/22(D) GE0/0/23(D)
GE0/0/24(D)
TG:GE0/0/10(U)

10 common UT:GE0/0/1(U) GE0/0/10(U)


20 common UT:GE0/0/3(U)
TG:GE0/0/10(U)

VID Status Property MAC-LRN Statistics Description


--------------------------------------------------------------------------------
1 enable default enable disable VLAN 0001
10 enable default enable disable VLAN 0010
20 enable default enable disable VLAN 0020

Notar que o caminho trunk PVID 10 foi alocado para a vlan 10 (untagged, UT) e o
caminho para a vlan 20 foi colocado pelo comando [SW2-GigabitEthernet0/0/10]port
trunk allow-pass vlan 10 20 e marcado como tagged, T.

Programação dos PCs

A figura a seguir mostra a programação do primeiro PC, com o IPv4 estático


(Basic Config).
Ping do PC1 no PC4 (que tem o endereço 192.168.10.2)

Monitoramento no Wireshark, no link g0/0/10

Resultado do Wireshark ao ping 192.168.10.1 para 192.168.10.2 (no final o código


hexadecimal correspondente). Observar o nível três (pacote ICMP) e os frames em
hexadecimal (abaixo). Notar a primeira coluna que mostra o número dos pacotes e
a segunda coluna que mostra o tempo entre a geração de cada pacote.

You might also like