On Wed, Jan 22, 2025 at 14:56:54 +0100, to...@tuxteam.de wrote:
> Yes, that would be totally useful. As has been stated in this
> list last days, ping actually does two things for you:
> 
>  - resolve the host's name to an IP address
>  - check connectivity to that host

Well, three really.  It resolves the argument to an IP address if it
wasn't already one.  It sends ICMP packets to that IP address.
It listens for responses.

If the name resolution step fails, then we know how to approach that.
The other steps can't take place until the name is resolved.

If the outgoing packets are fine but the responses are blocked, then
we would actually have unidirectional communications, but ping wouldn't
be able to tell us that.

If the outgoing packets are blocked (by some overzealous firewall,
perhaps), then the responses would never be generated in the first
place.

And of course there are some hosts on the Internet which are configured
to drop ICMP packets.  So, if you're trying to ping one of those, you
won't receive any response packets.

It's not possible to differentiate the various failure states using ping
alone (at least not from a single host), but it's a good starting point.

Reply via email to