ARP – Difference Between Proxy ARP and Default Gateway

arpciscoproxy-arp

Firstly what I understand,
Default Gateway–> When we set the default gateway in PC the network layer check the destination IP address and if it is not on same broadcast domain as the source IP address it set destination MAC address to be of the router which further make routing decision.

Proxy ARP –>{{It is used when host do not have default gateway set}} When the destination IP address's MAC address is not in the table of PC it sent an ARP request to know its MAC address. THE switch broadcast the request and it also goes to router and the router knows the destination IP address as it is directly connected to it so it gives its MAC address as proxy.

Now my question is that
MY network is like this–>> Host A—Switch1—-Router—-Switch2—Host B
and Host A has IP address of 192.168.1.1 (no default gateway set) and same for host B with IP address 192.168.2.1(no default gateway set) so why can't Host A ping Host B using Proxy ARP.Router has interfaces as 192.168.1.254 and 192.168.2.254

IS proxy ARP not enabled by default but it is given in cisco.com it is enabled by default so why can not then

AND Also

which is given preference default gateway method or proxy ARP is default gateway is set and router knows path to destination

Best Answer

Let me start by saying proxy ARP is at best a sloppy solution. They only time I found it useful as a feature is when I was dealing with devices on the network that could not utilize classless netmasks or couldn't set a default route.

Yes, it can "cover" many client configuration or bad design problems, but it doesn't fix those problems. It also doesn't "cover" all of them and it can make troubleshooting issues more difficult.

Getting back to your question, the most likely reason this isn't working is that your client's aren't ARPing. My guess is that you have given them what is often considered a "standard" network mask of /24. So the solution would be to switch the network masks on the clients to /16.

Why? A client uses it's IP address and network mask to determine if a destination is on the local network or not. If it is on the local network, the client checks it's ARP table for any entries for the destination and if one doesn't exist, will send out an ARP request to get this information. This is where the router with proxy ARP enabled can respond, but if there is no ARP request then the router cannot provide a proxy ARP response.

If the destination is not on the local network, then the client will check it's routing table to see where to forward the traffic. This is typically your default gateway.

Now, with the IP addresses you used, if you used a /24 network mask, when the client checked the destination against it's IP/mask, it would find the destination is not on the local network. Going to the routing table, it won't have a specific entry for the destination network (clients won't by default) and no default route/gateway. It will then fail with a "no route to host" type of message.