]> sourceware.org Git - lvm2.git/commit
Fix for bug 637936: killing both redundant logs causes deadlock
authorJonathan Earl Brassow <jbrassow@redhat.com>
Thu, 14 Oct 2010 20:03:12 +0000 (20:03 +0000)
committerJonathan Earl Brassow <jbrassow@redhat.com>
Thu, 14 Oct 2010 20:03:12 +0000 (20:03 +0000)
commit2c33c8b80c7754a56c63166ab2761c3adc984d02
tree9f60046772bed5dc92650293df6eebdfcec78402
parente3e64c8ea467fa4b3a0ef6e1a7ca8a166c60e7ed
Fix for bug 637936: killing both redundant logs causes deadlock

Problem:
When both legs of a mirrored log fail, neither the log nor the parent
mirror can proceed.  The repair code must be careful to replace the
log with an error target before operating on the parent - otherwise,
the parent can get stuck trying to suspend because it can't push through
any writes.  The steps to replace the log device with an error target
were incomplete and resulted in the replacement not happening at all!

The code originally had all the necessary logic to complete the
replacement task, but was pulled out in a effort to clean-up that
section of code, while fixing another bug:
<offending commit msg>
In addition, I added following three changes.

- Removed tmp_orphan_lvs handling procedure
  It seems that _delete_lv() can handle detached_log_lv properly
  without adding mirror legs in mirrored log to tmp_orphan_lvs.
  Therefore, I removed the procedure.

- Removed vg_write()/vg_commit()
  Metadata is saved by vg_write()/vg_commit() just after detached_log_lv
  is handled. Therefore, I removed vg_write()/vg_commit().
</offending commit msg>

http://sources.redhat.com/cgi-bin/cvsweb.cgi/LVM2/lib/metadata/mirror.c?cvsroot=lvm2&f=h#rev1.130

I've reverted the "clean-up" changes associated with that fix, but not what
that commit was actually fixing.

Signed-off-by: Jonathan Brassow <jbrassow@redhat.com>
Reviewed-by: Petr Rockai <prockai@redhat.com>
WHATS_NEW
lib/metadata/lv_manip.c
lib/metadata/mirror.c
This page took 0.037951 seconds and 5 git commands to generate.