]> sourceware.org Git - lvm2.git/commitdiff
Fix warn message and update man page
authorZdenek Kabelac <zkabelac@redhat.com>
Tue, 6 Mar 2012 09:22:02 +0000 (09:22 +0000)
committerZdenek Kabelac <zkabelac@redhat.com>
Tue, 6 Mar 2012 09:22:02 +0000 (09:22 +0000)
Fix regression in man page. The chunk size is in kilobyte units on command line
input though in the source code we work with sector size unit
so make it clear in the man page.

Update chunksize for thin pool in man page - it's max value is 1024M == 1G.

Fix warning range message to show proper max value.

WHATS_NEW
man/lvcreate.8.in
tools/lvcreate.c

index c3bac479cf2a91863d72d7eb4e1413f8d946ee9b..008506d53ff0da845c9455cc1638be8aa85ca6c4 100644 (file)
--- a/WHATS_NEW
+++ b/WHATS_NEW
@@ -1,5 +1,6 @@
 Version 2.02.96 - 
 ================================
+  Fix warn msg for thin pool chunk size and update man for chunksize (2.02.89).
 
 Version 2.02.95 - 6th March 2012
 ================================
index e8520d99f98e9a27303ae744a7375c6a45bb2d20..1090a1e76ef680566959a6c81301b1a85d8d6eea 100644 (file)
@@ -120,11 +120,14 @@ If clustered locking is enabled, \fB-a\fIey\fR will activate exclusively
 on one node and \fB-a\fIly\fR will activate only on the local node.
 .TP
 .BR \-c ", " \-\-chunksize " " \fIChunkSize
-Power of 2 chunk size in sector units (512b).
-For snapshot logical volume the value must be between 8 (4KB) and 1024 (512KB)
-and the default value is 8.
-For thin pool logical volume the value must be between 128 (64KB) and
-2097152 (1MB) and the default value is 128.
+Gives the size of chunk for snapshot and thin pool logical volumes.
+For snapshots the value must be power of 2 between 4KiB and 512KiB
+and the default value is 4.
+For thin pools the value must be power of 2 between 64KiB and
+1048576KiB and the default value starts with 64 and scales
+up to fit the pool metadata size within 128MB, 
+if the poolmetadata size is not specified.
+Default unit is in kilobytes.
 .TP
 .BR \-C ", " \-\-contiguous " {" \fIy | \fIn }
 Sets or resets the contiguous allocation policy for
index def36b9753008de36cccdcb589d90bce4db63995..aa2d80753d6f6a0160ac9a505e2a46cd81fdfe6b 100644 (file)
@@ -772,13 +772,15 @@ static int _lvcreate_params(struct lvcreate_params *lp,
                                return 0;
                        }
                } else {
-                       lp->chunk_size = arg_uint_value(cmd, chunksize_ARG, DM_THIN_MIN_DATA_BLOCK_SIZE);
+                       lp->chunk_size = arg_uint_value(cmd, chunksize_ARG,
+                                                       DM_THIN_MIN_DATA_BLOCK_SIZE);
                        if ((lp->chunk_size < DM_THIN_MIN_DATA_BLOCK_SIZE) ||
                            (lp->chunk_size > DM_THIN_MAX_DATA_BLOCK_SIZE) ||
                            (lp->chunk_size & (lp->chunk_size - 1))) {
                                log_error("Chunk size must be a power of 2 in the "
-                                         "range %uK to %uK", (DM_THIN_MIN_DATA_BLOCK_SIZE / 2),
-                                         (DM_THIN_MIN_DATA_BLOCK_SIZE / 2));
+                                         "range %uK to %uK",
+                                         (DM_THIN_MIN_DATA_BLOCK_SIZE / 2),
+                                         (DM_THIN_MAX_DATA_BLOCK_SIZE / 2));
                                return 0;
                        }
                }
This page took 0.036401 seconds and 5 git commands to generate.