How to send several pings per second? (ping more quickly)

pingterminal

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?

Best Answer

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).