Linux Archive

Linux Archive (http://www.linux-archive.org/)
-   Device-mapper Development (http://www.linux-archive.org/device-mapper-development/)
-   -   FW: the mirror log is NOT kept on disk (http://www.linux-archive.org/device-mapper-development/503679-fw-mirror-log-not-kept-disk.html)

"Eli Malul" 03-21-2011 12:10 PM

FW: the mirror log is NOT kept on disk
 
I just saw that clean_bits is being saved to the disk and is used to update sync_bits after crash/reboot (although the default behavior is to reset all the bits hence, resync is done for each resume).
*
But I still do not understand how should I create a mapped device with dmsetup tool which wouldl survive crash/reboot.
*
Can anyone help?
*
From: Eli Malul
Sent: Sunday, March 20, 2011 6:19 PM
To: 'dm-devel@redhat.com'
Subject: the mirror log is NOT kept on disk
*
Hi,
*
I tried a small test where I suspended and resumed a mirrored device without IO going on.
My expectation was that the mirror set will not get re-synced but unfortunately it did.
*
According the documentation the mirror log is kept on disk when creating a mirror logical device with 'disk' log type as an input parameter.
I looked at the code and I didn't see where the sync_bits are being written to the disk or read from the disk but only the number of regions is being saved.
*
How should a mirror device survive reboots/crashes without syncing the entire mirror set?
*
BTW – another problem is that after reboot the created logical device disappears, is there an easy way to keep it persistent or should I create at each boot?
*
--
dm-devel mailing list
dm-devel@redhat.com
https://www.redhat.com/mailman/listinfo/dm-devel

Milan Broz 03-21-2011 12:26 PM

FW: the mirror log is NOT kept on disk
 
On 03/21/2011 02:10 PM, Eli Malul wrote:

> But I still do not understand how should I create a mapped device
> with dmsetup tool which wouldl survive crash/reboot.

You cannot do that without implementing persistent metadata handling
yourself.

Use LVM here. dmsetup is simple wrapper to DM-ioctl, low level utility.

LVM is based on top of that and solves all the problems with persistent
metadata you just found.

Milan

--
dm-devel mailing list
dm-devel@redhat.com
https://www.redhat.com/mailman/listinfo/dm-devel


All times are GMT. The time now is 01:02 PM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.