44 votes

How can I determine if a machine is online without using ping?

Answer useful for Containers ping is ICMP, if you blocked ICMP you can't ping. So, if you have a service running on tcp/udp, just send a package to that port. Now, if you are running your test on ...
David Rz Ayala's user avatar
39 votes
Accepted

Why is ping working when all incoming and outgoing connections are blocked in the firewall?

Ping is ICMP so there's no TCP/UDP connections to block or accept (and that's what you probably denied). ICMP rules are configured in /etc/ufw/before.rules. See this for more information.
Florin Asăvoaie's user avatar
25 votes

How can ping know if my host is down

Differences between responses are not actually determined by ICMP itself but rather indirectly. ICMP can distingush between the following: 0 = net unreachable; 1 = host unreachable; 2 = ...
Overmind's user avatar
  • 3,141
21 votes

Why can't I ping my freshly set up amazon web service EC2 instance?

What you need to do is that you need to add a rule to the security group. Steps Given below. Go to EC2 Dashboard and click "Running Instances" on "Security Groups", select the group of your instance ...
kds's user avatar
  • 311
15 votes

How can I set a short timeout with the ping command?

Use -w switch, both on Windows and Debian. It's a quick way to check if machine responds at all, assuming it'll respond in time less then specified amount of seconds. ping -w 1 192.168.80.105 PING ...
NXT's user avatar
  • 253
15 votes
Accepted

Why echo request doesn't show in tcpdump?

This answer assumes Linux as OS. The output cannot be captured as plaintext by tcpdump: it's already encrypted before tcpdump has a chance to see it and its icmp filter will not match. The input, ...
A.B's user avatar
  • 12.8k
11 votes
Accepted

I am able to ping a device on a different subnet without passing through a L3 device. How?

Route Print on my local machine shows: 192.168.10.99 255.255.255.255 On-link 10.168.10.154 26 That is why, the On-link routes are accessible locally without any gateway, many times they are ...
arana's user avatar
  • 253
11 votes

Fast pinging without requiring the response

ping -f will not wait for the remote party to reply. However, a 1us delay between consecutive packets can simply be too much to ask from your hardware (CPU) and software (IP stack) combination. To ...
shodanshok's user avatar
  • 50.7k
11 votes
Accepted

What is the minimum gigabit Ethernet latency I can expect?

A ping does not measure latency nor does it measure round-trip time. It measures ICMP echo request response time. ICMP messages run with low priority and take way longer than serious traffic. As @...
Zac67's user avatar
  • 11.7k
10 votes

Linux : Ping all the host in the subnet

You can always try to ping to the broadcast address of your subnet. It depends on your local network setup, but you can find it out with $ ifconfig wlp4s0 | grep Bcast inet addr:192.168.199.47 ...
Nils Magnus's user avatar
10 votes

How to ping OpenVpn server to see if it's up?

If you want to know that the host is alive you can just ping its IP or hostname. Make sure the firewall is open for incoming ICMP echo packets from wherever you try to ping it. However if you want to ...
MLu's user avatar
  • 25.5k
10 votes
Accepted

How is ping so low, lower than theoretical limit?

For me, traceroute api.kraken.com ends with 8 ae-2-3602.edge3.Berlin1.Level3.net (4.69.159.5) 15.422 ms 16.278 ms 17.423 ms 9 unknown.Level3.net (212.162.40.34) 12.069 ms 12.045 ms 9.120 ms ...
Simon Richter's user avatar
10 votes

Why do I see more than one IP address for my site when I PING it from CMD?

You are getting different IP addresses because you are using Cloudflare. The whole point of Cloudflare is directing traffic through different nodes to distribute and cache traffic. Pinging the ...
Gerald Schneider's user avatar
9 votes
Accepted

Why EC2 instance continues responding to a ping request after deleting the inbound security group rule?

