mirror of
git://sourceware.org/git/lvm2.git
synced 2025-03-10 16:58:47 +03:00
thin: fix percentage compare
Since plugin's percentage compare has been fixed, it's now revealed wrong compare here. The logic for threshold is - to allow to go as high as given value e.g. 80% - so if pool is exactlu 80% full it's still allowed to use it (dmeventd will not resize it).
This commit is contained in:
parent
8f269697d2
commit
b780d329aa
@ -1,5 +1,6 @@
|
|||||||
Version 2.02.133 -
|
Version 2.02.133 -
|
||||||
======================================
|
======================================
|
||||||
|
Correct percentage evaluation when checking thin-pool over threshold.
|
||||||
Fix lvmcache to move PV from VG to orphans if VG is removed and lvmetad used.
|
Fix lvmcache to move PV from VG to orphans if VG is removed and lvmetad used.
|
||||||
Fix lvmcache to not cache even invalid info about PV which got removed.
|
Fix lvmcache to not cache even invalid info about PV which got removed.
|
||||||
Support checking of memlock daemon counter.
|
Support checking of memlock daemon counter.
|
||||||
|
@ -224,7 +224,7 @@ int pool_below_threshold(const struct lv_segment *pool_seg)
|
|||||||
if (!lv_thin_pool_percent(pool_seg->lv, 0, &percent))
|
if (!lv_thin_pool_percent(pool_seg->lv, 0, &percent))
|
||||||
return_0;
|
return_0;
|
||||||
|
|
||||||
if (percent >= threshold) {
|
if (percent > threshold) {
|
||||||
log_debug("Threshold configured for free data space in "
|
log_debug("Threshold configured for free data space in "
|
||||||
"thin pool %s has been reached (%.2f%% >= %.2f%%).",
|
"thin pool %s has been reached (%.2f%% >= %.2f%%).",
|
||||||
display_lvname(pool_seg->lv),
|
display_lvname(pool_seg->lv),
|
||||||
@ -237,7 +237,7 @@ int pool_below_threshold(const struct lv_segment *pool_seg)
|
|||||||
if (!lv_thin_pool_percent(pool_seg->lv, 1, &percent))
|
if (!lv_thin_pool_percent(pool_seg->lv, 1, &percent))
|
||||||
return_0;
|
return_0;
|
||||||
|
|
||||||
if (percent >= threshold) {
|
if (percent > threshold) {
|
||||||
log_debug("Threshold configured for free metadata space in "
|
log_debug("Threshold configured for free metadata space in "
|
||||||
"thin pool %s has been reached (%.2f%% > %.2f%%).",
|
"thin pool %s has been reached (%.2f%% > %.2f%%).",
|
||||||
display_lvname(pool_seg->lv),
|
display_lvname(pool_seg->lv),
|
||||||
|
Loading…
x
Reference in New Issue
Block a user