Add a lvm stripecount configure parameter
authorIustin Pop <iustin@google.com>
Mon, 8 Jun 2009 13:15:40 +0000 (15:15 +0200)
committerIustin Pop <iustin@google.com>
Mon, 8 Jun 2009 15:00:45 +0000 (17:00 +0200)
This patch adds a configure-time customizable parameter that will be
used to enable stripped LVs. The default of the parameter is 3.

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: Guido Trotter <ultrotter@google.com>

Makefile.am
configure.ac
lib/constants.py

index bacdc3d..da7c689 100644 (file)
@@ -316,6 +316,7 @@ lib/_autoconf.py: Makefile stamp-directories
          echo "KVM_PATH = '$(KVM_PATH)'"; \
          echo "KVM_MIGRATION_PORT = '$(KVM_MIGRATION_PORT)'"; \
          echo "SOCAT_PATH = '$(SOCAT_PATH)'"; \
+         echo "LVM_STRIPECOUNT = $(LVM_STRIPECOUNT)" ; \
        } > $@
 
 $(REPLACE_VARS_SED): Makefile stamp-directories
index 58de2f3..c04ad5e 100644 (file)
@@ -119,6 +119,16 @@ AC_ARG_WITH([socat-path],
   [socat_path="/usr/bin/socat"])
 AC_SUBST(SOCAT_PATH, $socat_path)
 
+# ---with-lvm-stripecount=...
+AC_ARG_WITH([lvm-stripecount],
+  [AS_HELP_STRING([--with-lvm-stripecount=NUM],
+    [the number of stripes to use for LVM volumes]
+    [ (default is 3)]
+  )],
+  [lvm_stripecount="$withval"],
+  [lvm_stripecount="3"])
+AC_SUBST(LVM_STRIPECOUNT, $lvm_stripecount)
+
 # Check common programs
 AC_PROG_INSTALL
 AC_PROG_LN_S
index d9edc13..3949f56 100644 (file)
@@ -245,6 +245,7 @@ DEFAULT_VG = "xenvg"
 BIND_ADDRESS_GLOBAL = "0.0.0.0"
 MIN_VG_SIZE = 20480
 DEFAULT_MAC_PREFIX = "aa:00:00"
+LVM_STRIPECOUNT = _autoconf.LVM_STRIPECOUNT
 
 # RPC constants
 (RPC_ENCODING_NONE,