The change applies immediately, but security group rules control establisment of new traffic flows (identified by source and destination address, protocol, and port numbers for protocols that use port ...
Michael - sqlbot's user avatar
9 votes

Can't ping EC2 instance after enabling ICMP packets

Allowing ICMP Echo Request as well in the security groups fixed it.
JacksonCounty's user avatar
8 votes

How can I enable Ping on an Azure Linux VM

Azure blocks by default ICMP traffic using Network Security groups. To enable you need to create a special rule allowing. For security reasons Azure not allow ICMP from internet Some examples about ...
deconya's user avatar
  • 135
7 votes
Accepted

How can I enable Ping on an Azure Linux VM

Ping external address from Azure VM - does not work as Azure does not permit outbound ICMP Ping Azure VM from external address - does not work as Azure does not permit inbound ICMP Ping between Azure ...
HEDMON's user avatar
  • 477
7 votes
Accepted

Hyper-V: Not able to ping my local VM from Host

It sounds like the document is instructing you to use ping as a method of validating network connectivity, which it isn't unless you know that ping should work in the first place, which it doesn't by ...
joeqwerty's user avatar
  • 111k
6 votes

Is there any way to ARP ping on Windows?

Try "arp-ping.exe" Thought I would add this tool which runs directly from the command prompt: Eli Fulkerson, arp-ping.exe - an implementation of ping via arp lookup (Archived here.) arp-...
Valamas's user avatar
  • 365
6 votes
Accepted

Does Ping ever uses DNS cache

Which database will be used by the system to resolve a host name in a modern Linux system is defined in nsswitch.conf. https://www.oreilly.com/openbook/linag2/book/ch06.html The Resolver Library The ...
Diamond's user avatar
  • 9,141
6 votes

Slow ping responses on LAN, but only in one direction

It looks like machine X might have 802.11 power saving enabled, so it enters lower power mode between pings and has to wake up each time you ping it. When going in the other direction, your laptop ...
expz's user avatar
  • 211
5 votes

Linux command to wait for a SSH server to be up

This is a 'ping_ssh' script I'm using. It handles timeout cases, fast success, and won't prompt for passwords or be fooled by the port being open but not responding as with 'nc' based solutions. This ...
poleguy's user avatar
  • 211
5 votes

Pinging Hostname results in reply from 2 different IP addresses

The first reply you get is from the device you are pinging from and is probably because of an ARP lookup going on which makes the first ping timeout.
Frederik's user avatar
  • 3,387
5 votes

Does Ping ever uses DNS cache

No, it does not, but overall it depends on the resolve. When you issue the command, the DNS entry is resolved into an IP address (yes, this is cache-dependent) and then the ping command protocol (ICMP)...
Overmind's user avatar
  • 3,141
5 votes

Ping request could not find host www.google.com. Please check the name and try a gain

Check your DNS server settings by using ipconfig /all Check your hosts file (located in X:\WINDOWS\system32\drivers\etc). It should be reseted if it contains some non-default records. Check what ...
NStorm's user avatar
  • 1,342
5 votes
Accepted

ping command is not printing result to the console

This is normal behavior. The Linux version of ping does not print any output if there is no reply or ICMP error response to the ping. Nor is there an option to cause it to print any such reply. Note ...
Michael Hampton's user avatar
5 votes
Accepted

ping: Warning: time of day goes back (-203647us), taking countermeasures

This has happened to me on AMD type processors before, where the clocksource wasn't shared between CPUs (it was set to jiffies for me). One of the CPU's was a few jiffies ahead of the other causing ...
Matthew Ife's user avatar
  • 23.6k
5 votes
Accepted

How is it possible that I'm getting a 13ms ping RTT from London to a New York IP?

As far as I can tell that IP-address 172.67.143.96 is a CloudFlare IP-address and not the actual IP-address of you server. CloudFlare in turn uses anycast or similar to direct your traffic to a nearby ...
HBruijn's user avatar
  • 80.3k
5 votes
Accepted

Why is Linux policy-based routing (PBR) not working for ping?

There's a difference between binding to an interface and binding to an IP address. While the 2 working cases do bind to an interface, they avoid the problem that ping encounters (to be explained later)...
A.B's user avatar
  • 12.8k
5 votes

Why can't I ping local IPv6 address?

tentative flag on iproute on Linux output implies duplicate address detection (DAD) has not happened. For you this is both the address in question and your link local. On IPv6, a standard DAD exists, ...
John Mahowald's user avatar

Only top scored, non community-wiki answers of a minimum length are eligible