mirror of
git://sourceware.org/git/lvm2.git
synced 2025-01-18 10:04:20 +03:00
raid: lvcreate and lvchange fail if --min_recovery_rate is defined
Fix typos in previous commit 3589e515d. Both commands default [raid_](min|max)recoveryrate to 0 but ensure min_recovery_rate is not larger than max_recoveryrate. This results in command failure without requesting the user to also define max_recovery_rate >= min_recovery_rate. Fix both commands by defining max_recovery_rate = min_recoveryrate in case "lvcreate/lvchange --minrecoveryrate Size ..." requests a larger value than current maxrecoveryrate without also giving option
This commit is contained in:
parent
3589e515dc
commit
f4edd87ffc
@ -596,7 +596,7 @@ static int _read_raid_params(struct cmd_context *cmd,
|
|||||||
|
|
||||||
if (lp->min_recovery_rate > lp->max_recovery_rate) {
|
if (lp->min_recovery_rate > lp->max_recovery_rate) {
|
||||||
log_print_unless_silent("Minimum recovery rate cannot be higher than maximum, adjusting.");
|
log_print_unless_silent("Minimum recovery rate cannot be higher than maximum, adjusting.");
|
||||||
lp->max_recovery_rate > lp->min_recovery_rate;
|
lp->max_recovery_rate = lp->min_recovery_rate;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (lp->region_size < lp->stripe_size) {
|
if (lp->region_size < lp->stripe_size) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user