Ping with timestamp

Posted on

In windows powershell ping.exe -t 10.122.0.10 |Foreach{“{0} – {1}” -f (Get-Date),$_} MacOS i terminal ping -i 1 -c 10000 1.1.1.1 | while read pong; do echo “$(date -j ‘+%Y-%m-%d %H:%M:%S’) $pong”;done