• 产品与解决方案
  • 行业解决方案
  • 服务
  • 支持
  • 合作伙伴
  • 新华三人才研学中心
  • 关于我们

H3C S3600系列以太网交换机 命令手册-RELEASE 1510(V1.04)

23-ARP命令

本章节下载  (133.3 KB)

docurl=/cn/Service/Document_Software/Document_Center/Switches/Catalog/S3600/S3600-SI/Command/Command_Manual/S3600-SI_CM(V1.04)/200711/317218_30005_0.htm

23-ARP命令

目  录

第1章 ARP配置... 1-1

1.1 ARP配置命令.. 1-1

1.1.1 arp check enable. 1-1

1.1.2 arp static. 1-1

1.1.3 arp timer aging. 1-2

1.1.4 display arp. 1-3

1.1.5 display arp | 1-4

1.1.6 display arp count 1-5

1.1.7 display arp timer aging. 1-6

1.1.8 gratuitous-arp-learning enable. 1-7

1.1.9 reset arp. 1-7

第2章 Resilient ARP配置命令... 2-1

2.1 Resilient ARP配置命令.. 2-1

2.1.1 display resilient-arp. 2-1

2.1.2 resilient-arp enable. 2-1

2.1.3 resilient-arp interface vlan-interface. 2-2

 


第1章  ARP配置

1.1  ARP配置命令

1.1.1  arp check enable

【命令】

arp check enable

undo arp check enable

【视图】

系统视图

【参数】

【描述】

arp check enable命令用来使能ARP表项的检查功能,即不学习MAC地址为组播MAC的ARP表项。undo arp check enable命令用来关闭ARP表项的检查功能,即允许学习MAC地址为组播MAC的ARP表项。

缺省情况下,使能ARP表项的检查功能,即不学习MAC地址为组播MAC的ARP表项。

【举例】

# 设置设备学习MAC地址是组播MAC的ARP表项。

<H3C> system-view

System View: return to User View with Ctrl+Z.

[H3C] undo arp check enable

1.1.2  arp static

【命令】

arp static ip-address mac-address [ vlan-id interface-type interface-number ]

arp static ip-address mac-address vlan-id(以太网端口视图)

undo arp ip-address

【视图】

系统视图、以太网端口视图

【参数】

ip-address:ARP映射项的IP地址部分。

mac-address:ARP映射项的MAC地址部分,格式为H-H-H。

vlan-id:静态ARP表项所属的VLAN,取值范围为1~4094。

interface-type:静态ARP表项所属端口的端口类型。

interface-number:静态ARP表项所属端口的端口编号。

【描述】

arp static命令用来配置ARP映射表中的静态ARP映射项。undo arp命令用来删除ARP映射项。

缺省情况下,系统ARP映射表为空,地址映射由动态ARP协议获取。

需要注意的是:

l              静态ARP映射项在以太网交换机正常工作时间内一直有效,但如果某ARP映射项所对应的VLAN被删除,则该ARP表项也被删除。

l              参数vlan-id必须是已经存在的VLAN ID,且vlan-id参数后面指定的以太网端口必须属于这个VLAN。

l              目前,不支持在聚合端口上配置静态ARP映射项。

相关配置可参考命令reset arpdisplay arp

【举例】

# 配置IP地址202.38.10.2对应的MAC地址为000f-e20f-0000,属于VLAN1的以太网端口Ethernet1/0/1。

<H3C> system-view

System View: return to User View with Ctrl+Z.

[H3C] arp static 202.38.10.2 000f-e20f-0000 1 Ethernet 1/0/1

1.1.3  arp timer aging

【命令】

arp timer aging aging-time

undo arp timer aging

【视图】

系统视图

【参数】

aging-time:动态ARP老化定时器的时间。取值范围为1~1440,单位为分钟。

【描述】

arp timer aging命令用来配置动态ARP老化定时器的时间。undo arp timer aging命令用来恢复动态ARP老化定时器的时间为缺省值。

缺省情况下,动态ARP老化定时器的时间为20分钟。

相关配置可参考命display arp timer aging

【举例】

# 配置动态ARP老化定时器的时间为10分钟。

<H3C> system-view

System View: return to User View with Ctrl+Z.

[H3C] arp timer aging 10

1.1.4  display arp

【命令】

display arp [ dynamic | static | ip-address ]

【视图】

任意视图

【参数】

dynamic:显示动态ARP映射项。

