Commit Graph

35 Commits (038)

Author SHA1 Message Date
Harald Hoyer 5746f04994 mdraid: catch nested md raids
Thanks to Ian Dall!
2012-08-22 13:01:53 +02:00
Harald Hoyer c0cae7f702 dmraid,mdraid,lvm,udev: don't process DM_MULTIPATH_DEVICE_PATH devs 2012-07-30 20:41:16 +02:00
Harald Hoyer e539fa9980 90mdraid: add "--offroot" support 2012-02-13 21:16:31 +01:00
Harald Hoyer dd03dea22e 90mdraid: remove mdadm_auto.sh completly
remove mdadm_auto.sh completly, because "mdadm -As --auto=yes" does not
add new appearing devices.
2011-11-16 10:50:21 +01:00
Harald Hoyer 77a57d5eaf order mdadm and lvm timeout operations 2011-10-04 13:03:45 +02:00
Michal Soltys 9fc3f04520 90mdraid: adjust /dev/md loops
Include '_' to also handle old partitionable arrays (pre-2.6.28).

Signed-off-by: Michal Soltys <soltys@ziu.info>
2011-09-22 17:34:51 +02:00
Michal Soltys db9b9f396e 90mdraid: check precisely for supported contaiers
ID_FS_TYPE can be much more than just ddf/imsm/linux raid member, so
do the proper checks.

This reverts certain changes from:
cf5891424e

Signed-off-by: Michal Soltys <soltys@ziu.info>
2011-09-22 17:14:42 +02:00
Michal Soltys a025cc17f0 90mdraid: fix/adjust 65-md* rules and related scripts
Reworked the flow of the rules file a bit, removed redundant tests, also
should be easier to follow. It's much shorter now as well, a bit more
similar to 90lvm script - both revolve around same concepts after all.

There's no reason to treat conf-assembled arrays differently from
incremental ones. Once we hit timeout in init's udev loop, we can use
common script (mdraid_start.sh) to try force inactive arrays
into degraded mode.

md-finished.sh was kind-of out of place - it didn't really wait for any
particular device(s) to show up, just watched if onetime mdadm scripts
are still in place. Furthermore, after moving mdraid_start to --timeout
initqueue, it didn't really have too much to watch at all, besides
mdadm_auto (and that served no purpose, as we do wait for concrete
devices).

Either way, with stock 64-md fixes, current version of 65-md*.rules does
the following:

- limits assembly to certain uuids, if specified
- watch for no ddf/imsm
- if mdadm.conf => setup onetime -As script, without forced --run option
- if !mdadm.conf => incrementally assemble
- for both cases, setup timeout script, run-forcing arrays as a last resort

Signed-off-by: Michal Soltys <soltys@ziu.info>
2011-09-22 15:37:26 +02:00
Michal Soltys cf5891424e 90(md|dm)raid: recognize ddf container
This patch adds ddf support, consistently with imsm/isw options.

Signed-off-by: Michal Soltys <soltys@ziu.info>
2011-09-22 15:37:26 +02:00
Michal Soltys 5f6a71b38a 90mdraid: containers are not runnable
Remove whole "start a container logic".

Containers once assembled, always remain in 'inactive' state.
Any attempt to run a container with mdadm -IR is a no-op, and any
attempt with just mdadm -R ends with an error.

Signed-off-by: Michal Soltys <soltys@ziu.info>
2011-09-22 15:37:23 +02:00
Harald Hoyer 1073b9f93a 90mdraid/65-md-incremental-imsm.rules: incremental run to settled
move incremental run to settled queue again

https://bugzilla.redhat.com/show_bug.cgi?id=732967
2011-08-24 17:23:00 +02:00
Harald Hoyer 3f02ed32a7 90mdraid: move force assembly to timeout initqueue 2011-08-11 14:27:26 +02:00
Harald Hoyer 031bf1d0fa modules.d/90mdraid/65-md-incremental-imsm.rules: fix md_finished install 2011-08-11 14:27:22 +02:00
Harald Hoyer 3b403b32fc removed trailing whitespaces 2011-05-10 11:56:09 +02:00
Harald Hoyer 2a9b703903 set udev property hookdir
Revert "mdraid/65-md-incremental-imsm.rules: s#$hookdir#/lib/dracut/hooks/"

