Actions
action #35877
closed[functional][u] Find out in post-fail-hook if system is I/O-busy
Status:
Resolved
Priority:
Normal
Assignee:
Category:
Enhancement to existing tests
Target version:
Start date:
2018-05-03
Due date:
% Done:
0%
Estimated time:
Difficulty:
Description
Motivation¶
Often we have the situation that tests fail because "something might be slow". But the question might be is it CPU or I/O? To answer this we should look for I/O load in post_fail_hooks
Acceptance criteria¶
- AC1: generic post_fail_hook in os-autoinst-distri-opensuse checks for I/O load on failures as one of the first steps
Suggestion¶
sed -n 's/^.*sda / /p' /proc/diskstats | cut -d' ' -f10
will show the value of "0" if there is no I/O pending and a higher number if there is I/O pending for the first disk. Use this or something comparable as one of the very first steps in a generic post_fail_hook, e.g. the one in lib/opensusebasetest.pm
Alternatives¶
sudo iotop --batch --iter=3 --processes --quiet --only
but it requires the package "iotop" installed which IMHO we do not even have available everywhere
References¶
Actions