diff options
author | Aaron Bockover <abockover@novell.com> | 2009-04-24 20:31:00 -0400 |
---|---|---|
committer | Aaron Bockover <abockover@novell.com> | 2009-05-15 22:44:18 -0400 |
commit | d6d3d1494fe5243217cb13f7552ad602d33906ba (patch) | |
tree | c5daf1cdddeb3b0e99e5acf3cd22077312b10eda /extras | |
parent | 95d0d9719820d4bb92d3a5a59ae7065814a17e2f (diff) |
Script to analyze service startup times
(cherry picked from commit bc127273ef3bfdf1c2846ac7e4456d0983c40ad4)
Diffstat (limited to 'extras')
-rwxr-xr-x | extras/perf-analyze-log | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/extras/perf-analyze-log b/extras/perf-analyze-log new file mode 100755 index 000000000..de740e62b --- /dev/null +++ b/extras/perf-analyze-log @@ -0,0 +1,18 @@ +#!/bin/bash + +[[ -e "$1" ]] || { + echo "File does not exist: $1"; + exit 1; +} + +for SERVICE_TYPE in Core Extension; do + echo "$SERVICE_TYPE Services:" + awk '/'"$SERVICE_TYPE"' service started/{ + gsub(/[\(\)\,]/, "") + gsub(/[0-9]s$/, "") + print "\t" $7 "\t " $6 + }' < "$1" | sort -nr + echo +done + + |