static:显示静态ARP映射项。

ip-address:按照指定的IP地址显示ARP映射项。

【描述】

display arp命令用来显示ARP映射表。

当不带任何可选参数的时候,将显示所有ARP映射项。

相关配置可参考命令arp staticreset arp

【举例】

# 显示所有ARP映射项。

<H3C> display arp

            Type: S-Static   D-Dynamic

IP Address       MAC Address     VLAN ID  Port Name / AL ID      Aging Type

10.2.72.162      000a-000a-0aaa  N/A      N/A                    N/A   S

192.168.0.77     0000-e8f5-6a4a  1        Ethernet1/0/2          13    D

192.168.0.2      000d-88f8-4e88  1        Ethernet1/0/2          14    D

192.168.0.200    0014-222c-9d6a  1        Ethernet1/0/2          14    D

192.168.0.45     000d-88f6-44c1  1        Ethernet1/0/2          15    D

192.168.0.110    0011-4301-991e  1        Ethernet1/0/2          15    D

192.168.0.32     0000-e8f5-73ee  1        Ethernet1/0/2          16    D

192.168.0.3      0014-222c-aa69  1        Ethernet1/0/2          16    D

192.168.0.17     000d-88f6-379c  1        Ethernet1/0/2          17    D

192.168.0.115    000d-88f7-9f7d  1        Ethernet1/0/2          18    D

192.168.0.43     000c-760a-172d  1        Ethernet1/0/2          18    D

192.168.0.33     000d-88f6-44ba  1        Ethernet1/0/2          20    D

192.168.0.35     000f-e20f-2181  1        Ethernet1/0/2          20    D

192.168.0.5      000f-e280-2b38  1        Ethernet1/0/2          20    D

 

---   14 entries found   ---

表1-1 display arp命令显示信息描述表

字段

描述

IP Address

ARP映射项的IP地址

MAC Address

ARP映射项的MAC地址

VLAN ID

ARP映射项所属的VLAN ID

Port Name / AL ID

ARP映射项所属的端口名

Aging

动态ARP映射项的有效时间,单位为分钟

Type

ARP类型

 

1.1.5  display arp |

【命令】

display arp [ dynamic | static] | { begin | exclude | include } text

【视图】

任意视图

【参数】

dynamic:显示动态ARP映射项。

static:显示静态ARP映射项。

| { begin | exclude | include } text:正则表达式。

begin:从第一个包含指定字符串text的ARP项开始显示。

exclude:只显示那些不包含指定字符串text的ARP项。

include:只显示那些包含指定字符串text的ARP项。

text:ARP项中包含的文本。

【描述】

display arp | 命令用来显示包含指定内容的ARP映射表。

相关配置可参考命令arp staticreset arp

【举例】

# 显示包含指定字符串77的ARP表项。

<H3C> display arp | include 77

            Type: S-Static   D-Dynamic

IP Address       MAC Address     VLAN ID  Port Name / AL ID      Aging Type

192.168.0.77     0000-e8f5-6a4a  1        Ethernet1/0/2          12    D

 

---   1 entry found   ---

# 显示不包含指定字符68的ARP表项。

<H3C> display arp | exclude 68

            Type: S-Static   D-Dynamic

IP Address       MAC Address     VLAN ID  Port Name / AL ID      Aging Type

10.2.72.162      000a-000a-0aaa  N/A      N/A                    N/A   S

 

---   1 entry found   ---

显示信息中各字段的解释,请参见表1-1

1.1.6  display arp count

【命令】

display arp count [ [ dynamic | static ] [ | { begin | exclude | include } text ] | ip-address ]

【视图】

任意视图

【参数】

dynamic:动态ARP映射项。

static:静态ARP映射项。

| { begin | exclude | include } text:正则表达式。

begin:从第一个包含指定字符串text的ARP项开始显示。

exclude:只显示那些不包含指定字符串text的ARP项。

include:只显示那些包含指定字符串text的ARP项。

text:ARP项中包含的文本。

ip-address:按照指定的IP地址显示ARP映射项。

【描述】

display arp count命令用来显示指定类型的ARP映射项的数目;当不带任何可选参数时,用来显示所有类型ARP映射项的数目。

相关配置可参考命令arp staticreset arp

【举例】

# 显示所有类型ARP映射项的数目。

<H3C> display arp count

 1 entry found

1.1.7  display arp timer aging

【命令】

