【实验】华三( H3C )交换机 VLAN 和 TRUNK 实验

如需注册 @ccie.engineer、@ccde.engineer、@ccar.engineer、@hcie.engineer、@rhce.engineer 和 @cissp.engineer 邮箱,请点击这里
更多有关于 “ H3C 实验 ” 的文章,请点击这里

实验环境:

操作系统:Windows 7 专业版(当时最新正式版),模拟器:HCL 2.1.1(当时最新版本)

  • 路由器的型号是:H3C MSR36-20
  • 交换机的型号是:H3C S5820V2-54QS-GE
华三(H3C)交换机 VLAN 和 TRUNK 实验
华三( H3C )交换机 VLAN 和 TRUNK 实验

实验需求:

  • PC1 和 PC2 实际是两台路由器,使用路由器来模拟 PC ;
  • 根据上图,在 PC1 和 PC2 的相应接口上配置相应的 IP 地址;
  • 根据上图,在 SW1 和 SW2 的相应接口上配置 TRUNK 口,并划分 VLAN10 ;
  • 最后,PC1 和 PC2 之间能相互 ping 通。

实验步骤:

本实验主要涉及到的命令是:IPv4 地址的配置、配置 TRUNK 口并划分 VLAN ,跟思科的命令大同小异,在此不做过多的描述。

PC1:

system-view
hostname PC1

int g 0/2
ip add 10.0.0.1 255.255.255.0
shutdown
undo shutdown
PC2:

system-view
hostname PC2

int g 0/2
ip add 10.0.0.2 255.255.255.0
shutdown
undo shutdown
SW1:

system-view
hostname SW1

vlan 10
port GigabitEthernet 1/0/2

int g 1/0/1
port link-type trunk
port trunk permit vlan 10
SW2:

system-view
hostname SW2

vlan 10
port GigabitEthernet 1/0/2

int g 1/0/1
port link-type trunk
port trunk permit vlan 10

如需清理 H3C 设备的配置,可使用如下命令:

<H3C>reset saved-configuration
The saved configuration file will be erased. Are you sure? [Y/N]:Y
Configuration file in flash: is being cleared.
Please wait ...
MainBoard:
Configuration file is cleared.
<H3C>
<H3C>reboot
Start to check configuration with next startup configuration file, please wait.........DONE!
Current configuration may be lost after the reboot, save current configuration? [Y/N]:N
This command will reboot the device. Continue? [Y/N]:Y
Now rebooting, please wait...

测试:

[PC1]ping 10.0.0.2
Ping 10.0.0.2 (10.0.0.2): 56 data bytes, press CTRL_C to break
56 bytes from 10.0.0.2: icmp_seq=0 ttl=255 time=6.000 ms
56 bytes from 10.0.0.2: icmp_seq=1 ttl=255 time=2.000 ms
56 bytes from 10.0.0.2: icmp_seq=2 ttl=255 time=3.000 ms
56 bytes from 10.0.0.2: icmp_seq=3 ttl=255 time=2.000 ms
56 bytes from 10.0.0.2: icmp_seq=4 ttl=255 time=2.000 ms

--- Ping statistics for 10.0.0.2 ---
5 packet(s) transmitted, 5 packet(s) received, 0.0% packet loss
round-trip min/avg/max/std-dev = 2.000/3.000/6.000/1.549 ms
[PC1]%May 22 16:01:14:029 2019 PC1 PING/6/PING_STATISTICS: Ping statistics for 10.0.0.2: 5 packet(s) transmitted, 5 packet(s) received, 0.0% packet loss, round-trip min/avg/max/std-dev = 2.000/3.000/6.000/1.549 ms.

[PC1]
[PC2]ping 10.0.0.1
Ping 10.0.0.1 (10.0.0.1): 56 data bytes, press CTRL_C to break
56 bytes from 10.0.0.1: icmp_seq=0 ttl=255 time=5.000 ms
56 bytes from 10.0.0.1: icmp_seq=1 ttl=255 time=9.000 ms
56 bytes from 10.0.0.1: icmp_seq=2 ttl=255 time=1.000 ms
56 bytes from 10.0.0.1: icmp_seq=3 ttl=255 time=2.000 ms
56 bytes from 10.0.0.1: icmp_seq=4 ttl=255 time=2.000 ms

--- Ping statistics for 10.0.0.1 ---
5 packet(s) transmitted, 5 packet(s) received, 0.0% packet loss
round-trip min/avg/max/std-dev = 1.000/3.800/9.000/2.926 ms
[PC2]%May 22 16:01:03:412 2019 PC2 PING/6/PING_STATISTICS: Ping statistics for 10.0.0.1: 5 packet(s) transmitted, 5 packet(s) received, 0.0% packet loss, round-trip min/avg/max/std-dev = 1.000/3.800/9.000/2.926 ms.

[PC2]

 

本文完。如有疑问,欢迎在下方留言;如本文有什么错误,欢迎在下方留言指正,谢谢。

打赏 赞(0)
比特币钱包
以太坊钱包
比特币钱包二维码图片

比特币钱包扫描二维码打赏

以太坊钱包二维码图片

以太坊钱包扫描二维码打赏

Was this article helpful?

Leave A Comment?

此站点使用Akismet来减少垃圾评论。了解我们如何处理您的评论数据