Tips & Tricks: Ping a Range of IP Addresses

A way to ping all addresses from 192.168.1.1 to 192.168.1.254 once, wait 100ms for a reply and display only addresses that are getting a reply.

Syntax for FOR /l is (start,step,end) if you want to change the range.

Note that the Windows FIND is case sensitive, so make sure you capitalise "Reply,".

C:\Users\dknezev>for /l %i in (1,1,254) do @ping 192.168.1.%i -n 1 -w 100 | find "Reply"

No comments:

Post a Comment