From: Jun'ichi Nomura <j-nomura@ce.jp.nec.com>
To: lvm-devel@redhat.com
Subject: [PATCH lvconvert 0/2] Fixes suspend/resume ordering of lvconvert
Date: Wed, 06 Feb 2008 16:55:11 -0500 [thread overview]
Message-ID: <47AA2CBF.1060109@ce.jp.nec.com> (raw)
lvconvert has problems where 2 active mirror maps coexist
for a short while sharing the same log device.
That is critical to cluster mirror as it detects such situation
but also dangerous to non-clustered mirror.
(A lot of thanks to Jon Brassow for the reports, testings and
analysis from cluster mirror viewpoint)
The problems are:
1. resume before suspend
When a layer is inserted beneath a LV, the layer is
resumed before the LV is suspended.
I.e. if the LV is active, lvconvert calls suspend_lv() for
the LV to suspend the LV preparing for the update:
suspend_lv()
_lv_suspend()
_lv_preload()
dev_manager_preload()
dm_tree_preload_children()
Load tables for devices from bottom to top.
If a device has parents, resume the device, too.
_lv_suspend_lv()
dev_manager_suspend()
However, before actually suspend the LV, suspend_lv() will end
up calling dm_tree_preload_children() that involves resuming
of the layer.
2. off-tree device not updated
When a layer is removed, a new table of "error" target
is not loaded/resumed for the layer during the update
of the LV.
So the layer continues to have the old table.
_remove_mirror_images()
remove_layer_from_lv()
Update the in-memory VG metadata.
The layer is no longer a part of the LV in the metadata.
vg_write()
The metadata is pre-committed.
suspend_lv()
vg_commit()
The metadata is committed.
resume_lv()
Load new tables based on the new metadata and resume.
It doesn't load a new table for the layer.
Thanks,
--
Jun'ichi Nomura, NEC Corporation of America
-------------- next part --------------
A non-text attachment was scrubbed...
Name: lvconvert-bad.log
Type: text/x-log
Size: 228564 bytes
Desc: not available
URL: <http://listman.redhat.com/archives/lvm-devel/attachments/20080206/402cb516/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: lvconvert-good.log
Type: text/x-log
Size: 230023 bytes
Desc: not available
URL: <http://listman.redhat.com/archives/lvm-devel/attachments/20080206/402cb516/attachment-0001.bin>
next reply other threads:[~2008-02-06 21:55 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-02-06 21:55 Jun'ichi Nomura [this message]
2008-02-06 22:04 ` [PATCH lvconvert 1/2] Fix resume/suspend ordering after temporary mirror insertion Jun'ichi Nomura
2008-02-06 22:05 ` [PATCH lvconvert 2/2] Update dm table of off-tree layer LV on lvconvert Jun'ichi Nomura
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=47AA2CBF.1060109@ce.jp.nec.com \
--to=j-nomura@ce.jp.nec.com \
--cc=lvm-devel@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.