display arp timer aging

【视图】

任意视图

【参数】

【描述】

display arp timer aging命令用来显示动态ARP老化定时器的时间。

相关配置可参考命令arp timer aging

【举例】

# 显示动态ARP老化定时器的时间。

<H3C> display arp timer aging

Current ARP aging time is 20 minute(s)(default)

以上显示信息表示动态ARP老化定时器的时间为20分钟。

1.1.8  gratuitous-arp-learning enable

【命令】

gratuitous-arp-learning enable

undo gratuitous-arp-learning enable

【视图】

系统视图

【参数】

【描述】

gratuitous-arp-learning enable命令用来启动免费ARP报文的学习功能。undo gratuitous-arp-learning enable命令用来关闭免费ARP报文的学习功能。

缺省情况下,交换机上的免费ARP报文学习功能处于开启状态。

在使能了免费ARP报文学习功能后,一个设备收到免费ARP报文后将会进行以下处理:

l              如果高速缓存中已存在与此报文对应的ARP表项,那么此设备就用免费ARP报文中携带的发送端硬件地址更新ARP表项中相应的内容。

l              如果高速缓存中没有与此报文对应的ARP表项,那么在高速缓存中添加相应的ARP表项。

【举例】

# 在交换机上开启免费ARP报文学习功能。

<H3C> system-view

System View: return to User View with Ctrl+Z.

[H3C] gratuitous-arp-learning enable

1.1.9  reset arp

【命令】

reset arp [ dynamic | static | interface interface-type interface-number ]

【视图】

用户视图

【参数】

dynamic:清除动态ARP映射项。

static:清除静态ARP映射项。

interface-type:端口类型。

interface-number:端口编号。

【描述】

reset arp命令用来清除符合条件的ARP映射项。

相关配置可参考命令arp staticdisplay arp

【举例】

# 清除静态ARP映射项。

<H3C> reset arp static

 


第2章  Resilient ARP配置命令

2.1  Resilient ARP配置命令

2.1.1  display resilient-arp

【命令】

display resilient-arp [ unit unit-id ]

【视图】

任意视图

【参数】

unit-id:Unit ID,取值范围为1~8。

【描述】

display resilient-arp命令用来显示各Unit的Resilient ARP状态信息、可发送Resilient ARP报文的VLAN接口。

如果没有指定unit-id,则显示所有Unit的Resilient ARP的状态信息;如果指定了unit-id,则只显示指定Unit上的Resilient ARP状态信息。

【举例】

# 显示Unit1的Resilient ARP的状态信息。

<H3C> display resilient-arp unit 1

The state of unit 1 is:L3Master

The sending interface(s):

Vlan-interface2

Vlan-interface1

以上显示信息表示Unit1的Resilient ARP当前状态是L3Master,可发送Resilient ARP报文的VLAN接口是VLAN接口2和VLAN接口1。

2.1.2  resilient-arp enable

【命令】

resilient-arp enable

undo resilient-arp enable

【视图】

系统视图

【参数】

【描述】

resilient-arp enable命令用来开启Resilient ARP功能。undo resilient-arp enable命令用来关闭Resilient ARP功能。

缺省情况下,Resilient ARP处于开启状态。

相关配置可参考命令display resilient-arp

【举例】

# 开启Resilient ARP功能。

<H3C> system-view

System View: return to User View with Ctrl+Z.

[H3C] resilient-arp enable

2.1.3  resilient-arp interface vlan-interface

【命令】

resilient-arp interface vlan-interface vlan-id

undo resilient-arp interface vlan-interface vlan-id

【视图】

系统视图

【参数】

vlan-id:VLAN接口号。

【描述】

resilient-arp interface vlan-interface命令用来配置可发送Resilient ARP报文的VLAN接口。undo resilient-arp interface vlan-interface命令用来删除可发送Resilient ARP报文的VLAN接口。

缺省情况下,从VLAN 1接口发送Resilient ARP报文。

相关配置可参考命令display resilient-arp

【举例】

# 配置可发送Resilient ARP报文的VLAN接口为VLAN接口2。

<H3C> system-view

System View: return to User View with Ctrl+Z.

[H3C] resilient-arp interface vlan-interface 2

 

 

不同款型规格的资料略有差异, 详细信息请向具体销售和400咨询。H3C保留在没有任何通知或提示的情况下对资料内容进行修改的权利!

新华三官网
联系我们