-
-
Save dotiful/984a76abdcbb9fc360a50093e1338feb to your computer and use it in GitHub Desktop.
Testing DNS Speeds
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 domain in twitter.com tosbourn.com i.ua; do \ | |
google_dns=$(dig @8.8.8.8 ${domain} | awk '/msec/{print $4}') | |
cloudflare_dns=$(dig @1.1.1.1 ${domain} | awk '/msec/{print $4}') | |
open_dns=$(dig @208.67.222.222 ${domain} | awk '/msec/{print $4}') | |
printf "${domain}\tCloudFlare DNS ${cloudflare_dns}ms\tGoogle DNS ${google_dns}ms\tOpenDNS ${open_dns}ms\n" | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment