h3c s3600配置案例:
(网络环境是:划分vlan101到vlan104加vlan1 六个vlan,vlan1 的ip是
192.168.0.30/24,且在vlan1 中有一台dhcp 服务器(windows2003搭建),ip为192.168.0.10,其 他五个vlan分别为vlan 1 的子网,各个vlan间要求可以互通,其他vlan 共用vlan里的dhcp服务器 ,自动获得ip;另外这个环境中在交换机前面还有一台防火墙,防火墙和交换机相连的端口一定要配置 成trunk模式,并且一定的在防火墙上加四条静态路由,分别到达内部的四个vlan子网,网关为vlan1 的ip,防火墙的ip和vlan1在一个网段) <h3c-3600>display current-configuration #查看所有的配置信息
<h3c-3600>display version #查看版本信息
<h3c-3600>system-viem #进入系统视图
[h3c-3600]vlan 101 #创建vlan 101(批量创建:vlan 101 to 5)
[h3c-3600-vlan101]name testvlan #给vlan命名
[h3c-3600-vlan101]port e1/0/1 to e1/0/5 e1/0/7 e/1/011#批量把端口加入到vlan101
[h3c-3600-vlan101]quit
[h3c-3600]interface vlan-interface 101
[h3c-3600-vlan-interface101]ip address 192.168.2.1 255.255.255.192
[h3c-3600-vlan-interface101]quit
[h3c-3600]vlan 102
[h3c-3600-vlan102]name guanglivlan
[h3c-3600-vlan102]quit [h3c-3600]interface vlan-interface 102
[h3c-3600-vlan-interface102]ip address 192.168.2.65 255.255.255.192
[h3c-3600-vlan-interface102]quit
[h3c-3600]int e1/0/1
[h3c-3600-e1/0/1]port link-type trunk
[h3c-3600-e1/0/1]port trunk permit vlan all #允许所有vlan通过,否则只允许vlan 1 通过
。。。。。。。。。。。。。其他配置略。
配置DHCP Relay
本节主要介绍DHCP Server的配置,对于举例中的DHCP Relay设备配置,只进行最简单的介绍,保证
其可以将DHCP请求转发至DHCP Server。 <H3C> system-view
[H3C] dhcp-server 1 ip 192.168.0.10(dhcp服务器的ip)
[H3C] interface Vlan-interface 101
[H3C-Vlan-interface5] dhcp-server 1
[H3C] interface Vlan-interface 102
[H3C-Vlan-interface102] dhcp-server 1
.。。。。。。。。。。。。。。。。。。。。。
由于原来交换机的ios版本比较低,导致配到第三vlan时,配置好后测试拿不到ip ,甚至导致其他 vlan也获取不到ip,手动去配ip也不通到达vlan,最后按下面的方式升级ios版本,问题解决。 1.1 通过命令行远程升级
用户在本地计算机上运行FTP Server,注意配置了用户名和密码,以及正确的文件所在目录(假设IP
地址为10.10.110.1)。同时用户通过Telnet远程登录到交换机上,利用FTP将主机程序传送到交换机 上。 假设主机程序为SWITCH.bin,BOOTROM程序为SWITCH.btm。在用户通过Telnet远程登录到交换机上后,进行下列操作。
第一步:通过FTP将软件下载到交换机上。 <H3C> ftp 10.10.110.1
Trying ...
Press CTRL+K to abort
Connected.
220 WFTPD 2.0 service (by Texas Imperial Software) ready for new user
User(none):lyt
331 Give me your password, please
Password:
230 Logged in successfully
[ftp] get SWITCH.bin SWITCH.bin
[ftp] get SWITCH.btm SWITCH.btm
(如果空间不足,可以在系统模式下删除原来的ios,命令如下:
[h3c]delete flash:/SWITCH.bin
[ftp] bye
第二步,加载BOOTROM。
<H3C> boot bootrom SWITCH.btm
please wait ...
Bootrom is updated!
第三步,加载主机软件。
<H3C> boot boot-loader SWITCH.bin
<H3C> display boot-loader
The app to boot at the next time is: flash:/SWITCH.bin
<H3C> reboot(重启前请确认其他配置是否保存,防止重启后造成配置丢失)
通过以上操作即可完成BOOTROM和主机软件的加载。需要注意的是,加载主机软件必须通过reboot命令重起交换机才能使加载成功。如果 Flash memory空间不够,可以首先完成BOOTROM的加载,然后删除flash中的部分程序文件(建议删除已不使用的某主机程序),再将加载用的主机程序 通过FTP上载到交换机来完成主机程序的加载。注意,在加载过程中不可断电。
注意:如果Flash memory空间不够,可以首先完成BOOTROM的升级,然后再将主机程序通过FTP上载到交换机上完成主机程序的升级。
s3600上的具体配置信息: <H3C3600> <H3C3600>dis cu # sysname H3C3600 # dhcp-server 1 ip 192.168.0.10 # radius scheme system # domain system # local-user admin password simple shineit service-type telnet level 3 # acl number 2000 rule 1 permit # vlan 1 # vlan 101 to 104 # interface Vlan-interface1 ip address 192.168.0.30 255.255.255.0 # interface Vlan-interface101 ip address 192.168.2.1 255.255.255.192 dhcp-server 1 # interface Vlan-interface102 ip address 192.168.2.65 255.255.255.192 <H3C3600>dis cu
# sysname H3C3600 # dhcp-server 1 ip 192.168.0.10 # radius scheme system # domain system # local-user admin password simple shineit service-type telnet level 3 # acl number 2000 rule 1 permit # vlan 1 # vlan 101 to 104 # interface Vlan-interface1 ip address 192.168.0.30 255.255.255.0 # interface Vlan-interface101 ip address 192.168.2.1 255.255.255.192 dhcp-server 1 # interface Vlan-interface102 ip address 192.168.2.65 255.255.255.192 dhcp-server 1 # interface Vlan-interface103 ip address 192.168.2.129 255.255.255.192 dhcp-server 1 # interface Vlan-interface104 ip address 192.168.2.193 255.255.255.192 dhcp-server 1 # interface Aux1/0/0 # interface Ethernet1/0/1 port access vlan 103 # interface Ethernet1/0/2 port access vlan 102 # interface Ethernet1/0/3 # interface Ethernet1/0/4 port access vlan 101 # interface Ethernet1/0/5 # interface Ethernet1/0/6 port access vlan 104 # interface Ethernet1/0/7 # interface Ethernet1/0/8 # interface Ethernet1/0/9 # interface Ethernet1/0/10 # interface Eth # interface Ethernet1/0/12 # interface Ethernet1/0/13 # interface Ethernet1/0/14 # interface Ethernet1/0/15 # interface Ethernet1/0/16 # interface Ethernet1/0/17 # interface Ethernet1/0/18 # interface Ethernet1/0/19 port link-type trunk port trunk permit vlan all # interface Ethernet1/0/20 # interface Ethernet1/0/21 # interface Ethernet1/0/22 port link-type trunk port trunk permit vlan all # interface Ethernet1/0/23 port link-type trunk port trunk permit vlan all # interface Ethernet1/0/24 port link-type trunk port trunk permit vlan all # interface GigabitEthernet1/1/1 # interface GigabitEthernet1/1/2 # interface GigabitEthernet1/1/3 port link-type trunk port trunk permit vlan all # interface GigabitEthernet1/1/4 # undo irf-fabric authentication-mode # interface NULL0 # telnet source-interface Vlan-interface1 # voice vlan mac-address 0001-e300-0000 mask ffff-ff00-0000 # ip route-static 0.0.0.0 0.0.0.0 192.168.0.1 preference 60 # telnet-server source-interface Vlan-interface1 # user-interface aux 0 7 user-interface vty acl 2000 inbound user privilege level 3 set authentication password simple shineit history-command max-size 20 screen-length 30 protocol inbound telnet user-interface vty 1 4 acl 2000 inbound # return <H3C3600>dis ver H3C Comware Platform Software Comware Software, Version 3.10, Release 1602P10 #(升级后的版本) Copyright (c) 2004-2008 Hangzhou H3C Technologies Co., Ltd. All rights reserved. H3C S3600-28TP-SI uptime is 0 week, 0 day, 1 hour, 8 minutes
H3C S3600-28TP-SI with 1 Processor
64M bytes DRAM 8196K bytes Flash Memory Config Register points to FLASH Hardware Version is REV.B
CPLD Version is CPLD 003 Bootrom Version is 514 [Subslot 0] 24 FE Hardware Version is REV.B [Subslot 1] 4 GE Hardware Version is REV.B <H3C3600>
|