Skip to content

Instantly share code, notes, and snippets.

@igricart
Created September 9, 2020 08:16
Show Gist options
  • Save igricart/347684dc9155b7b5080a1c2f71706152 to your computer and use it in GitHub Desktop.
Save igricart/347684dc9155b7b5080a1c2f71706152 to your computer and use it in GitHub Desktop.
Ping with timer information
#!/bin/bash
ping www.google.fr | while read pong; do echo "$(date +%F%T): $pong"; done
# This command would show the output in /tmp/ping.log | To check the values during runtime one could run `tail -f /tmp/ping.log`
ping www.google.fr | while read pong; do echo "$(date +%F%T): $pong"; done > /tmp/ping.log
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment