1

why when ping an IP address we get 4 replies ?

thanks

2

Ping is just a small program which sends ICMP Echo Requests, and receives the ICMP Echo Replies. Actually, many different implementations of ping exist...

On Windows, the default ping utility sends 4 echo request by default. So, when everything is working fine, you will see 4 echo replies. You can send more (or less) requests by passing the -n option to the ping executable.

On Unix systems, the default implementation will keep sending echo requests until interrupted by the user (with Ctrl-C), and the option to send a specific number of requests is -c.

2

I will assume you're using a Windows PC.

When you "ping," your computer sends (by default) four ICMP echo requests. Each request will get a reply (if everything is working properly). So you see each of the four replies. You can change the number of echo requests with the "-n" switch.

2
  • Why it sends 4 requests ? – Nina May 2 '17 at 18:17
  • 2
    That's just the way the program works. I assume it's so you will see several values of response time, rather than a single data point. – Ron Trunk May 2 '17 at 18:18

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.