]> sourceware.org Git - lvm2.git/commitdiff
thin: allow to convert chunksize of empty pool
authorZdenek Kabelac <zkabelac@redhat.com>
Mon, 3 Nov 2014 13:00:09 +0000 (14:00 +0100)
committerZdenek Kabelac <zkabelac@redhat.com>
Mon, 3 Nov 2014 13:19:33 +0000 (14:19 +0100)
When pool is not used, allow to change its chunksize.

tools/lvconvert.c

index f22c84ba891324ebcbefb03de6768b0aab1c74d2..f37a7a8329f391e96be9d02a652a26ba0d5b9213 100644 (file)
@@ -2923,7 +2923,8 @@ static int _lvconvert_pool(struct cmd_context *cmd,
 
                /* Normally do NOT change chunk size when swapping */
                if (arg_count(cmd, chunksize_ARG) &&
-                   (lp->chunk_size != seg->chunk_size)) {
+                   (lp->chunk_size != seg->chunk_size) &&
+                   !dm_list_empty(&pool_lv->segs_using_this_lv)) {
                        if (lp->force == PROMPT) {
                                log_error("Chunk size can be only changed with --force. Conversion aborted.");
                                return 0;
This page took 0.05073 seconds and 5 git commands to generate.