1

From Windows CMD, when trying to ping another computer on our internal LAN, the IP obviously fails to respond. However the reply of "Destination host unreachable." comes from yet a different IP, and not that of the router.

In my network, the gateway is 10.0.0.252, but I'm getting a reply from 10.0.20.188; which is an dynamic DHCP allocated IP to general devices.

C:\Users\drodecker>ping pbx

Pinging pbx.office.relevantads.com [10.1.1.211] with 32 bytes of data:
Reply from 10.0.20.188: Destination host unreachable.
Reply from 10.0.20.188: Destination host unreachable.
Reply from 10.0.20.188: Destination host unreachable.
Reply from 10.0.20.188: Destination host unreachable.

Ping statistics for 10.1.1.211:
    Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),
drodecker
  • 51
  • 4

1 Answers1

1

SIMPLE ANSWER: Your PC is trying to resolve the Ethernet MAC address of the next-hop interface, but it can not find none (eg: the target PC is powered off). So it reports a "Destination host unreachable" ICMP message originating from its own interface.

LONG ANSWER An IP-over-Ethernet network has two complementary network addresses: a non-routable, link-layer physical addressing (the MAC address) and a routable, network-layer logical addressing (the IP address).

When trying to ping another hosts, your PC must:

  1. decide, by virtue of the routing table, the outgoing interface
  2. determine the MAC address of the next-hop Ethernet interface (using the ARP protocol)
  3. send a packed with the next-hop interface as the destination MAC address and with the target IP address as the final destination

Point n.2 is were behavior can diverge:

  • if the remote host is on the local network, the next-hop Ethernet interface is the final destination you are trying to reach (eg: if my PC has IP 10.0.0.1 /24 and I am trying to ping PC with IP address 10.0.0.2, the next-hop interface is that of the target computer);
  • if the remote host is on a remote network, the next-hop Ethernet interface is that of the gateway interface (eg: if my PC has IP 10.0.0.1 /24 and I am trying to ping PC with IP address 10.10.10.1 /24 and that remote network can be reached using local router 10.0.0.254 /24, the next-hop interface is that of the router).

So, if your ping failed with a reply from your own PC interface, we have two possibility:

  1. you are trying to ping a local address: this address is not replying to your PC ARP requests and, after a timeout, your PC inform you that the target Ethernet address can not be found.
  2. you are trying to ping a remote address: your configured gateway for that address (eg: your default gateway) is not responding to your PC ARP requests. After a timeout, your PC inform you that the target Ethernet address can not be found.
shodanshok
  • 47,711
  • 7
  • 111
  • 180