summaryrefslogtreecommitdiffstats
path: root/tools/lvchange.c
diff options
context:
space:
mode:
authorZdenek Kabelac <zkabelac@redhat.com>2011-10-30 22:07:38 +0000
committerZdenek Kabelac <zkabelac@redhat.com>2011-10-30 22:07:38 +0000
commit7654abc26fa30fbecc62274f3351fe457f81d8b4 (patch)
tree9dc36177aba8c9515db36dbbb1680c0ff9fa105e /tools/lvchange.c
parentbbcd37e4b8962ddbc9f6827cde7eb9b925e472a5 (diff)
downloadlvm2-7654abc26fa30fbecc62274f3351fe457f81d8b4.tar.gz
lvm2-7654abc26fa30fbecc62274f3351fe457f81d8b4.tar.xz
lvm2-7654abc26fa30fbecc62274f3351fe457f81d8b4.zip
Thin creation without activation
All thins are created with the next activation and VG is updated without messages. Only some basic commands works. (i.e. lvcreate -an -V10 -T mvg/pool) There can be some combination to confuse this system. This functionality for snapshots is going to be interesting.
Diffstat (limited to 'tools/lvchange.c')
-rw-r--r--tools/lvchange.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/tools/lvchange.c b/tools/lvchange.c
index c58a9e38..42933b62 100644
--- a/tools/lvchange.c
+++ b/tools/lvchange.c
@@ -142,6 +142,10 @@ static int lvchange_availability(struct cmd_context *cmd,
"exclusively", lv->name);
if (!activate_lv_excl(cmd, lv))
return_0;
+ /* Drop any left thin messages after activation */
+ if (lv_is_thin_volume(lv) &&
+ !detach_pool_messages(first_seg(lv)->pool_lv))
+ return_0;
} else if (activate == CHANGE_ALY) {
log_verbose("Activating logical volume \"%s\" locally",
lv->name);