linux-raid.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/3] Fix mdadm vs udev race in Incremental and Assemble
@ 2011-10-20 10:06 Jes.Sorensen
  2011-10-20 10:06 ` [PATCH 1/3] Remove race for starting container devices Jes.Sorensen
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Jes.Sorensen @ 2011-10-20 10:06 UTC (permalink / raw)
  To: neilb; +Cc: linux-raid, lukasz.dorau, adam.kwolek, dledford

From: Jes Sorensen <Jes.Sorensen@redhat.com>

Hi,

This patch set fixes the problem with mdadm racing udev during during
incremental or regular assembly of IMSM raids. This set fixes a bug in
the initial patch I posted earlier, and adds the locking to Assemble()
which I didn't have in the first round.

There are three patches to the set:
1) Hold the lock while running Incremental_container() to avoid udev
   (or someone else like a boot script) kicking off an additional
   mdadm instance to try and assemble the container in parallel.
2) Don't send udev a 'change' event to handle incremental assembly
   since we are about to do it ourselves anyway.
3) Hold the lock during Assemble() again to avoid udev kicking in
   behind our backs.

With these patches in place, I can no longer reproduce the case I was
seeing on Fedora 16 Beta where an array would not come up correctly.

Patches are on top of Neil's current git repository.

Comments?

Cheers,
Jes


Jes Sorensen (3):
  Remove race for starting container devices.
  Don't tell sysfs to launch the container as we are doing it ourselves
  Hold the map lock while performing Assemble to avoid races with udev

 Incremental.c |   27 ++++++++++++++-------------
 mdadm.c       |    6 ++++++
 2 files changed, 20 insertions(+), 13 deletions(-)

-- 
1.7.6.4


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2011-10-20 10:06 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-10-20 10:06 [PATCH 0/3] Fix mdadm vs udev race in Incremental and Assemble Jes.Sorensen
2011-10-20 10:06 ` [PATCH 1/3] Remove race for starting container devices Jes.Sorensen
2011-10-20 10:06 ` [PATCH 2/3] Don't tell sysfs to launch the container as we are doing it ourselves Jes.Sorensen
2011-10-20 10:06 ` [PATCH 3/3] Hold the map lock while performing Assemble to avoid races with udev Jes.Sorensen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).