谢谢大神,想不明白。下面有H3C5500配置
爱快路由 192.168.0.1/24 (LAN1口)接H3C5500 43口 三层IP192.168.0.2/24 VLAN7下的电脑能自动获取IP能正常上网,但设置固定IP就无法上网,也不能PING能VLAN下的网关。
设置列表
对齐方式
Xshell 6 (Build 0197)
Copyright (c) 2002 NetSarang Computer, Inc. All rights reserved.
Type `help' to learn how to use Xshell prompt.
[C:\~]$
Connecting to 192.168.0.2:23...
Connection established.
To escape to local shell, press 'Ctrl+Alt+]'.
******************************************************************************
* Copyright (c) 2004-2013 Hangzhou H3C Tech. Co., Ltd. All rights reserved. *
* Without the owner's prior written consent, *
* no decompiling or reverse-engineering shall be allowed. *
******************************************************************************
Login authentication
Username:admin
Password:
<H3C_FXL>system-view
System View: return to User View with Ctrl+Z.
[H3C_FXL]dis cu
#
version 5.20, Release 5206
#
sysname H3C_FXL
#
super password level 3 cipher $c$3$eVzsgTOdseiP/eiindMA+oKPUXWinxZwxltibEs=
#
dhcp relay server-group 1 ip 192.168.0.1
#
irf mac-address persistent timer
irf auto-update enable
undo irf link-delay
#
domain default enable system
#
telnet server enable
#
mvrp global enable
#
password-recovery enable
#
vlan 1
#
vlan 6
description VLAN 0006bangong
#
vlan 7
description VLAN 0007menjin
#
vlan 8
description VLAN 0008jiankong
#
vlan 9
description VLAN 0009sushe
#
vlan 10
description VLAN 0010fuwu
#
vlan 172
description VLAN 0172zhiji
#
domain system
access-limit disable
state active
idle-cut disable
self-service-url disable
#
dhcp server ip-pool vlan6
network 192.168.6.0 mask 255.255.255.0
gateway-list 192.168.6.1
dns-list 114.114.114.114
#
user-group system
group-attribute allow-guest
#
local-user admin
password cipher $c$3$zQ37qV1f1GtDwnYgweVRJLoBVNTnn00UJ43zRR8=
authorization-attribute level 3
service-type telnet terminal
service-type web
#
user-profile privilege
#
interface NULL0
#
interface Vlan-interface1
ip address 192.168.0.2 255.255.255.0
undo dhcp select server global-pool
#
interface Vlan-interface6
ip address 192.168.6.1 255.255.255.0
#
interface Vlan-interface7
ip address 192.168.7.1 255.255.255.0
dhcp select relay
dhcp relay address-check enable
dhcp relay server-select 1
#
interface Vlan-interface8
ip address 192.168.8.1 255.255.255.0
undo dhcp select server global-pool
#
interface Vlan-interface9
ip address 192.168.9.1 255.255.255.0
undo dhcp select server global-pool
#
interface Vlan-interface10
ip address 192.168.10.1 255.255.255.0
undo dhcp select server global-pool
#
interface GigabitEthernet1/0/1
port link-mode bridge
#
interface GigabitEthernet1/0/2
port link-mode bridge
#
interface GigabitEthernet1/0/3
port link-mode bridge
#
interface GigabitEthernet1/0/4
port link-mode bridge
#
interface GigabitEthernet1/0/5
port link-mode bridge
#
interface GigabitEthernet1/0/6
port link-mode bridge
#
interface GigabitEthernet1/0/7
port link-mode bridge
port access vlan 6
#
interface GigabitEthernet1/0/8
port link-mode bridge
port access vlan 6
#
interface GigabitEthernet1/0/9
port link-mode bridge
port access vlan 7
#
interface GigabitEthernet1/0/10
port link-mode bridge
port access vlan 7
#
interface GigabitEthernet1/0/11
port link-mode bridge
port access vlan 8
#
interface GigabitEthernet1/0/12
port link-mode bridge
port access vlan 8
#
interface GigabitEthernet1/0/13
port link-mode bridge
port access vlan 9
#
interface GigabitEthernet1/0/14
port link-mode bridge
port access vlan 9
#
interface GigabitEthernet1/0/15
port link-mode bridge
port access vlan 10
#
interface GigabitEthernet1/0/16
port link-mode bridge
port access vlan 10
#
interface GigabitEthernet1/0/17
port link-mode bridge
#
interface GigabitEthernet1/0/18
port link-mode bridge
#
interface GigabitEthernet1/0/19
port link-mode bridge
#
interface GigabitEthernet1/0/20
port link-mode bridge
#
interface GigabitEthernet1/0/21
port link-mode bridge
#
interface GigabitEthernet1/0/22
port link-mode bridge
#
interface GigabitEthernet1/0/23
port link-mode bridge
#
interface GigabitEthernet1/0/24
port link-mode bridge
#
interface GigabitEthernet1/0/25
port link-mode bridge
#
interface GigabitEthernet1/0/26
port link-mode bridge
#
interface GigabitEthernet1/0/27
port link-mode bridge
#
interface GigabitEthernet1/0/28
port link-mode bridge
#
interface GigabitEthernet1/0/29
port link-mode bridge
#
interface GigabitEthernet1/0/30
port link-mode bridge
#
interface GigabitEthernet1/0/31
port link-mode bridge
#
interface GigabitEthernet1/0/32
port link-mode bridge
#
interface GigabitEthernet1/0/33
port link-mode bridge
#
interface GigabitEthernet1/0/34
port link-mode bridge
#
interface GigabitEthernet1/0/35
port link-mode bridge
#
interface GigabitEthernet1/0/36
port link-mode bridge
#
interface GigabitEthernet1/0/37
port link-mode bridge
#
interface GigabitEthernet1/0/38
port link-mode bridge
#
interface GigabitEthernet1/0/39
port link-mode bridge
#
interface GigabitEthernet1/0/40
port link-mode bridge
#
interface GigabitEthernet1/0/41
port link-mode bridge
port link-type trunk
port trunk permit vlan 1 6 to 10
#
interface GigabitEthernet1/0/42
port link-mode bridge
port link-type trunk
port trunk permit vlan 1 6 to 10
#
interface GigabitEthernet1/0/43
port link-mode bridge
port link-type trunk
port trunk permit vlan 1 6 to 10
#
interface GigabitEthernet1/0/44
port link-mode bridge
port link-type trunk
port trunk permit vlan 1 6 to 10
#
interface GigabitEthernet1/0/45
port link-mode bridge
port link-type trunk
port trunk permit vlan 1 8
#
interface GigabitEthernet1/0/46
port link-mode bridge
port link-type trunk
port trunk permit vlan 1 8
#
interface GigabitEthernet1/0/47
port link-mode bridge
port link-type trunk
port trunk permit vlan 1 7 to 10
#
interface GigabitEthernet1/0/48
port link-mode bridge
port link-type trunk
port trunk permit vlan 1 7 to 10
#
interface GigabitEthernet1/0/49
port link-mode bridge
port link-type trunk
port trunk permit vlan 1 7 to 10
#
interface GigabitEthernet1/0/50
port link-mode bridge
port link-type trunk
port trunk permit vlan 1 7 to 10
#
interface GigabitEthernet1/0/51
port link-mode bridge
port link-type trunk
port trunk permit vlan 1 7 to 10
#
interface GigabitEthernet1/0/52
port link-mode bridge
port link-type trunk
port trunk permit vlan 1 7 to 10
#
interface M-GigabitEthernet0/0/0
#
interface Ten-GigabitEthernet1/0/53
port link-mode bridge
port link-type trunk
port trunk permit vlan 1 6 to 10
#
interface Ten-GigabitEthernet1/0/54
port link-mode bridge
port link-type trunk
port trunk permit vlan 1 6 to 10
#
ip route-static 0.0.0.0 0.0.0.0 192.168.0.1
#
snmp-agent
snmp-agent local-engineid 800063A2035CDD70CEFFB8
snmp-agent community read public
snmp-agent sys-info version v2c v3
snmp-agent trap enable default-route
#
dhcp server forbidden-ip 192.168.6.1 192.168.6.100
dhcp server forbidden-ip 192.168.7.1 192.168.7.100
dhcp server forbidden-ip 192.168.7.254
#
dhcp enable
#
ssh server enable
#
load xml-configuration
#
load tr069-configuration
#
user-interface aux 0
user-interface vty 0 15
authentication-mode scheme
user privilege level 3
#
return
[H3C_FXL]
(0)
最佳答案
删除下面这条命令
【命令】
dhcp relay address-check enable
undo dhcp relay address-check enable
【视图】
接口视图
【缺省级别】
2:系统级
【参数】
无
【描述】
dhcp relay address-check enable命令用来使能DHCP中继的地址匹配检查功能。undo dhcp relay address-check enable命令用来禁止DHCP中继的地址匹配检查功能。
缺省情况下,禁止DHCP中继的地址匹配检查功能。
接口上使能该功能后,当客户端通过DHCP中继从DHCP服务器获取到IP地址时,DHCP中继可以自动记录客户端IP地址与MAC地址的绑定关系,生成DHCP中继的动态用户地址表项。同时,为满足用户采用合法固定IP地址访问外部网络的需求,DHCP中继也支持静态配置用户地址表项,即在DHCP中继上手工配置IP地址与MAC地址的绑定关系。
DHCP中继接收到主机发送的报文后,如果在用户地址表中(包括DHCP中继动态记录的表项以及手工配置的用户地址表项)没有与报文源IP地址和源MAC地址匹配的表项,则不学习该主机的ARP表项,从而保证非法主机不能通过DHCP中继与外部网络通信。
需要注意的是:
l 目前只能在三层以太网端口和VLAN接口上执行本命令。
l 执行dhcp relay address-check enable命令后将只检查IP和MAC地址,不检查接口。
【举例】
# 使能DHCP中继的地址匹配检查功能。
<Sysname> system-view
[Sysname] interface vlan-interface 1
[Sysname-Vlan-interface1] dhcp relay address-check enable
(0)
亲~登录后才可以操作哦!
确定你的邮箱还未认证,请认证邮箱或绑定手机后进行当前操作
举报
×
侵犯我的权益
×
侵犯了我企业的权益
×
抄袭了我的内容
×
原文链接或出处
诽谤我
×
对根叔社区有害的内容
×
不规范转载
×
举报说明
暂无评论