master - mirror: Add deprecation warning for mirrored log
Gitweb: https://sourceware.org/git/?p=lvm2.git;a=commitdiff;h=d67f1602005b4f83e5949668a0cf4e7e5ff0c7d2 Commit: d67f1602005b4f83e5949668a0cf4e7e5ff0c7d2 Parent: dd6fbcbb6941b0d534689258f7f07f567ee6f352 Author: Marian Csontos <[email protected]> AuthorDate: Wed Feb 14 12:46:08 2018 +0100 Committer: Marian Csontos <[email protected]> CommitterDate: Wed Feb 14 13:32:04 2018 +0100
mirror: Add deprecation warning for mirrored log
--- lib/metadata/mirror.c | 4 ++++ tools/lvconvert.c | 5 +++++ 2 files changed, 9 insertions(+), 0 deletions(-)
lib/metadata/mirror.c +4 -0
@@ -1945,6 +1945,10 @@ int add_mirror_log(struct cmd_context *cmd, struct logical_volume *lv,return 1 ; } +if (log_count >1 ) { +log_warn ("Log type \"mirrored\" is DEPRECATED and will be removed in the future. Use RAID1 LV or disk log instead." ); + } +if (!(parallel_areas =build_parallel_areas_from_lv (lv,0 ,0 ))) return_0;
tools/lvconvert.c +5 -0
@@ -1216,6 +1216,11 @@ static int _lvconvert_mirrors(struct cmd_context *cmd, (old_log_count == new_log_count))return 1 ; +if ((old_log_count != new_log_count) && + (new_log_count ==MIRROR_LOG_MIRRORED )) { +log_warn ("Log type \"mirrored\" is DEPRECATED and will be removed in the future. Use RAID1 LV or disk log instead." ); + } +if (!_lvconvert_mirrors_aux (cmd, lv, lp,NULL , new_mimage_count, new_log_count, lp->pvh)) return_0;