[Date Prev][Date Next] [Thread Prev][Thread Next]
[Thread Index]
[Date Index]
[Author Index]
Re: [dm-devel] creating two device mapper files for an underline blockdevice
- From: Milan Broz <mbroz redhat com>
- To: device-mapper development <dm-devel redhat com>
- Cc: Sanjana Shari <sanjana linux gmail com>
- Subject: Re: [dm-devel] creating two device mapper files for an underline blockdevice
- Date: Wed, 02 Nov 2011 08:57:35 +0100
On 11/01/2011 06:10 PM, Sanjana Shari wrote:
> Using the remaining of first half of the same blockdevice /dev/loop0.
> This seems to work. So I ma confused here how the mapping works..
There is no magic for linear mapping.
Imagine you have this mapping table
0 8 linear /dev/sdb 1000
8 8 linear /dev/sdc 500
It means you created 16 sectors device consisting of two segments.
First half (sectors 0-7) is mapped to /dev/sdb starting at sector 10000.
(IOW sectors 0-7 of newly mapped device is mapped to sectors 10000-10007 of /dev/sdb)
Second half (sectors 8-15) is mapped to /dev/sdc starting at sector 500.
See dmsetup man page, where linear mapping is described.
Just do not confuse source and destination device offset.
Milan
[Date Prev][Date Next] [Thread Prev][Thread Next]
[Thread Index]
[Date Index]
[Author Index]