Created attachment 1178802 [details]
Description of problem:
Currently, for qemu iothrottling, the burst value could be set smaller than the throttle vaule(i.e. the FOO_max value could be smaller than the FOO value), which makes the burst is meaningless, so suggest to limit its value to be equal or larger than throttle value.
After some test by setting the burst value smaller than the throttle value, it's found: If set burst_length at the same time, the IO would be limited only by the burst value; and if not set burst_length, the IO is limited by the throttle value. Please refer to attached script/test logs for details of current issue.
Version-Release number of selected component (if applicable):
Steps to Reproduce:
Created attachment 1178803 [details]
Test log for bps=512000 bps_max=51200 throttling.bps-total-max-length=1
Created attachment 1178804 [details]
Test log for bps=512000 bps_max=51200 throttling.bps-total-max-length=2
(In reply to Gu Nini from comment #0)
> Currently, for qemu iothrottling, the burst value could be set
> smaller than the throttle vaule(i.e. the FOO_max value could be
> smaller than the FOO value), which makes the burst is meaningless,
> so suggest to limit its value to be equal or larger than throttle
I think I didn't restrict that when I wrote this feature because I
assumed no one would define a FOO_max level that is lower than FOO.
One could argue that if the user does that on purpose then they
deserve the outcome :-)
But I guess it's fine to forbit that kind of setup altogether (that
is, adding a new check to throttle_is_valid()).
The only thing we need to be careful with is that we must not call
throttle_is_valid() after throttle_config(), because the latter sets
FOO_max = FOO / 10 if FOO_max is not set (see throttle_fix_bucket()
But that doesn't seem to be happening so we should be safe.
Fix included in qemu-kvm-rhev-2.6.0-20.el7
Verify the bug on following sw versions:
Host kernel: 3.10.0-489.el7.x86_64
Now there is prompt "bps_max/iops_max cannot be lower than bps/iops" if setting burst value less than throttle value.
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.
For information on the advisory, and where to find the updated
files, follow the link below.
If the solution does not work for you, open a new bug report.