Last active
August 29, 2015 14:03
-
-
Save yurrriq/23f8b4463cebca6c3ba5 to your computer and use it in GitHub Desktop.
Hacky one-liner to extract worker stack completion times from mover logs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
cat logs/mover.log | awk '/in [0-9]+\.[0-9]+s/{time = $11; sub(/s/, "", time); print $4"-"$3"-"$2"@"$5" " time}' | gnuplot -p -e "set xdata time; set timefmt \"%Y-%b-%d@%H:%M:%S\"; set yrange [0 : 10]; set xrange [\"2014-Jul-07@00:00:00\" : \"2014-Jul-09@00:00:00\"]; set term png size 1920,1080; set xtics format \"%m-%d %H:%M\"; plot '-' using 1:2" | base64 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
cat logs/mover.log | awk '/[0-9]+\.[0-9]+s/{ time = $11; sub(/s/, "", time); print time }' > mover-$(date +'%s').data |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment