Package: yaird
Version: 0.0.12-18
Severity: important
Tags: patch

By default, yaird includes merely the dm-mod module with its LVM plan if
the root device is or depends on a logical volume. This causes serious
trouble if an LVM snapshot of the root volume is present while booting.

With the dm-snapshot module loaded, a snapshot is created beforehand:

$ lvcreate -s -L500M -n snaproot /dev/vg/root


Subsequently rebooting, this results in the following boot failure:

device-mapper: ioctl: 4.7.0-ioctl (2006-06-24) initialised: [EMAIL PROTECTED]
device-mapper: table: 253:1: snapshot-origin: unknown target type
device-mapper: ioctl: error adding target to table
  device-mapper: reload ioctl failed: Invalid argument
  2 logical volume(s) in volume group "vg" now active


So as to solve this problem, the dm-snapshot and dm-mirror modules
should always be added to the initramfs image, if available.

The patch included below takes care of optionally adding these modules.
The optionality allows users with custom kernels to leave out snapshot
and/or mirror support entirely.

Regards,
Peter


-- System Information:
Debian Release: testing/unstable
  APT prefers unstable
  APT policy: (500, 'unstable'), (400, 'testing'), (1, 'experimental')
Architecture: amd64 (x86_64)
Shell:  /bin/sh linked to /bin/bash
Kernel: Linux 2.6.18-maia
Locale: LANG=C, [EMAIL PROTECTED] (charmap=ISO-8859-15)

Versions of packages yaird depends on:
ii  cpio                         2.6-17      GNU cpio -- a program to manage ar
ii  dash                         0.5.3-3     The Debian Almquist Shell
ii  libc6                        2.3.6.ds1-6 GNU C Library: Shared libraries
ii  libhtml-template-perl        2.8-1       HTML::Template : A module for usin
ii  libparse-recdescent-perl     1.94.free-3 Generates recursive-descent parser
ii  perl                         5.8.8-6.1   Larry Wall's Practical Extraction 

yaird recommends no packages.

-- no debconf information
diff -urN yaird-0.0.12.orig/perl/Plan.pm yaird-0.0.12/perl/Plan.pm
--- yaird-0.0.12.orig/perl/Plan.pm      2006-10-10 22:43:43.000000000 +0200
+++ yaird-0.0.12/perl/Plan.pm   2006-10-10 22:44:17.000000000 +0200
@@ -352,6 +352,8 @@
                addDevicePlan ($actions, $pdev, $working);
        }
        ModProbe::addModules ($actions, [ "dm-mod" ]);
+       ModProbe::addOptModules ($actions, [ "dm-mirror" ], 1);
+       ModProbe::addOptModules ($actions, [ "dm-snapshot" ], 1);
        $actions->add ("vgchange", $vgnam);
        $device->setCreator ("devmapper");
        return 1;

Reply via email to