From: Johannes Truschnigg Date: Sat, 3 Sep 2022 17:36:41 +0000 (+0200) Subject: Drop unused script reflector_detect X-Git-Url: https://johannes.truschnigg.info/gitweb/?a=commitdiff_plain;h=5625b7bbb51dc6b6fcb6d9bd322dc2260343f2cd;p=sqm_lagthrottle Drop unused script reflector_detect --- diff --git a/reflector_detect b/reflector_detect deleted file mode 100755 index 63903ba..0000000 --- a/reflector_detect +++ /dev/null @@ -1,26 +0,0 @@ -#!/bin/sh - -get_first_pingpeer() { - traceroute -n "${1}" | while read num peer lat1 _ lat2 _ lat3 _ - do - case "${num}" in - [123456789]*) - if ping -c 1 -s 1280 -W 2 -w 2 "${peer}" >/dev/null 2>/dev/null - then - printf '# %s - hop #%d (%s) responds to ICMP ECHO\n' "${1}" "${num}" "${peer}" - printf 'PEER %s\n' "${peer}" - break - fi - ;; - *) - : pass $num $peer - ;; - esac - done -} - - -for p in 8.8.8.8 1.1.1.1 example.com google.com -do - get_first_pingpeer "${p}" -done