Chinaunix首页 | 论坛 | 博客
  • 博客访问: 5381019
  • 博文数量: 890
  • 博客积分: 12876
  • 博客等级: 上将
  • 技术积分: 10760
  • 用 户 组: 普通用户
  • 注册时间: 2004-10-04 14:18
个人简介

猝然临之而不惊,无故加之而不怒。

文章分类

全部博文(890)

文章存档

2016年(1)

2014年(18)

2013年(41)

2012年(48)

2011年(65)

2010年(84)

2009年(121)

2008年(101)

2007年(129)

2006年(95)

2005年(118)

2004年(69)

分类: 网络与安全

2012-12-13 10:52:05

show ip arp命令可以得到IP地址与MAC地址的对应关系,show mac-address-table可以得到MAC地址与端口的对应关系,根据这两组对应关系,我们就可以得到IP地址与端口的对应关系。
 
命令总结:
1.静态绑定arp表项后,无老化时间
R2(config)#arp 192.168.1.2 cc01.0614.0000 arpa
 
2.show ip arp        ---查看arp表
R2#show ip arp 
Protocol  Address          Age (min)  Hardware Addr   Type   Interface
Internet  192.168.1.1             1   cc00.0614.0000  ARPA   FastEthernet0/0
Internet  192.168.1.2             -   cc01.0614.0000  ARPA  
Internet  192.168.1.3             0   cc02.0614.0000  ARPA   FastEthernet0/0
Internet  192.168.1.4             1   cc03.0614.0000  ARPA   FastEthernet0/0
R2#
 
3.show mac-address-table     ---查看mac-address-table,适用于二层接口
 
4.修改arp老化时间
R2(config)#int f0/0
R2(config-if)#arp timeout ?
  <0-2147483>  Seconds
 
5.静态绑定mac-address-table
R1(config)#mac-address-table static cc01.0614.0000 interface fastEthernet 1/2 vlan 2
 
6.清除arp缓存,刷新arp表
R1#clear arp-cache ?
  A.B.C.D    IP address
  interface  Clear the entire ARP cache on the interface
  vrf        Clear entries for a VPN Routing/Forwarding instance
 
R1#clear arp-cache interface fastEthernet 1/2
R1#
 
7.no mac-address-table static 后需要刷新mac-address-table
  clear mac-address-table

From:http://www.cisco-club.com.cn/space-129343-do-blog-id-5263.html
阅读(17926) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~