Skip to content

Instantly share code, notes, and snippets.

@brianlan
Created September 30, 2019 02:51
Show Gist options
  • Save brianlan/f29d4093d05ff6aa2b3e008a9e4da9ae to your computer and use it in GitHub Desktop.
Save brianlan/f29d4093d05ff6aa2b3e008a9e4da9ae to your computer and use it in GitHub Desktop.
traceroute-test.sh
#!/bin/bash
# apt -y install unzip
# install besttrace
if [ ! -f "besttrace" ]; then
wget https://github.com/wn789/VPS-/raw/master/besttrace
# unzip besttrace4linux.zip
chmod +x besttrace
fi
## start to use besttrace
next() {
printf "%-70s\n" "-" | sed 's/\s/-/g'
}
clear
next
ip_list=(101.95.120.109 211.95.72.254 183.192.160.3)
ip_addr=(上海电信 上海联通 上海移动)
# ip_len=${#ip_list[@]}
for i in {0..2}
do
echo ${ip_addr[$i]}
./besttrace -q 1 ${ip_list[$i]}
next
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment