h3c web配置(H3C交换机配置)
不管是运维实施部署也好,还是网路工程师也好,交换机的配置可能是家常便饭,在工作中你是搞运维的,会配置交换机也是一个炫耀的加分项哦!下面我们就拿H3C的交换机配置,做一个介绍吧!主要讲解交换机的连接,登陆,配置vlan,划分网口access或者trunk,查看配置状态等!
准备工作:一、将交换机通过console线连接到笔记本电脑二、通过crt远程管理软件,远程连接
1、新建一个链接,协议选择为serial
2、端口和波特率分别为COM3和9600
3、点击完成,并且连接
4、按2下enter键即可连接到交换机了
一、进入系统配置视图
<itcloud-test-H3C>system-view
System View: return to User View with Ctrl Z.
二、显示vlan配置[itcloud-test-H3C]display vlan
total 23 VLAN exist(s). The following VLANs exist: 1(default), 10, 13-15, 21, 25, 30, 66, 68, 106, 108-110, 120-122, 124-125, 135, 222, 500-501,
三、创建vlan[itcloud-test-H3C]vlan 123
[itcloud-test-H3C-vlan123]quit
四、再次查看vlan是否创建成功[itcloud-test-H3C]display vlan
Total 24 VLAN exist(s). The following VLANs exist: 1(default), 10, 13-15, 21, 25, 30, 66, 68, 106, 108-110, 120-125, 135, 222, 500-501,
五、为网口划分vlan[itcloud-test-H3C]interface GigabitEthernet1/0/3
[itcloud-test-H3C-GigabitEthernet1/0/3]port link-type access
[itcloud-test-H3C-GigabitEthernet1/0/3]port access vlan 123
[itcloud-test-H3C-GigabitEthernet1/0/3]quit
六、查看vlan及网口配置[itcloud-test-H3C]display interface brief
The brief information of interface(s) under route mode: Link: ADM - administratively down; Stby - standby Protocol: (s) - spoofing Interface Link Protocol Main IP Description M-GE0/0/0 DOWN DOWN -- NULL0 UP UP(s) -- Vlan1 UP UP -- Vlan10 UP UP -- Vlan13 UP UP 10.10.13.201 Vlan21 UP UP -- Vlan25 UP UP 192.168.25.1 Vlan30 UP UP 192.168.30.1 Vlan110 UP UP 192.168.10.1 Vlan120 UP UP 192.168.20.254 Vlan121 UP UP 192.168.21.254 Vlan122 UP UP 192.168.22.254 Vlan124 UP UP 192.168.24.254 Vlan125 UP UP -- Vlan135 UP UP 192.168.35.254 Vlan222 UP UP 192.168.0.1 Vlan500 UP UP 1.1.1.1 Vlan501 UP UP 2.2.2.1 The brief information of interface(s) under bridge mode: Link: ADM - administratively down; Stby - standby Speed or Duplex: (a)/A - auto; H - half; F - full Type: A - access; T - trunk; H - hybrid Interface Link Speed Duplex Type PVID Description GE1/0/1 UP 1G(a) F(a) A 120 GE1/0/2 DOWN auto A A 120 GE1/0/3 UP 100M(a) F(a) A 123 GE1/0/4 UP 1G(a) F(a) A 120 GE1/0/5 DOWN auto A A 120 GE1/0/6 DOWN auto A A 120 GE1/0/7 UP 1G(a) F(a) A 120 GE1/0/8 UP 1G(a) F(a) A 120 GE1/0/9 UP 1G(a) F(a) A 123 GE1/0/10 UP 1G(a) F(a) A 120 GE1/0/11 UP 1G(a) F(a) A 123 GE1/0/12 UP 1G(a) F(a) A 120 GE1/0/13 DOWN auto A A 120 GE1/0/14 DOWN auto A A 120 GE1/0/15 UP 1G(a) F(a) A 123 GE1/0/16 DOWN auto A A 120 GE1/0/17 DOWN auto A A 120 GE1/0/18 DOWN auto A A 120 GE1/0/19 DOWN auto A A 120 GE1/0/20 DOWN auto A A 120 GE1/0/21 DOWN auto A A 120 GE1/0/22 DOWN auto A A 120 GE1/0/23 UP 1G(a) F(a) A 120 GE1/0/24 UP 1G(a) F(a) A 120 GE1/0/25 DOWN auto A A 120 GE1/0/26 DOWN auto A T 1 GE1/0/27 DOWN auto A T 1 GE1/0/28 DOWN auto A T 1 GE1/0/29 DOWN auto A T 1 GE1/0/30 DOWN auto A T 1 GE1/0/31 DOWN auto A T 1 GE1/0/32 DOWN auto A T 1 GE1/0/33 UP 1G(a) F(a) T 1 GE1/0/34 DOWN auto A T 1 GE1/0/35 UP 1G(a) F(a) T 1 GE1/0/36 DOWN auto A T 1 GE1/0/37 DOWN auto A T 1 GE1/0/38 DOWN auto A T 1 GE1/0/39 UP 1G(a) F(a) T 1 GE1/0/40 DOWN auto A T 1 GE1/0/41 DOWN auto A T 1 GE1/0/42 DOWN auto A T 1 GE1/0/43 DOWN auto A T 1 GE1/0/44 DOWN auto A A 1 GE1/0/45 DOWN auto A A 1 GE1/0/46 DOWN auto A A 1 GE1/0/47 UP 1G(a) F(a) T 1 GE1/0/48 DOWN auto A A 1 GE1/0/49 DOWN auto A A 1 GE1/0/50 DOWN auto A A 1 GE1/0/51 DOWN auto A A 1 GE1/0/52 DOWN auto A A 1 XGE1/0/53 DOWN auto A A 1 XGE1/0/54 DOWN auto A A 1 [itcloud-test-H3C]
七、为vlan配置ip[itcloud-test-H3C]interface Vlan-interface 123
[itcloud-test-H3C-Vlan-interface123] %May 9 09:35:22:786 2000 itcloud-test-H3C IFNET/3/LINK_UPDOWN: Vlan-interface123 link status is UP. %May 9 09:35:23:028 2000 itcloud-test-H3C IFNET/5/LINEPROTO_UPDOWN: Line protocol on the interface Vlan-interface123 is UP.
[itcloud-test-H3C-Vlan-interface123]ip address 192.168.23.254 255.255.255.0
[itcloud-test-H3C-Vlan-interface123]quit
八、验证是否配置成功[itcloud-test-H3C]display interface brief
The brief information of interface(s) under route mode: Link: ADM - administratively down; Stby - standby Protocol: (s) - spoofing Interface Link Protocol Main IP Description M-GE0/0/0 DOWN DOWN -- NULL0 UP UP(s) -- Vlan1 UP UP -- Vlan10 UP UP -- Vlan13 UP UP 10.10.13.201 Vlan21 UP UP -- Vlan25 UP UP 192.168.25.1 Vlan30 UP UP 192.168.30.1 Vlan110 UP UP 192.168.10.1 Vlan120 UP UP 192.168.20.254 Vlan121 UP UP 192.168.21.254 Vlan122 UP UP 192.168.22.254 Vlan123 UP UP 192.168.23.254 Vlan124 UP UP 192.168.24.254 Vlan125 UP UP -- Vlan135 UP UP 192.168.35.254 Vlan222 UP UP 192.168.0.1 Vlan500 UP UP 1.1.1.1 Vlan501 UP UP 2.2.2.1
九、查看某一个vlan的配置[itcloud-test-H3C]display vlan 123
VLAN ID: 123 VLAN Type: static Route Interface: configured IPv4 address: 192.168.23.254 IPv4 subnet mask: 255.255.255.0 Description: VLAN 0123 Name: vlan123 Tagged Ports: GigabitEthernet1/0/26 GigabitEthernet1/0/27 GigabitEthernet1/0/28 GigabitEthernet1/0/29 GigabitEthernet1/0/30 GigabitEthernet1/0/31 GigabitEthernet1/0/32 GigabitEthernet1/0/33 GigabitEthernet1/0/34 GigabitEthernet1/0/35 GigabitEthernet1/0/36 GigabitEthernet1/0/37 GigabitEthernet1/0/38 GigabitEthernet1/0/39 GigabitEthernet1/0/40 GigabitEthernet1/0/41 GigabitEthernet1/0/42 GigabitEthernet1/0/43 GigabitEthernet1/0/47 Untagged Ports: GigabitEthernet1/0/3 GigabitEthernet1/0/9 GigabitEthernet1/0/11 GigabitEthernet1/0/15 GigabitEthernet1/0/48 [itcloud-test-H3C]
十、删除网口的vlan[itcloud-test-H3C]interface GigabitEthernet1/0/48
[itcloud-test-H3C-GigabitEthernet1/0/48]undo port access vlan
[itcloud-test-H3C-GigabitEthernet1/0/46]quit
十一、验证网口的vlan是否删除成功[itcloud-test-H3C]display interface brief
The brief information of interface(s) under route mode: Link: ADM - administratively down; Stby - standby Protocol: (s) - spoofing Interface Link Protocol Main IP Description M-GE0/0/0 DOWN DOWN -- NULL0 UP UP(s) -- Vlan1 UP UP -- Vlan10 UP UP -- Vlan13 UP UP 10.10.13.201 Vlan21 UP UP -- Vlan25 UP UP 192.168.25.1 Vlan30 UP UP 192.168.30.1 Vlan110 UP UP 192.168.10.1 Vlan120 UP UP 192.168.20.254 Vlan121 UP UP 192.168.21.254 Vlan122 UP UP 192.168.22.254 Vlan123 UP UP 192.168.23.254 Vlan124 UP UP 192.168.24.254 Vlan125 UP UP -- Vlan135 UP UP 192.168.35.254 Vlan222 UP UP 192.168.0.1 Vlan500 UP UP 1.1.1.1 Vlan501 UP UP 2.2.2.1 The brief information of interface(s) under bridge mode: Link: ADM - administratively down; Stby - standby Speed or Duplex: (a)/A - auto; H - half; F - full Type: A - access; T - trunk; H - hybrid Interface Link Speed Duplex Type PVID Description GE1/0/1 UP 1G(a) F(a) A 120 GE1/0/2 DOWN auto A A 120 GE1/0/3 UP 1G(a) F(a) A 123 GE1/0/4 UP 1G(a) F(a) A 120 GE1/0/5 DOWN auto A A 120 GE1/0/6 DOWN auto A A 120 GE1/0/7 UP 1G(a) F(a) A 120 GE1/0/8 UP 1G(a) F(a) A 120 GE1/0/9 UP 1G(a) F(a) A 123 GE1/0/10 UP 1G(a) F(a) A 120 GE1/0/11 UP 1G(a) F(a) A 123 GE1/0/12 UP 1G(a) F(a) A 120 GE1/0/13 DOWN auto A A 120 GE1/0/14 DOWN auto A A 120 GE1/0/15 UP 1G(a) F(a) A 123 GE1/0/16 DOWN auto A A 120 GE1/0/17 DOWN auto A A 120 GE1/0/18 DOWN auto A A 120 GE1/0/19 DOWN auto A A 120 GE1/0/20 DOWN auto A A 120 GE1/0/21 DOWN auto A A 120 GE1/0/22 DOWN auto A A 120 GE1/0/23 UP 1G(a) F(a) A 120 GE1/0/24 UP 1G(a) F(a) A 120 GE1/0/25 DOWN auto A A 120 GE1/0/26 DOWN auto A T 1 GE1/0/27 DOWN auto A T 1 GE1/0/28 DOWN auto A T 1 GE1/0/29 DOWN auto A T 1 GE1/0/30 DOWN auto A T 1 GE1/0/31 DOWN auto A T 1 GE1/0/32 DOWN auto A T 1 GE1/0/33 UP 1G(a) F(a) T 1 GE1/0/34 DOWN auto A T 1 GE1/0/35 UP 1G(a) F(a) T 1 GE1/0/36 DOWN auto A T 1 GE1/0/37 DOWN auto A T 1 GE1/0/38 DOWN auto A T 1 GE1/0/39 UP 1G(a) F(a) T 1 GE1/0/40 DOWN auto A T 1 GE1/0/41 DOWN auto A T 1 GE1/0/42 DOWN auto A T 1 GE1/0/43 DOWN auto A T 1 GE1/0/44 DOWN auto A A 1 GE1/0/45 DOWN auto A A 1 GE1/0/46 DOWN auto A A 1 GE1/0/47 UP 1G(a) F(a) T 1 GE1/0/48 UP 1G(a) F(a) A 1 GE1/0/49 DOWN auto A A 1 GE1/0/50 DOWN auto A A 1 GE1/0/51 DOWN auto A A 1 GE1/0/52 DOWN auto A A 1 XGE1/0/53 DOWN auto A A 1 XGE1/0/54 DOWN auto A A 1 [itcloud-test-H3C]
十二、删除vlan[itcloud-test-H3C]undo vlan 140
十三、查看vlan是否删除[itcloud-test-H3C]display vlan
Total 24 VLAN exist(s). The following VLANs exist: 1(default), 10, 13-15, 21, 25, 30, 66, 68, 106, 108-110, 120-125, 135, 222, 500-501, [itcloud-test-H3C]
十四、将网口设置为trunk[itcloud-test-H3C]interface GigabitEthernet1/0/48
[itcloud-test-H3C-GigabitEthernet1/0/48]
[itcloud-test-H3C-GigabitEthernet1/0/48]port link-type trunk
[itcloud-test-H3C-GigabitEthernet1/0/48]
[itcloud-test-H3C-GigabitEthernet1/0/48]port trunk permit vlan 123
[itcloud-test-H3C-GigabitEthernet1/0/48]
[itcloud-test-H3C-GigabitEthernet1/0/48]port trunk permit vlan 124
[itcloud-test-H3C-GigabitEthernet1/0/48]quit
十五、查看网口配置[itcloud-test-H3C]display interface GigabitEthernet1/0/48
GigabitEthernet1/0/48 current state: UP IP Packet Frame Type: PKTFMT_ETHNT_2, Hardware Address: 70f9-6ddb-e626 Description: GigabitEthernet1/0/48 Interface Loopback is not set Media type is twisted pair Port hardware type is 1000_BASE_T 1000Mbps-speed mode, full-duplex mode Link speed type is autonegotiation, link duplex type is autonegotiation Flow-control is not enabled The Maximum Frame Length is 12288 Broadcast MAX-ratio: 100% Unicast MAX-ratio: 100% Multicast MAX-ratio: 100% Allow jumbo frame to pass PVID: 1 Mdi type: auto Port link-type: trunk VLAN passing : 1(default vlan), 123-124 VLAN permitted: 1(default vlan), 123-124 Trunk port encapsulation: IEEE 802.1q Port priority: 0 Last clearing of counters: Never Peak value of Input: 112 bytes/sec, at 2000-05-09 09:23:25 Peak value of Output: 944 bytes/sec, at 2000-05-09 09:25:35 Last 300 seconds input: 0 packets/sec 2 bytes/sec 0% Last 300 seconds output: 0 packets/sec 91 bytes/sec 0% Input (total): 1493 packets, 123621 bytes 157 unicasts, 1130 broadcasts, 206 multicasts, 0 pauses Input (normal): 1493 packets, - bytes 157 unicasts, 1130 broadcasts, 206 multicasts, 0 pauses Input: 0 input errors, 0 runts, 0 giants, 0 throttles 0 CRC, 0 frame, - overruns, 0 aborts - ignored, - parity errors Output (total): 11604 packets, 1028034 bytes 1780 unicasts, 4157 broadcasts, 5667 multicasts, 0 pauses Output (normal): 11604 packets, - bytes 1780 unicasts, 4157 broadcasts, 5667 multicasts, 0 pauses Output: 0 output errors, - underruns, - buffer failures 0 aborts, 0 deferred, 0 collisions, 0 late collisions 0 lost carrier, - no carrier [itcloud-test-H3C]
十六、显示设备上当前存在的Hybrid或Trunk端口:display port { hybrid | trunk }[itcloud-test-H3C]display port trunk
Interface PVID VLAN passing GE1/0/26 1 1, 10, 13-15, 21, 25, 30, 66, 68, 106, 108-110, 120-125, 135, 222, 500-501, GE1/0/27 1 1, 10, 13-15, 21, 25, 30, 66, 68, 106, 108-110, 120-125, 135, 222, 500-501, GE1/0/28 1 1, 10, 13-15, 21, 25, 30, 66, 68, 106, 108-110, 120-125, 135, 222, 500-501, GE1/0/29 1 1, 10, 13-15, 21, 25, 30, 66, 68, 106, 108-110, 120-125, 135, 222, 500-501, GE1/0/30 1 1, 10, 13-15, 21, 25, 30, 66, 68, 106, 108-110, 120-125, 135, 222, 500-501, GE1/0/31 1 1, 10, 13-15, 21, 25, 30, 66, 68, 106, 108-110, 120-125, 135, 222, 500-501, GE1/0/32 1 1, 10, 13-15, 21, 25, 30, 66, 68, 106, 108-110, 120-125, 135, 222, 500-501, GE1/0/33 1 1, 10, 13-15, 21, 25, 30, 66, 68, 106, 108-110, 120-125, 135, 222, 500-501, GE1/0/34 1 1, 10, 13-15, 21, 25, 30, 66, 68, 106, 108-110, 120-125, 135, 222, 500-501, GE1/0/35 1 1, 10, 13-15, 21, 25, 30, 66, 68, 106, 108-110, 120-125, 135, 222, 500-501, GE1/0/36 1 1, 10, 13-15, 21, 25, 30, 66, 68, 106, 108-110, 120-125, 135, 222, 500-501, GE1/0/37 1 1, 10, 13-15, 21, 25, 30, 66, 68, 106, 108-110, 120-125, 135, 222, 500-501, GE1/0/38 1 1, 10, 13-15, 21, 25, 30, 66, 68, 106, 108-110, 120-125, 135, 222, 500-501, GE1/0/39 1 1, 10, 13-15, 21, 25, 30, 66, 68, 106, 108-110, 120-125, 135, 222, 500-501, GE1/0/40 1 1, 10, 13-15, 21, 25, 30, 66, 68, 106, 108-110, 120-125, 135, 222, 500-501, GE1/0/41 1 1, 10, 13-15, 21, 25, 30, 66, 68, 106, 108-110, 120-125, 135, 222, 500-501, GE1/0/42 1 1, 10, 13-15, 21, 25, 30, 66, 68, 106, 108-110, 120-125, 135, 222, 500-501, GE1/0/43 1 1, 10, 13-15, 21, 25, 30, 66, 68, 106, 108-110, 120-125, 135, 222, 500-501, GE1/0/47 1 1, 10, 13-15, 21, 25, 30, 66, 68, 106, 108-110, 120-125, 135, 222, 500-501, GE1/0/48 1 1, 123-124, [itcloud-test-H3C]
,免责声明:本文仅代表文章作者的个人观点,与本站无关。其原创性、真实性以及文中陈述文字和内容未经本站证实,对本文以及其中全部或者部分内容文字的真实性、完整性和原创性本站不作任何保证或承诺,请读者仅作参考,并自行核实相关内容。文章投诉邮箱:anhduc.ph@yahoo.com