This reverts commit e1f68dc6a0.
2011-04-12 08:45:31 +02:00
Harald Hoyer e1f68dc6a0 mdraid/65-md-incremental-imsm.rules: s#$hookdir#/lib/dracut/hooks/ 2011-04-11 19:25:00 +02:00
Harald Hoyer 0b53ca70b6 Move all hooks to "$hookdir"
hookdir=/lib/dracut/hooks for now, to keep the root directory clean
2011-03-25 16:10:46 +01:00
Harald Hoyer d752c51b90 mdraid: --no-degraded not allowed with -I 2010-08-02 14:17:58 +02:00
Harald Hoyer 24bac034d1 65-md-incremental-imsm.rules: check if md raid is already running 2009-09-16 16:10:09 +02:00
Harald Hoyer 094097fab3 lvm/dm/md: switch from lockfiles to $sys/$devpath/holders/*
This is a more sane solution, than ignoring subsequent "change" events.

The only danger is that we could loop, if a lvm scan triggers a broken
md partition, which triggers a broken PV and so on.

Better fix the scanning tools, not to emit change events for devices,
if no action was taken.
2009-09-16 15:34:13 +02:00
Harald Hoyer 5c3f5746bb 90mdraid/65-md-incremental-imsm.rules: first set initqueue-finished,
then initqueue-settled

also introduce md_finished.sh to check for all md activity to be settled
2009-09-15 15:00:25 +02:00
Harald Hoyer 2f02ae9d45 mdraid: add rd_NO_MDADMCONF --mdadmconf --nomdadmconf
Copy /etc/mdadm.conf to initramfs (even for non-hostonly) if
mdadmconf="yes" is set in dracut.conf or --mdadmconf is specified on the
dracut command line.

This was done, because there seems _no_ sane way to autoassemble md raid
arrays.

also moved rd_NO_MD to an udev ENV
2009-09-15 15:00:18 +02:00
Harald Hoyer 5a8d8dfbb6 switch modules to initqueue-finished 2009-09-15 11:17:22 +02:00
Harald Hoyer aa297ca6b6 65-md-incremental-imsm.rules: refine rules 2009-09-08 15:33:19 +02:00
Harald Hoyer 3bb5b261c7 65-md-incremental-imsm: add additional check for md-non-containers 2009-09-08 13:42:31 +02:00
Harald Hoyer 273b197d75 added initqueue-settled and refactored code 2009-09-07 19:12:01 +02:00
Harald Hoyer 587b3497c1 mdraid_start.sh: fixed raid activation 2009-09-07 16:18:12 +02:00
Harald Hoyer c1d670a893 65-md-incremental-imsm.rules: also check on "change" 2009-09-01 15:42:27 +02:00
Harald Hoyer 0e77eb3782 dmraid/mdraid: only try to delete partition 1-1024
add "--nr 1-1024" to partx, otherwise partx will try to delete
partitions 1-INT_MAX, which takes a long time.
2009-07-23 11:58:24 +02:00
Harald Hoyer 308b10311c mdraid: first remove the partitions, then add to the md raid 2009-07-21 15:40:11 +02:00
Harald Hoyer 7045d15460 dmraid/mdraid: use ENV{DEVTYPE} instead of ATTR{partition} 2009-07-21 15:01:41 +02:00
Harald Hoyer 0de01de409 mdraid: do not handle isw_raid_member if rd_NO_MDIMSM is set in udev ENV
install md-noimsm.sh if mdadm does not support imsm.
2009-07-17 16:00:19 +02:00
Harald Hoyer f874872fc2 add command line parameters to specify exact actions for root assembly
LVM
       rd_NO_LVM
              disable LVM detection

       rd_LVM_VG=<volume group name>
              only activate the volume groups with the given name

crypto LUKS
       rd_NO_LUKS
              disable crypto LUKS detection

       rd_LUKS_UUID=<luks uuid>
              only activate the LUKS partitions with the given UUID

MD
       rd_NO_MD
              disable MD RAID detection

       rd_MD_UUID=<md uuid>
              only activate the raid sets with the given UUID

DMRAID
       rd_NO_DM
              disable DM RAID detection

       rd_DM_UUID=<dmraid uuid>
              only activate the raid sets with the given UUID
2009-07-15 18:27:21 +02:00
Harald Hoyer 584e55654c remove partitions from raid devices before they are used for something
else
2009-07-15 18:27:20 +02:00
Hans de Goede 3564cb7c2c Make Intel BIOS raid use mdraid instead of dmraid when mdadm 3.0 is available
Intel BIOS raid is being shifted from dmraid to mdraid because mdraid offers
more features. So if an imsm metadata capable mdadm is present use mdraid
instead of dmraid for isw_raid_member's

This patch also adds code to mdraid_start.sh so that the raidsets
inside the imsm containers get started once udev is done probing
(doing this earlier leads to potentially degraded use of the sets and
 an unwanted resync).
2009-07-15 18:27:20 +02:00