1
0
mirror of git://sourceware.org/git/lvm2.git synced 2024-12-21 13:34:40 +03:00
lvm2/udev
Peter Rajnoha 764195207d udev: also autoactivate on coldplug
Commit 756bcabbfe fixed autoactivation
to not trigger on each uevent for a PV that appeared in the system
most notably the events that are triggered artificially (udevadm
trigger or as the result of the WATCH udev rule being applied that
consequently generates CHANGE uevents). This fixed a situation in
which VGs/LVs were activated when they should not.

BUT we still need to care about the coldplug used at boot to
retrigger the ADD events - the "udevadm trigger --action=add"!

For non-DM-based PVs, this is already covered as for these we
run the autoactivation on ADD event only.

However, for DM-based PVs, we still need to run the
autoactivation even for the artificial ADD event, reusing
the udev DB content from previous proper CHANGE event that
came with the DM device activation.

Simply, this patch fixes a situation in which we run extra
"udevadm trigger --action=add" (or echo add > /sys/block/<dev>/uevent)
for DM-based PVs (cryptsetup devices, multipath devices, any
other DM devices...).

Without this patch, while using lvmetad + autoactivation,
any VG/LV that has a DM-based PV and for which we do not
call the activation directly, the VG/LV is not activated.

For example a VG with an LV with root FS on it which is directly
activated in initrd and then missing activation of the rest
of the LVs in the VG because of unhandled uevent retrigger on
boot after switching to root FS (the "coldplug").

(No WHATS_NEW here as this fixes the commit mentioned
above and which was not released yet.)
2013-04-19 12:43:36 +02:00
..
10-dm.rules.in udev: also autoactivate on coldplug 2013-04-19 12:43:36 +02:00
11-dm-lvm.rules.in udev: udev rules cleanup 2012-06-27 12:11:56 +02:00
12-dm-permissions.rules add copyright lines 2009-10-26 22:42:07 +00:00
13-dm-disk.rules.in Call built-in blkid conditionaly (udev version >= 176), call standard blkid 2012-02-20 19:38:40 +00:00
69-dm-lvm-metad.rules.in udev: also autoactivate on coldplug 2013-04-19 12:43:36 +02:00
95-dm-notify.rules.in udev: udev rules cleanup 2012-06-27 12:11:56 +02:00
Makefile.in udev: udev rules cleanup 2012-06-27 12:11:56 +02:00