Advertisement
bytecoded

TopCallsByTotalMemory.sh

Nov 19th, 2019
405
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 0.27 KB | None | 0 0
  1. cat rphost*/*.log | grep -P ',CALL,.+,Context=' | sed -r 's/\xef\xbb\xbf//g; s/^.+,Context=//g; s/,MemoryPeak=.+$//g' | gawk -F',Memory=' '{{Memory[$1]+=$2}} END {for (Context in Memory) print Memory[Context] " " Context}' | sort -rnb | head -n 1000 > TopCallsByTotalMemory.txt
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement