華爲 —小型企業多交換機多VLAN通信簡單實驗

多交換機VLAN間通信

一、實驗目的

實現多交換機不同VLAN間通信,並實現全網互通。

 

二、實驗環境

Windows 10

eNSP

 

三、實驗拓撲

111.png


四、實驗步驟

PC配置IP地址的步驟就不進行展示了。

SW1

         <Huawei>sys

         [Huawei]sys SW1

         [SW1]vl ba 10 20 30

         [SW1]int eth0/0/1

         [SW1-Ethernet0/0/1]un shu

         [SW1-Ethernet0/0/1]po link-t ac

         [SW1-Ethernet0/0/1]po de vl 10

               [SW1-Ethernet0/0/1]int eth 0/0/2

               [SW1-Ethernet0/0/2]un shu

               [SW1-Ethernet0/0/2]po link-t ac

               [SW1-Ethernet0/0/2]po de vl 20

               [SW1-Ethernet0/0/2]int eth 0/0/3

               [SW1-Ethernet0/0/3]un shu

               [SW1-Ethernet0/0/3]po link-t ac

               [SW1-Ethernet0/0/3]po de vl 30

               [SW1-Ethernet0/0/3]int eth 0/0/22

               [SW1-Ethernet0/0/22]po link-t tr

               [SW1-Ethernet0/0/22]po tr all vl all

 

         SW2

         <Huawei>sys

         [Huawei]sys SW2

         [SW2]vl ba 40 50

         [SW2]int eth0/0/1

         [SW2-Ethernet0/0/1]un shu

         [SW2-Ethernet0/0/1]po link-t ac

         [SW2-Ethernet0/0/1]po de vl 40

               [SW2-Ethernet0/0/1]int eth 0/0/2

               [SW2-Ethernet0/0/2]un shu

               [SW2-Ethernet0/0/2]po link-t ac

               [SW2-Ethernet0/0/2]po de vl 50

               [SW2-Ethernet0/0/2]int eth 0/0/22

               [SW2-Ethernet0/0/22]po link-t tr

               [SW2-Ethernet0/0/22]po tr all vl all

 

         LSW1:

                   <Huawei>sys

                   [Huawei]sys LSW1

                   [LSW1]vl ba 10 20 30 40 50 60

                   [LSW1]int g0/0/1

                   [LSW1-GigabitEthernet0/0/1]un shu

                   [LSW1-GigabitEthernet0/0/1]po link-t tr

                   [LSW1-GigabitEthernet0/0/1]po tr all vl all

                   [LSW1-GigabitEthernet0/0/1]int g0/0/2

                   [LSW1-GigabitEthernet0/0/2]un shu

                   [LSW1-GigabitEthernet0/0/2]po link-t tr

                   [LSW1-GigabitEthernet0/0/2]po tr all vl all

                   [LSW1-GigabitEthernet0/0/2]int g0/0/24

                   [LSW1-GigabitEthernet0/0/24]po link-t acc

                   [LSW1-GigabitEthernet0/0/24]po de vl 60

                   [LSW1-GigabitEthernet0/0/24]int vl 10

                   [LSW1-Vlanif10]un shu

[LSW1-Vlanif10]ip add 192.168.10.254 255.255.255.0

                   [LSW1-Vlanif10]int vl 20

                   [LSW1-Vlanif20]un shu

                   [LSW1-Vlanif20]ip add 192.168.20.254 255.255.255.0

                   [LSW1-Vlanif20]int vl 30

                   [LSW1-Vlanif30]un shu

                   [LSW1-Vlanif30]ip add 192.168.30.254 255.255.255.0

                   [LSW1-Vlanif30]int vl 40

                   [LSW1-Vlanif40]un shu

                   [LSW1-Vlanif40]ip add 192.168.40.254 255.255.255.0

                   [LSW1-Vlanif40]int vl 50

                   [LSW1-Vlanif50]un shu

                   [LSW1-Vlanif50]ip add 192.168.50.254255.255.255.0

                   [LSW1-Vlanif50]int vl 60

                   [LSW1-Vlanif60]un shu

                   [LSW1-Vlanif60]ip add 192.168.60.2 255.255.255.0

                   [LSW1-Vlanif60]quit

                   [LSW1]ip route-static 192.168.70.0 255.255.255.0 192.168.60.1

 

         R1:

            <Huawei>sys

            [Huawei]sys R1

            [R1]int g0/0/1

            [R1- GigabitEthernet0/0/1]un shu

[R1- GigabitEthernet0/0/1]ip add 192.168.60.1 255.255.255.0

[R1- GigabitEthernet0/0/1]int g0/0/0

[R1- GigabitEthernet0/0/0]un shu

[R1- GigabitEthernet0/0/0]ip add 192.168.70.254 255.255.255.0

[R1- GigabitEthernet0/0/0]quit

[R1]ip route-static 0.0.0.0 0.0.0.0 192.168.6.2

五、結果驗證

測試PC1與其他全部PC的連通性

1112.png

1113.png


發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章