Merge lp:~asac/ubuntu-test-cases/use-top-and-always-dumb-toplog into lp:ubuntu-test-cases/touch
Proposed by
Alexander Sack
Status: | Merged |
---|---|
Merged at revision: | 12 |
Proposed branch: | lp:~asac/ubuntu-test-cases/use-top-and-always-dumb-toplog |
Merge into: | lp:ubuntu-test-cases/touch |
Diff against target: |
140 lines (+32/-33) 1 file modified
systemsettle/systemsettle.sh (+32/-33) |
To merge this branch: | bzr merge lp:~asac/ubuntu-test-cases/use-top-and-always-dumb-toplog |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Paul Larson | Approve | ||
Review via email: mp+180889@code.launchpad.net |
This proposal supersedes a proposal from 2013-08-19.
Description of the change
+ use top in batchmode instead of vmstat
+ improve logging; echo cli arguments given as well as
+ dumb top_log regardless of success and failyure
+ top_log is now more useful to see what was going on as we dumb exactly what was measured
+ addresses all previous comments (minus request for optionally dumping top log)
To post a comment you must log in.
I haven't looked too deeply just yet, but there are some things I see after a quick trial run locally:
>Measurement:
> + idle level: 148.50
> + idle sum: 148.5 / count: 2
>
>system settled. SUCCESS
I told it to only pass if it hit 99% or better, and my system was constantly at 80% or less idle... clearly this is not good.
Using top in the way you are using it right now means that we only see that it's starting the first pass, but then we don't get any more feedback that something is happening until the end of the entire run.
27 +echo " cmd = 'top -b -d $vmstat_wait -n $vmstat_repeat' ignoring first $vmstat_ignore (tail: $vmstat_tail)"
Instead of printing out 7 lines of verbose detail about the options we just passed it, I think it would make more sense to just have the above line do something like print the exact command line args. I had thought about changing this in the first pass, but waited.
48 + top -b -d $vmstat_wait -n $vmstat_repeat >> $top_log
49 + cat $top_log | grep '.Cpu.*' | tail -n $vmstat_tail > $vmstat_log.reduced
If we are no longer using vmstat, we may as well change the variable names to reflect that as well.
Printing the entire top log of every run is not always desirable, and sometimes gets in the way. Considering our primary use, I think it's sensible to have it on by default, but we should at least have an option to turn it off.