]> sourceware.org Git - lvm2.git/commitdiff
cleanup: enhance messages
authorZdenek Kabelac <zkabelac@redhat.com>
Thu, 11 Jan 2018 09:46:04 +0000 (10:46 +0100)
committerZdenek Kabelac <zkabelac@redhat.com>
Wed, 17 Jan 2018 13:45:48 +0000 (14:45 +0100)
Add extra info about failing local exlusive activation
(as in cluster the LV can be active on some other nodes).

lib/locking/locking.c
tools/pvmove.c

index c68d4c7d50cf9a868f174e76f3b72974b5b3d47a..8daa61e886f623a0bc00f4bfe6dec40c2dec5c7c 100644 (file)
@@ -406,7 +406,8 @@ int activate_lvs(struct cmd_context *cmd, struct dm_list *lvs)
 
        dm_list_iterate_items(lvl, lvs) {
                if (!activate_lv_excl_local(cmd, lvl->lv)) {
-                       log_error("Failed to activate %s", display_lvname(lvl->lv));
+                       log_error("Failed to locally exclusively activate %s.",
+                                 display_lvname(lvl->lv));
                        dm_list_uniterate(lvh, lvs, &lvl->list) {
                                lvl = dm_list_item(lvh, struct lv_list);
                                if (!deactivate_lv(cmd, lvl->lv))
index c5d7e52c41cea3d8ce3ea8ee7decc820d079ac95..af3fec40cbdd8285798d1afabdd4ebb45b8fb606 100644 (file)
@@ -375,9 +375,9 @@ static struct logical_volume *_set_up_pvmove_lv(struct cmd_context *cmd,
                        continue;
 
                if (lv_is_converting(lv) || lv_is_merging(lv)) {
-                       log_error("Unable to pvmove when %s volumes are present.",
-                                 lv_is_converting(lv) ?
-                                 "converting" : "merging");
+                       log_error("Unable to pvmove when %s volume %s is present.",
+                                 lv_is_converting(lv) ? "converting" : "merging",
+                                 display_lvname(lv));
                        return NULL;
                }
 
@@ -389,13 +389,13 @@ static struct logical_volume *_set_up_pvmove_lv(struct cmd_context *cmd,
                                return_NULL;
 
                        /*
-                        * Remove any PVs holding SubLV siblings to allow
-                        * for collocation (e.g. *rmeta_0 -> *rimage_0).
-                        *
-                        * Callee checks for lv_name and valid raid segment type.
-                        *
-                        * FIXME: don't rely on namespace
-                        */
+                        * Remove any PVs holding SubLV siblings to allow
+                        * for collocation (e.g. *rmeta_0 -> *rimage_0).
+                        *
+                        * Callee checks for lv_name and valid raid segment type.
+                        *
+                        * FIXME: don't rely on namespace
+                        */
                        if (!_remove_sibling_pvs_from_trim_list(lv, lv_name, &trim_list))
                                return_NULL;
 
@@ -436,7 +436,7 @@ static struct logical_volume *_set_up_pvmove_lv(struct cmd_context *cmd,
 
                if (lv_is_locked(lv)) {
                        lv_skipped = 1;
-                       log_print_unless_silent("Skipping locked LV %s.", lv->name);
+                       log_print_unless_silent("Skipping locked LV %s.", display_lvname(lv));
                        continue;
                }
 
@@ -445,8 +445,9 @@ static struct logical_volume *_set_up_pvmove_lv(struct cmd_context *cmd,
                    lv_is_active(lv) &&
                    !lv_is_active_exclusive_locally(lv)) {
                        lv_skipped = 1;
-                       log_print_unless_silent("Skipping LV %s which is activated "
-                                               "exclusively on remote node.", lv->name);
+                       log_print_unless_silent("Skipping LV %s which is active, "
+                                               "but not locally exclusively.",
+                                               display_lvname(lv));
                        continue;
                }
 
This page took 0.034692 seconds and 5 git commands to generate.