3

I was looking into pinging a host 5 times per second. I've read the man page for 'ping' for Mac OSX, but I can't find anything that would allow me to do this. I tried setting the -W switch to 5, to try and force sending more packets faster than the reply is received, but no luck there.

-W waittime Time in milliseconds to wait for a reply for each packet sent.

I ended up using liboping from homebrew.

Is there a reason why I can't control the time gap between ping attempts with the default ping utility?

5
ping -n -i 0.1 google.com

This should do it at 10/sec (works fine in my testing). (-i sets the interval wait in seconds).

  • Thanks, apparently I missed that while reading the man page. – cloneman Aug 21 '14 at 15:22
  • FYI; From my testing, 0.1 works without sudo (10 pings /sec) on Mac OSX, and under Linux, it's 0.2 (5 pings/sec) – cloneman Feb 8 '17 at 23:08

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .