dev-ops/dns_warmup/dns_warmup.sh

15 lines
323 B
Bash
Raw Permalink Normal View History

2022-07-16 13:42:25 +00:00
#!/bin/bash
2022-07-17 08:56:47 +00:00
target_domain=$1
if [[ -z "${target_domain}" ]]; then
echo "target_domain should not be null. Usage: ./${0} <target_domain>"
exit 1
fi
while true;
do
date
2022-07-17 08:58:00 +00:00
cat chinese_public_dns.list | grep -v '#' | grep '.' | xargs -I {} dig +time=5 +tries=1 @{} ${target_domain} > /dev/null 2>&1
2022-07-17 08:56:47 +00:00
sleep 60
done