1. 程式人生 > >1.1-PC1無默認網關/Proxy-ARP(代理ARP)

1.1-PC1無默認網關/Proxy-ARP(代理ARP)

證明 驗證 address images fas 51cto success fault sequence

1、實驗拓撲:
技術分享圖片

2、命令部署:
PC1(config)#no ip default-gateway 12.1.1.2
拓展:PC1(config)#default int int f0/0

3、驗證:
(1)默認開啟代理:
R2#debug arp
ARP packet debugging is on
PC1#ping 3.3.3.3

R2#
Mar 1 00:16:17.167: IP ARP: rcvd req src 12.1.1.1 c001.1858.0000, dst 3.3.3.3 FastEthernet0/0
Mar 1 00:16:17.171: IP ARP: creating entry for IP address: 12.1.1.1, hw: c001.1858.0000

*Mar 1 00:16:17.171: IP ARP: sent rep src 3.3.3.3 c002.3430.0000,
dst 12.1.1.1 c001.1858.0000 FastEthernet0/0
註意:可以看到3.3.3.3對應的MAC是:c002.3430.0000,這是R2 f0/0的接口MAC地址。
證明:此過程是Proxy-ARP

PC1#show arp
Protocol Address Age (min) Hardware Addr Type Interface
Internet 3.3.3.3 3 c002.3430.0000 ARPA FastEthernet0/0

Internet 12.1.1.1 - c001.1858.0000 ARPA FastEthernet0/0

(2)關閉代理功能:
R2(config)#int f0/0
R2(config-if)#no ip proxy-arp

PC1#ping 3.3.3.3
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 3.3.3.3, timeout is 2 seconds:
.....
Success rate is 0 percent (0/5)

R2#
*Mar 1 00:56:05.231: IP ARP: rcvd req src 12.1.1.1 c001.1858.0000, dst 3.3.3.3 FastEthernet0/0

技術分享圖片

1.1-PC1無默認網關/Proxy-ARP(代理ARP)