Posts tagged as:

Ping Command Example

How To Execute Ping Command Only For N number of Packets

by Ramesh Natarajan on November 6, 2009

Question: When I execute ping command from the command line, it keeps sending the packets until I hit CTRL-C to terminate the ping command output. How can I execute ping command only for N number of packets and terminate the output automatically?

Answer: Use ping option -c to specify the number of packets. After sending N number of packets, ping command will terminate automatically as explained below.

(more…)

{ 0 comments }