echo " [--with=<module>] [--image-version] [--fstab=<fstab>] [--nocompress]"
echo " [--initrdfs=rom|ext2|cram] [--modules-conf=<modules.conf>]"
echo " [--with-raidstart] [--without-raidstart] [--with-insmod-static]"
- echo " [--without-bootsplash] [--lvmversion=1|2]"
+ echo " [--without-bootsplash] [--lvmtoolsversion=1|2]"
echo " <initrd-image> <kernel-version>"
echo " (ex: `basename $0` /boot/initrd-2.2.5-15.img 2.2.5-15)"
exit 1
echo "Please install lvm(2) and lvm(2)-initrd package and rerun $0." >&2
exit 1
fi
- if [ -z "$LVMVERSION" ] ; then
- LVMVERSION=$(/sbin/initrd-lvm vgchange --version 2>/dev/null|head -n 1|awk '{gsub("vgchange: Logical Volume Manager ",NIL); gsub("LVM version: ",NIL); gsub(/\..*/,NIL); print $1}')
- if [ -z "$LVMVERSION" ] ; then
- echo "ERROR: Can't determine LVM tools version. Please set LVMVERSION" >&2
+ if [ -z "$LVMTOOLSVERSION" ] ; then
+ LVMTOOLSVERSION=$(/sbin/initrd-lvm vgchange --version 2>/dev/null|head -n 1|awk '{gsub("vgchange: Logical Volume Manager ",NIL); gsub("LVM version: ",NIL); gsub(/\..*/,NIL); print $1}')
+ if [ -z "$LVMTOOLSVERSION" ] ; then
+ echo "ERROR: Can't determine LVM tools version. Please set LVMTOOLSVERSION" >&2
echo "and rerun $0." >&2
exit 1
fi
echo "You can try to set PVDEVICES in /etc/sysconfig/geninitrd." >&2
exit 1
fi
- if [ "$LVMVERSION" = "2" ]; then
+ if [ "$LVMTOOLSVERSION" = "2" ]; then
findmodule "-dm-mod"
- elif [ "$LVMVERSION" = "1" ]; then
+ elif [ "$LVMTOOLSVERSION" = "1" ]; then
findmodule "-lvm"
findmodule "-lvm-mod"
else
- echo "ERROR: LVM version $LVMVERSION is not supported yet." >&2
+ echo "ERROR: LVM version $LVMTOOLSVERSION is not supported yet." >&2
exit 1
fi
uselvm="yes"
--without-bootsplash)
BOOT_SPLASH="no"
;;
- --lvmversion=)
- LVMVERSION="`echo $1 | awk -F= '{print $2;}'`"
+ --lvmtoolsversion=|--lvmversion=)
+ LVMTOOLSVERSION="`echo $1 | awk -F= '{print $2;}'`"
;;
- --lvmversion)
- LVMVERSION="$2"
+ --lvmtoolsversion|--lvmversion)
+ LVMTOOLSVERSION="$2"
shift
;;
--with=*)
echo "mount -t proc none /proc" >> "$s"
echo "mount -t devfs none /dev" >> "$s"
echo "mount -t tmpfs none /tmp" >> "$s"
- if [ "$LVMVERSION" = "1" ] ; then
+ if [ "$LVMTOOLSVERSION" = "1" ] ; then
echo "lvm vgscan -T" >> "$s"
echo "lvm vgchange -T -a y" >> "$s"
else
<arg rep="repeat">--preload=module</arg>
<arg>--fstab=fstab</arg>
<arg>--raidtab=raidtab</arg>
- <arg>--lvmversion=1|2</arg>
+ <arg>--lvmtoolsversion=1|2</arg>
<arg>--modules-conf=modules.conf</arg>
<arg>--fs=rom|ext2|cram</arg>
<arg>--with-insmod-static</arg>
</listitem>
</varlistentry>
<varlistentry>
- <term>--lvmversion=1|2</term>
+ <term>--lvmtoolsversion=1|2</term>
<listitem>
<para>Tell which version of LVM tools are used.</para>
</listitem>