btrfs-progs: mkfs: allow DUP on multidev fs, only warn
authorDavid Sterba <dsterba@suse.com>
Wed, 16 Mar 2016 17:08:33 +0000 (18:08 +0100)
committerDavid Sterba <dsterba@suse.com>
Wed, 30 Mar 2016 14:26:27 +0000 (16:26 +0200)
The DUP profile can work on multiple filesystems, the limitation is
rather artificial. Let the user make the decision and print a warning.

Signed-off-by: David Sterba <dsterba@suse.com>
utils.c

diff --git a/utils.c b/utils.c
index 160bd73..0ba4ecb 100644 (file)
--- a/utils.c
+++ b/utils.c
@@ -2461,9 +2461,7 @@ int test_num_disk_vs_raid(u64 metadata_profile, u64 data_profile,
 
        if (dev_cnt > 1 &&
            ((metadata_profile | data_profile) & BTRFS_BLOCK_GROUP_DUP)) {
-               fprintf(stderr,
-                   "ERROR: DUP is not allowed when FS has multiple devices\n");
-               return 1;
+               warning("DUP is not recommended on filesystem with multiple devices");
        }
        if (metadata_profile & ~allowed) {
                fprintf(stderr,