Created
September 17, 2018 16:19
-
-
Save relrod/3eed6961f2d6971be3581caeb001ae3f to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
for ip in $(echo 150.134.{0..255}.{0..255}); do | |
echo $ip | |
ping -W 1 -c 1 $ip | |
if [[ $? -eq 0 ]]; then | |
echo $ip >> ips.used | |
else | |
echo $ip >> ips.error | |
fi | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment