【定义及作用】

本地代理ARP,以网关自身的MAC回应本网段的IP地址的ARP请求,用于二层端口隔离时,同一网段的客户之间能够通信。

 
【实验拓扑】

 

本地代理ARP(Local Proxy ARP ) _实验

【实验要求】
当在R1上过滤了R6的MAC地址时,R1也能够ping通R6

 

 
【配置方法】
R1&R6
no ip routing

 
R4
int E0/0
ip proxy-arp
ip local-proxy-arp

 
【实验验证】
R4#clear arp-cache
R4#ping 155.1.146.1

 
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 155.1.146.1, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 20/45/84 ms
R4#ping 155.1.146.6

 
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 155.1.146.6, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 16/40/116 ms
R4#show arp
Protocol Address Age (min) Hardware Addr Type Interface
Internet 155.1.146.1 0 c000.0dd0.0000 ARPA Ethernet0/0
Internet 155.1.146.4 - c003.0dd0.0000 ARPA Ethernet0/0
Internet 155.1.146.6 0 c005.0f80.0000 ARPA Ethernet0/0

 
从R4到R1与R6的MAC地址都变成了R4的MAC地址,因此即使在R1上过滤R6的MAC地址,R1与R6依然能够ping通,原因是R1认为到R6的MAC地址为R4 E0/0的接口地址,实验无法配置过滤因此只能通过show arp 来查看MAC地址是否相同

 

【实验基本配置】
R1:
inter fa 0/0
ip address 155.1.146.1 255.255.255.0
no shut
R4:
inter ethernet 0/0
ip address 155.1.146.4 255.255.255.0
no shut
!
interface Serial 0/0
encaps frame-relay
no frame-relay inverse
ip address 155.1.0.4 255.255.255.0
frame map ip 155.1.0.5 405 broad
no shutdown
R5:
interface Serial 0/0
encaps frame-relay
no frame-relay inverse
ip address 155.1.0.5 255.255.255.0
frame map ip 155.1.0.4 504 broad
no shut
R6:
inter gig 0/0
ip address 155.1.146.6 255.255.255.0
no shut