Whamcloud - gitweb
LU-1366 utils: disable ldiskfs extents feature for MDT
authorBobi Jam <bobijam@whamcloud.com>
Tue, 15 May 2012 14:10:10 +0000 (22:10 +0800)
committerOleg Drokin <green@whamcloud.com>
Fri, 18 May 2012 06:26:18 +0000 (02:26 -0400)
Explicitly disable "extents" for MDT filesystem if it's based on ext4,
it provides no benifit for MDT.

Signed-off-by: Bobi Jam <bobijam@whamcloud.com>
Change-Id: I9cb4d9cbaa80096cb8182e307e4911a92004ddd4
Reviewed-on: http://review.whamcloud.com/2797
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Tested-by: Hudson
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
lustre/utils/mkfs_lustre.c

index eadca90..e1492d0 100644 (file)
@@ -621,10 +621,11 @@ static void enable_default_ext4_features(struct mkfs_opts *mop, char *anchor,
                 append_unique(anchor, user_spec ? "," : " -O ",
                               "extents", NULL, sizeof(mop->mo_mkfsopts));
                 append_unique(anchor, ",", "uninit_bg", NULL, maxbuflen);
                 append_unique(anchor, user_spec ? "," : " -O ",
                               "extents", NULL, sizeof(mop->mo_mkfsopts));
                 append_unique(anchor, ",", "uninit_bg", NULL, maxbuflen);
-        } else if (IS_MDT(&mop->mo_ldd)) {
-                append_unique(anchor, user_spec ? "," : " -O ",
-                              "dirdata", NULL, maxbuflen);
-                append_unique(anchor, ",", "uninit_bg", NULL, maxbuflen);
+       } else if (IS_MDT(&mop->mo_ldd)) {
+               append_unique(anchor, user_spec ? "," : " -O ",
+                             "dirdata", NULL, maxbuflen);
+               append_unique(anchor, ",", "uninit_bg", NULL, maxbuflen);
+               append_unique(anchor, ",", "^extents", NULL, maxbuflen);
         } else {
                 append_unique(anchor, user_spec ? "," : " -O ",
                               "uninit_bg", NULL, maxbuflen);
         } else {
                 append_unique(anchor, user_spec ? "," : " -O ",
                               "uninit_bg", NULL, maxbuflen);