* [linux-lvm] I can't have the mirror_log mirrored, LVM complains "there is no suitable space"
@ 2013-07-02 0:14 Alessandro MACUZ
2013-07-02 16:08 ` Alessandro MACUZ
2013-07-04 11:18 ` Alasdair G Kergon
0 siblings, 2 replies; 10+ messages in thread
From: Alessandro MACUZ @ 2013-07-02 0:14 UTC (permalink / raw)
To: LVM general discussion and development
[-- Attachment #1: Type: text/plain, Size: 4213 bytes --]
The process here below is self-explanatory of what happens.
Starting with one volume (on /dev/sda1) I'd like to mirror it on /dev/sdb1
and having the mirror_log mirrored as well.
Though I think there is plenty of PE I get the error message
Insufficient suitable allocatable extents for logical volume : 1536 more
required
Unable to allocate extents for mirror(s).
I mean the mirror_log is one PE, i.e. 4 Megabytes...
Why "*lvconvert -i 5 -m1 --mirrorlog mirrored /dev/lvgrptstnlvm/root
/dev/sdb1*" doesn't work whereas
"*lvconvert -m1 /dev/lvgrptstnlvm/root /dev/sdb1*" does? The space to be
allocated differs by just one PE.
I'm using Knoppix to fix a system due to other problems, I have noticed
there was a (human) design problem with LVM and I want to achieve the goal
of one volume mirrored in 2 parts and 2 mirrors logs each on one disk.
Thanks,
Alex
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
*root@Microknoppix:/home/knoppix# lvs -a -o +devices,lv_size*
LV VG Attr LSize Pool Origin Data% Move
Log Copy% Convert Devices LSize
root lvgrptstnlvm mwi-aom- 6.00g
root_mlog 100.00 root_mimage_0(0),root_mimage_1(0) 6.00g
[root_mimage_0] lvgrptstnlvm iwi-aom-
6.00g
/dev/sda1(0) 6.00g
[root_mimage_1] lvgrptstnlvm iwi-aom-
6.00g
/dev/sdb1(0) 6.00g
[root_mlog] lvgrptstnlvm lwi-aom-
4.00m
/dev/sdb1(1536) 4.00m
*
*
*root@Microknoppix:/home/knoppix# pvs -v -o +pv_pe_count,pv_pe_alloc_count*
Scanning for physical volume names
PV VG Fmt Attr PSize PFree DevSize PV
UUID PE Alloc
/dev/sda1 lvgrptstnlvm lvm2 a-- 9.00g 3.00g 9.00g
5h4peZ-7SVd-MKrH-IQNJ-UACQ-mM7Q-6CVeo5 2303 1536
/dev/sdb1 lvgrptstnlvm lvm2 a-- 7.07g 1.06g 9.00g
VlGEw0-JaqC-THbz-G4mv-yHq5-9Y80-N5ANNQ 1809 1537
*
*
*root@Microknoppix:/home/knoppix# lvs -a -o +devices,lv_size*
LV VG Attr LSize Pool Origin Data% Move
Log Copy% Convert Devices LSize
root lvgrptstnlvm mwi-aom- 6.00g
root_mlog 100.00 root_mimage_0(0),root_mimage_1(0) 6.00g
[root_mimage_0] lvgrptstnlvm iwi-aom-
6.00g
/dev/sda1(0) 6.00g
[root_mimage_1] lvgrptstnlvm iwi-aom-
6.00g
/dev/sdb1(0) 6.00g
[root_mlog] lvgrptstnlvm lwi-aom-
4.00m
/dev/sdb1(1536) 4.00m
*
*
*root@Microknoppix:/home/knoppix# lvconvert -m0 /dev/lvgrptstnlvm/root
/dev/sdb1*
/sbin/dmeventd: stat failed: No such file or directory
Logical volume root converted.
*
*
*root@Microknoppix:/home/knoppix# lvconvert -i 5 -m1 --mirrorlog mirrored
/dev/lvgrptstnlvm/root /dev/sdb1*
Insufficient suitable allocatable extents for logical volume : 1536 more
required
Unable to allocate extents for mirror(s).
*
*
*root@Microknoppix:/home/knoppix# lvconvert -m1 /dev/lvgrptstnlvm/root
/dev/sdb1*
lvgrptstnlvm/root: Converted: 0.5%
[...SKIP...]
lvgrptstnlvm/root: Converted: 100.0%
*
*
*root@Microknoppix:/home/knoppix# lvs -a -o +devices,lv_size*
LV VG Attr LSize Pool Origin Data% Move
Log Copy% Convert Devices LSize
root lvgrptstnlvm mwi-aom- 6.00g
root_mlog 100.00 root_mimage_0(0),root_mimage_1(0) 6.00g
[root_mimage_0] lvgrptstnlvm iwi-aom-
6.00g
/dev/sda1(0) 6.00g
[root_mimage_1] lvgrptstnlvm iwi-aom-
6.00g
/dev/sdb1(0) 6.00g
[root_mlog] lvgrptstnlvm lwi-aom-
4.00m
/dev/sdb1(1536) 4.00m
*
*
*root@Microknoppix:/home/knoppix# pvs -v -o +pv_pe_count,pv_pe_alloc_count*
Scanning for physical volume names
PV VG Fmt Attr PSize PFree DevSize PV
UUID PE Alloc
/dev/sda1 lvgrptstnlvm lvm2 a-- 9.00g 3.00g 9.00g
5h4peZ-7SVd-MKrH-IQNJ-UACQ-mM7Q-6CVeo5 2303 1536
/dev/sdb1 lvgrptstnlvm lvm2 a-- 7.07g 1.06g 9.00g
VlGEw0-JaqC-THbz-G4mv-yHq5-9Y80-N5ANNQ 1809 1537
*
*
*root@Microknoppix:/home/knoppix#*
[-- Attachment #2: Type: text/html, Size: 8256 bytes --]
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [linux-lvm] I can't have the mirror_log mirrored, LVM complains "there is no suitable space"
2013-07-02 0:14 [linux-lvm] I can't have the mirror_log mirrored, LVM complains "there is no suitable space" Alessandro MACUZ
@ 2013-07-02 16:08 ` Alessandro MACUZ
2013-07-02 16:24 ` Alessandro MACUZ
2013-07-04 11:18 ` Alasdair G Kergon
1 sibling, 1 reply; 10+ messages in thread
From: Alessandro MACUZ @ 2013-07-02 16:08 UTC (permalink / raw)
To: LVM general discussion and development
[-- Attachment #1: Type: text/plain, Size: 4816 bytes --]
2013/7/2 Alessandro MACUZ <alessandro.macuz@gmail.com>
> The process here below is self-explanatory of what happens.
>
>
> Starting with one volume (on /dev/sda1) I'd like to mirror it on /dev/sdb1
> and having the mirror_log mirrored as well.
>
>
> Though I think there is plenty of PE I get the error message
>
>
> Insufficient suitable allocatable extents for logical volume : 1536 more
> required
>
> Unable to allocate extents for mirror(s).
>
>
> I mean the mirror_log is one PE, i.e. 4 Megabytes...
>
>
> Why "*lvconvert -i 5 -m1 --mirrorlog mirrored /dev/lvgrptstnlvm/root
> /dev/sdb1*" doesn't work whereas
>
> "*lvconvert -m1 /dev/lvgrptstnlvm/root /dev/sdb1*" does? The space to be
> allocated differs by just one PE.
>
>
> I'm using Knoppix to fix a system due to other problems, I have noticed
> there was a (human) design problem with LVM and I want to achieve the goal
> of one volume mirrored in 2 parts and 2 mirrors logs each on one disk.
>
>
> Thanks,
>
>
> Alex
>
>
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>
>
> *root@Microknoppix:/home/knoppix# lvs -a -o +devices,lv_size*
>
> LV VG Attr LSize Pool Origin Data% Move
> Log Copy% Convert Devices LSize
>
> root lvgrptstnlvm mwi-aom- 6.00g
> root_mlog 100.00 root_mimage_0(0),root_mimage_1(0) 6.00g
>
> [root_mimage_0] lvgrptstnlvm iwi-aom-
> 6.00g
> /dev/sda1(0) 6.00g
>
> [root_mimage_1] lvgrptstnlvm iwi-aom-
> 6.00g
> /dev/sdb1(0) 6.00g
>
> [root_mlog] lvgrptstnlvm lwi-aom-
> 4.00m
> /dev/sdb1(1536) 4.00m
>
> *
> *
>
> *root@Microknoppix:/home/knoppix# pvs -v -o +pv_pe_count,pv_pe_alloc_count
> *
>
> Scanning for physical volume names
>
> PV VG Fmt Attr PSize PFree DevSize PV
> UUID PE Alloc
>
> /dev/sda1 lvgrptstnlvm lvm2 a-- 9.00g 3.00g 9.00g
> 5h4peZ-7SVd-MKrH-IQNJ-UACQ-mM7Q-6CVeo5 2303 1536
>
> /dev/sdb1 lvgrptstnlvm lvm2 a-- 7.07g 1.06g 9.00g
> VlGEw0-JaqC-THbz-G4mv-yHq5-9Y80-N5ANNQ 1809 1537
>
> *
> *
>
> *root@Microknoppix:/home/knoppix# lvs -a -o +devices,lv_size*
>
> LV VG Attr LSize Pool Origin Data% Move
> Log Copy% Convert Devices LSize
>
> root lvgrptstnlvm mwi-aom- 6.00g
> root_mlog 100.00 root_mimage_0(0),root_mimage_1(0) 6.00g
>
> [root_mimage_0] lvgrptstnlvm iwi-aom-
> 6.00g
> /dev/sda1(0) 6.00g
>
> [root_mimage_1] lvgrptstnlvm iwi-aom-
> 6.00g
> /dev/sdb1(0) 6.00g
>
> [root_mlog] lvgrptstnlvm lwi-aom-
> 4.00m
> /dev/sdb1(1536) 4.00m
>
> *
> *
>
> *root@Microknoppix:/home/knoppix# lvconvert -m0 /dev/lvgrptstnlvm/root
> /dev/sdb1*
>
> /sbin/dmeventd: stat failed: No such file or directory
>
> Logical volume root converted.
>
> *
> *
>
> *root@Microknoppix:/home/knoppix# lvconvert -i 5 -m1 --mirrorlog mirrored
> /dev/lvgrptstnlvm/root /dev/sdb1*
>
> Insufficient suitable allocatable extents for logical volume : 1536 more
> required
>
> Unable to allocate extents for mirror(s).
>
> *
> *
>
> *root@Microknoppix:/home/knoppix# lvconvert -m1 /dev/lvgrptstnlvm/root
> /dev/sdb1*
>
> lvgrptstnlvm/root: Converted: 0.5%
>
> [...SKIP...]
> lvgrptstnlvm/root: Converted: 100.0%
>
> *
> *
>
> *root@Microknoppix:/home/knoppix# lvs -a -o +devices,lv_size*
>
> LV VG Attr LSize Pool Origin Data% Move
> Log Copy% Convert Devices LSize
>
> root lvgrptstnlvm mwi-aom- 6.00g
> root_mlog 100.00 root_mimage_0(0),root_mimage_1(0) 6.00g
>
> [root_mimage_0] lvgrptstnlvm iwi-aom-
> 6.00g
> /dev/sda1(0) 6.00g
>
> [root_mimage_1] lvgrptstnlvm iwi-aom-
> 6.00g
> /dev/sdb1(0) 6.00g
>
> [root_mlog] lvgrptstnlvm lwi-aom-
> 4.00m
> /dev/sdb1(1536) 4.00m
>
> *
> *
>
> *root@Microknoppix:/home/knoppix# pvs -v -o +pv_pe_count,pv_pe_alloc_count
> *
>
> Scanning for physical volume names
>
> PV VG Fmt Attr PSize PFree DevSize PV
> UUID PE Alloc
>
> /dev/sda1 lvgrptstnlvm lvm2 a-- 9.00g 3.00g 9.00g
> 5h4peZ-7SVd-MKrH-IQNJ-UACQ-mM7Q-6CVeo5 2303 1536
>
> /dev/sdb1 lvgrptstnlvm lvm2 a-- 7.07g 1.06g 9.00g
> VlGEw0-JaqC-THbz-G4mv-yHq5-9Y80-N5ANNQ 1809 1537
>
> *
> *
>
> *root@Microknoppix:/home/knoppix#*
>
Same result if done from a Debian LiveCD. If there are a lot of PEs why LVM
complains it is not suitable, in my case it needs just 1 PE.
I used --alloc anywherebut it noticed the two mirror-logs were on the same
disk, thing that I don't want of course...
[-- Attachment #2: Type: text/html, Size: 8887 bytes --]
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [linux-lvm] I can't have the mirror_log mirrored, LVM complains "there is no suitable space"
2013-07-02 16:08 ` Alessandro MACUZ
@ 2013-07-02 16:24 ` Alessandro MACUZ
2013-07-03 22:44 ` Alessandro MACUZ
0 siblings, 1 reply; 10+ messages in thread
From: Alessandro MACUZ @ 2013-07-02 16:24 UTC (permalink / raw)
To: LVM general discussion and development
[-- Attachment #1: Type: text/plain, Size: 1880 bytes --]
> Same result if done from a Debian LiveCD. If there are a lot of PEs why
> LVM complains it is not suitable, in my case it needs just 1 PE.
>
> I used --alloc anywherebut it noticed the two mirror-logs were on the same
> disk, thing that I don't want of course...
>
Here's the proof fro the test --alloc anywhere
root@debian:/home/user# lvs -a -o+devices
LV VG Attr LSize Pool Origin Data% Move
Log Copy% Convert Devices
root lvgrptstnlvm mwi-a-m- 6.00g
root_mlog 100.00 root_mimage_0(0),root_mimage_1(0)
[root_mimage_0] lvgrptstnlvm iwi-aom- 6.00g
/dev/sda1(0)
[root_mimage_1] lvgrptstnlvm iwi-aom- 6.00g
/dev/sdb1(0)
[root_mlog] lvgrptstnlvm mwa-aom- 4.00m
100.00 root_mlog_mimage_0(0),root_mlog_mimage_1(0)
[root_mlog_mimage_0] lvgrptstnlvm iwi-aom- 4.00m
/dev/sdb1(1536)
[root_mlog_mimage_1] lvgrptstnlvm iwi-aom- 4.00m
/dev/sdb1(1537)
root@debian:/home/user# pvs -a -o+devices,pv_pe_count,pv_pe_alloc_count
PV VG Fmt Attr PSize PFree Devices
PE Alloc
/dev/loop0 --- 0 0
0 0
/dev/lvgrptstnlvm/root --- 0 0
0 0
/dev/sda1 lvgrptstnlvm lvm2 a-- 9.00g 3.00g /dev/sda1(0)
2303 1536
/dev/sda1 lvgrptstnlvm lvm2 a-- 9.00g 3.00g
2303 1536
/dev/sdb1 lvgrptstnlvm lvm2 a-- 7.07g 1.06g /dev/sdb1(0)
1809 1538
/dev/sdb1 lvgrptstnlvm lvm2 a-- 7.07g 1.06g /dev/sdb1(1536)
1809 1538
/dev/sdb1 lvgrptstnlvm lvm2 a-- 7.07g 1.06g /dev/sdb1(1537)
1809 1538
/dev/sdb1 lvgrptstnlvm lvm2 a-- 7.07g 1.06g
1809 1538
Might this be for devs' attention?
Alex
[-- Attachment #2: Type: text/html, Size: 2596 bytes --]
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [linux-lvm] I can't have the mirror_log mirrored, LVM complains "there is no suitable space"
2013-07-02 16:24 ` Alessandro MACUZ
@ 2013-07-03 22:44 ` Alessandro MACUZ
2013-07-04 10:55 ` matthew patton
0 siblings, 1 reply; 10+ messages in thread
From: Alessandro MACUZ @ 2013-07-03 22:44 UTC (permalink / raw)
To: LVM general discussion and development
[-- Attachment #1: Type: text/plain, Size: 566 bytes --]
Ok,
it seems I'm getting closer to the solution.
Thanks to this link
http://serverfault.com/questions/500533/lvm-mirror-with-data-and-logs-mirrored-on-same-2-devices
it seems that what I want to achieve can be done only when creating a new
fresh volume.
Do I really need three logical volumes (the original + those 2 with
redundant mirrorlog on the same disks) or there is a short cut so that I
don't have to find room for the third logical volume?
Thanks to anybody who will be willing to help... I've just started with
LVM, I might not see the obvious.
Alex
[-- Attachment #2: Type: text/html, Size: 737 bytes --]
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [linux-lvm] I can't have the mirror_log mirrored, LVM complains "there is no suitable space"
2013-07-03 22:44 ` Alessandro MACUZ
@ 2013-07-04 10:55 ` matthew patton
2013-07-04 12:45 ` Alessandro MACUZ
0 siblings, 1 reply; 10+ messages in thread
From: matthew patton @ 2013-07-04 10:55 UTC (permalink / raw)
To: LVM general discussion and development
>
>http://serverfault.com/questions/500533/lvm-mirror-with-data-and-logs-mirrored-on-same-2-devices
wow, that smells like a logic bug to me. If not, then the documentation needs a VERY obvious warning about how to properly do mirrored devices with mirrored logs (nee 4+ distinct PV devices). If the internals can't be fixed, then it needs to error out on creation when there aren't 4 devices to work with. Any particular reason why you wanted pseudo-external logs in the first place?
Does 'lvcreate -nv' show you the work plan?
I'd say most people use MD for any sort of RAID functionality. It's implemented better (or at least faster).
>I've just started with LVM, I might not see the obvious.
maybe turn down the exotic, till you have more experience?
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [linux-lvm] I can't have the mirror_log mirrored, LVM complains "there is no suitable space"
2013-07-02 0:14 [linux-lvm] I can't have the mirror_log mirrored, LVM complains "there is no suitable space" Alessandro MACUZ
2013-07-02 16:08 ` Alessandro MACUZ
@ 2013-07-04 11:18 ` Alasdair G Kergon
2013-07-04 11:43 ` Alessandro MACUZ
1 sibling, 1 reply; 10+ messages in thread
From: Alasdair G Kergon @ 2013-07-04 11:18 UTC (permalink / raw)
To: Alessandro MACUZ; +Cc: LVM general discussion and development
On Tue, Jul 02, 2013 at 02:14:01AM +0200, Alessandro MACUZ wrote:
> Why "*lvconvert -i 5 -m1 --mirrorlog mirrored /dev/lvgrptstnlvm/root
> /dev/sdb1*" doesn't work whereas
> "*lvconvert -m1 /dev/lvgrptstnlvm/root /dev/sdb1*" does? The space to be
> allocated differs by just one PE.
Exactly which version of lvm2 are you using?
Is it 2.02.97 or later? If not, you should try a newer version.
To debug, you then need to run the command with -vvvv added to the command
line. Post a link to this output if you want others to look.
Alasdair
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [linux-lvm] I can't have the mirror_log mirrored, LVM complains "there is no suitable space"
2013-07-04 11:18 ` Alasdair G Kergon
@ 2013-07-04 11:43 ` Alessandro MACUZ
2013-07-04 14:27 ` Alessandro MACUZ
0 siblings, 1 reply; 10+ messages in thread
From: Alessandro MACUZ @ 2013-07-04 11:43 UTC (permalink / raw)
To: Alessandro MACUZ, LVM general discussion and development
[-- Attachment #1: Type: text/plain, Size: 1327 bytes --]
2013/7/4 Alasdair G Kergon <agk@redhat.com>
> On Tue, Jul 02, 2013 at 02:14:01AM +0200, Alessandro MACUZ wrote:
> > Why "*lvconvert -i 5 -m1 --mirrorlog mirrored /dev/lvgrptstnlvm/root
> > /dev/sdb1*" doesn't work whereas
> > "*lvconvert -m1 /dev/lvgrptstnlvm/root /dev/sdb1*" does? The space to be
> > allocated differs by just one PE.
>
> Exactly which version of lvm2 are you using?
> Is it 2.02.97 or later? If not, you should try a newer version.
> To debug, you then need to run the command with -vvvv added to the command
> line. Post a link to this output if you want others to look.
On Knoppix
root@Microknoppix:/home/knoppix# lvm version
LVM version: 2.02.95(2) (2012-03-06)
Library version: 1.02.74 (2012-03-06)
Driver version: 4.23.0
On Debian Live CD
LVM version: 2.02.95(2) (2012-03-06)
Library version: 1.02.74 (2012-03-06)
Driver version: 4.22.0
The usage of LVM instead of MD raid was not chosen by me and LVM is a
temporary choice to move VMdisks from local to the NAS (iSCSI)
I'll post the detailed output as I was asked.
I wonder if the problem is only with the creation of the second leg of the
volume and the mirrored mirror_logs. If it so I guess I can use whatever
distro that has LVM version more recent then 2.02.97 and then handle it
with less recent version...
Alex
[-- Attachment #2: Type: text/html, Size: 2203 bytes --]
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [linux-lvm] I can't have the mirror_log mirrored, LVM complains "there is no suitable space"
2013-07-04 10:55 ` matthew patton
@ 2013-07-04 12:45 ` Alessandro MACUZ
0 siblings, 0 replies; 10+ messages in thread
From: Alessandro MACUZ @ 2013-07-04 12:45 UTC (permalink / raw)
To: matthew patton, LVM general discussion and development
[-- Attachment #1: Type: text/plain, Size: 12471 bytes --]
2013/7/4 matthew patton <pattonme@yahoo.com>
>
>
> >
> >
> http://serverfault.com/questions/500533/lvm-mirror-with-data-and-logs-mirrored-on-same-2-devices
>
> wow, that smells like a logic bug to me. If not, then the documentation
> needs a VERY obvious warning about how to properly do mirrored devices with
> mirrored logs (nee 4+ distinct PV devices). If the internals can't be
> fixed, then it needs to error out on creation when there aren't 4 devices
> to work with. Any particular reason why you wanted pseudo-external logs in
> the first place?
>
> Does 'lvcreate -nv' show you the work plan?
>
>
Yet lvconvert looks the right tool for me if I could overcome this
limitation. I guess you meant 'lvconvert' instead of 'lvcreate' because
lvcreate works fine and I don't think it needs to be debugged. The only
drawback is that I need a much more complicated migration.
In case you needed the "lvconvert" here it is (pretty long) the output of
lvconvert -vvv -m1 --mirrorlog mirrored /dev/lvgrptstnlvm/root /dev/sdb1
root@debian:/home/user# lvconvert -vvv -m1 --mirrorlog mirrored
/dev/lvgrptstnlvm/root /dev/sdb1
Processing: lvconvert -vvv -m1 --mirrorlog mirrored
/dev/lvgrptstnlvm/root /dev/sdb1
O_DIRECT will be used
Setting global/locking_type to 1
Setting global/wait_for_locks to 1
File-based locking selected.
Setting global/locking_dir to /run/lock/lvm
Setting activation/mirror_region_size to 512
Getting target version for mirror
dm versions OF [16384] (*1)
Getting target version for mirror
dm versions OF [16384] (*1)
Locking /run/lock/lvm/V_lvgrptstnlvm WB
_do_flock /run/lock/lvm/V_lvgrptstnlvm:aux WB
_do_flock /run/lock/lvm/V_lvgrptstnlvm WB
_undo_flock /run/lock/lvm/V_lvgrptstnlvm:aux
/dev/sr0: Added to device cache
/dev/cdrom: Aliased to /dev/sr0 in device cache (preferred name)
/dev/cdrw: Aliased to /dev/cdrom in device cache
/dev/disk/by-id/ata-VMware_Virtual_IDE_CDROM_Drive_10000000000000000001:
Aliased to /dev/cdrom in device cache
/dev/disk/by-label/Debian\x20wheezy\x2020130505-08:21: Aliased to
/dev/cdrom in device cache
/dev/disk/by-path/pci-0000:00:07.1-scsi-1:0:0:0: Aliased to
/dev/cdrom in device cache
/dev/dvd: Aliased to /dev/cdrom in device cache
/dev/dvdrw: Aliased to /dev/cdrom in device cache
/dev/sda: Added to device cache
/dev/disk/by-path/pci-0000:00:10.0-scsi-0:0:0:0: Aliased to
/dev/sda in device cache
/dev/sda1: Added to device cache
/dev/disk/by-path/pci-0000:00:10.0-scsi-0:0:0:0-part1: Aliased to
/dev/sda1 in device cache
/dev/sdb: Added to device cache
/dev/disk/by-id/scsi-26362623865306265: Aliased to /dev/sdb in
device cache
/dev/disk/by-path/pci-0000:00:10.0-scsi-0:0:1:0: Aliased to
/dev/sdb in device cache
/dev/sdb1: Added to device cache
/dev/disk/by-id/scsi-26362623865306265-part1: Aliased to /dev/sdb1
in device cache
/dev/disk/by-path/pci-0000:00:10.0-scsi-0:0:1:0-part1: Aliased to
/dev/sdb1 in device cache
/dev/sdb2: Added to device cache
/dev/disk/by-id/scsi-26362623865306265-part2: Aliased to /dev/sdb2
in device cache
/dev/disk/by-path/pci-0000:00:10.0-scsi-0:0:1:0-part2: Aliased to
/dev/sdb2 in device cache
/dev/fd0: Added to device cache
/dev/loop0: Added to device cache
/dev/loop1: Added to device cache
/dev/loop2: Added to device cache
/dev/loop3: Added to device cache
/dev/loop4: Added to device cache
/dev/loop5: Added to device cache
/dev/loop6: Added to device cache
/dev/loop7: Added to device cache
/dev/dm-0: Added to device cache
/dev/disk/by-id/dm-name-lvgrptstnlvm-root: Aliased to /dev/dm-0 in
device cache (preferred name)
/dev/disk/by-id/dm-uuid-LVM-DxeZ119H0aLSu7DzkC21nfqolp4rPTBpNTJpPI2EvQWsK2Xd5eoSvk4x8slmPVYC:
Aliased to /dev/disk/by-id/dm-name-lvgrptstnlvm-root in device cache
/dev/disk/by-uuid/2e715f19-ad02-44d8-9e06-e1ac5e302dfd: Aliased to
/dev/disk/by-id/dm-name-lvgrptstnlvm-root in device cache
/dev/lvgrptstnlvm/root: Aliased to
/dev/disk/by-id/dm-name-lvgrptstnlvm-root in device cache (preferred name)
/dev/mapper/lvgrptstnlvm-root: Aliased to /dev/lvgrptstnlvm/root in
device cache
/dev/fd0: Skipping: Unrecognised LVM device type 2
Opened /dev/loop0 RO O_DIRECT
/dev/loop0: size is 1094288 sectors
Closed /dev/loop0
/dev/loop0: size is 1094288 sectors
Opened /dev/loop0 RO O_DIRECT
/dev/loop0: block size is 1024 bytes
Closed /dev/loop0
Using /dev/loop0
Opened /dev/loop0 RO O_DIRECT
/dev/loop0: block size is 1024 bytes
/dev/loop0: No label detected
Closed /dev/loop0
Opened /dev/sda RO O_DIRECT
/dev/sda: size is 18874368 sectors
/dev/sda: block size is 4096 bytes
/dev/sda: Skipping: Partition table signature found
Closed /dev/sda
/dev/cdrom: Skipping: Unrecognised LVM device type 11
dm status (254:0) OF [16384] (*1)
Opened /dev/lvgrptstnlvm/root RO O_DIRECT
/dev/lvgrptstnlvm/root: size is 12582912 sectors
Closed /dev/lvgrptstnlvm/root
/dev/lvgrptstnlvm/root: size is 12582912 sectors
Opened /dev/lvgrptstnlvm/root RO O_DIRECT
/dev/lvgrptstnlvm/root: block size is 4096 bytes
Closed /dev/lvgrptstnlvm/root
Using /dev/lvgrptstnlvm/root
Opened /dev/lvgrptstnlvm/root RO O_DIRECT
/dev/lvgrptstnlvm/root: block size is 4096 bytes
/dev/lvgrptstnlvm/root: No label detected
Closed /dev/lvgrptstnlvm/root
Opened /dev/loop1 RO O_DIRECT
/dev/loop1: size is 0 sectors
/dev/loop1: Skipping: Too small to hold a PV
Closed /dev/loop1
Opened /dev/sda1 RO O_DIRECT
/dev/sda1: size is 18872320 sectors
Closed /dev/sda1
/dev/sda1: size is 18872320 sectors
Opened /dev/sda1 RO O_DIRECT
/dev/sda1: block size is 4096 bytes
Closed /dev/sda1
Using /dev/sda1
Opened /dev/sda1 RO O_DIRECT
/dev/sda1: block size is 4096 bytes
/dev/sda1: lvm2 label detected at sector 1
lvmcache: /dev/sda1: now in VG #orphans_lvm2 (#orphans_lvm2) with 0
mdas
/dev/sda1: Found metadata at 42496 size 1283 (in area at 4096 size
192512) for lvgrptstnlvm (DxeZ11-9H0a-LSu7-DzkC-21nf-qolp-4rPTBp)
lvmcache: /dev/sda1: now in VG lvgrptstnlvm with 1 mdas
lvmcache: /dev/sda1: setting lvgrptstnlvm VGID to
DxeZ119H0aLSu7DzkC21nfqolp4rPTBp
lvmcache: /dev/sda1: VG lvgrptstnlvm: Set creation host to debian.
Opened /dev/loop2 RO O_DIRECT
/dev/loop2: size is 0 sectors
/dev/loop2: Skipping: Too small to hold a PV
Closed /dev/loop2
Opened /dev/loop3 RO O_DIRECT
/dev/loop3: size is 0 sectors
/dev/loop3: Skipping: Too small to hold a PV
Closed /dev/loop3
Opened /dev/loop4 RO O_DIRECT
/dev/loop4: size is 0 sectors
/dev/loop4: Skipping: Too small to hold a PV
Closed /dev/loop4
Opened /dev/loop5 RO O_DIRECT
/dev/loop5: size is 0 sectors
/dev/loop5: Skipping: Too small to hold a PV
Closed /dev/loop5
Opened /dev/loop6 RO O_DIRECT
/dev/loop6: size is 0 sectors
/dev/loop6: Skipping: Too small to hold a PV
Closed /dev/loop6
Opened /dev/loop7 RO O_DIRECT
/dev/loop7: size is 0 sectors
/dev/loop7: Skipping: Too small to hold a PV
Closed /dev/loop7
Opened /dev/sdb RO O_DIRECT
/dev/sdb: size is 18874368 sectors
/dev/sdb: block size is 4096 bytes
/dev/sdb: Skipping: Partition table signature found
Closed /dev/sdb
Opened /dev/sdb1 RO O_DIRECT
/dev/sdb1: size is 18610176 sectors
Closed /dev/sdb1
/dev/sdb1: size is 18610176 sectors
Opened /dev/sdb1 RO O_DIRECT
/dev/sdb1: block size is 4096 bytes
Closed /dev/sdb1
Using /dev/sdb1
Opened /dev/sdb1 RO O_DIRECT
/dev/sdb1: block size is 4096 bytes
/dev/sdb1: lvm2 label detected at sector 1
lvmcache: /dev/sdb1: now in VG #orphans_lvm2 (#orphans_lvm2) with 0
mdas
/dev/sdb1: Found metadata at 6144 size 1283 (in area at 4096 size
520192) for lvgrptstnlvm (DxeZ11-9H0a-LSu7-DzkC-21nf-qolp-4rPTBp)
lvmcache: /dev/sdb1: now in VG lvgrptstnlvm
(DxeZ119H0aLSu7DzkC21nfqolp4rPTBp) with 1 mdas
Opened /dev/sdb2 RO O_DIRECT
/dev/sdb2: size is 262144 sectors
Closed /dev/sdb2
/dev/sdb2: size is 262144 sectors
Opened /dev/sdb2 RO O_DIRECT
/dev/sdb2: block size is 4096 bytes
Closed /dev/sdb2
Using /dev/sdb2
Opened /dev/sdb2 RO O_DIRECT
/dev/sdb2: block size is 4096 bytes
/dev/sdb2: lvm2 label detected at sector 1
lvmcache: /dev/sdb2: now in VG #orphans_lvm2 (#orphans_lvm2) with 0
mdas
/dev/sdb2: Found metadata at 4608 size 1283 (in area at 4096 size
1044480) for lvgrptstnlvm (DxeZ11-9H0a-LSu7-DzkC-21nf-qolp-4rPTBp)
lvmcache: /dev/sdb2: now in VG lvgrptstnlvm
(DxeZ119H0aLSu7DzkC21nfqolp4rPTBp) with 1 mdas
Using cached label for /dev/sda1
Using cached label for /dev/sdb1
Using cached label for /dev/sdb2
Allocated VG lvgrptstnlvm at 0x2732230.
Using cached label for /dev/sda1
Using cached label for /dev/sdb1
Using cached label for /dev/sdb2
Read lvgrptstnlvm metadata (109) from /dev/sda1 at 42496 size 1283
Allocated VG lvgrptstnlvm at 0x2736240.
Using cached label for /dev/sda1
Using cached label for /dev/sdb1
Using cached label for /dev/sdb2
Read lvgrptstnlvm metadata (109) from /dev/sdb1 at 6144 size 1283
Freeing VG lvgrptstnlvm at 0x2736240.
Allocated VG lvgrptstnlvm at 0x2736240.
Using cached label for /dev/sda1
Using cached label for /dev/sdb1
Using cached label for /dev/sdb2
Read lvgrptstnlvm metadata (109) from /dev/sdb2 at 4608 size 1283
Freeing VG lvgrptstnlvm at 0x2736240.
/dev/sda1 0: 0 1536: root(0:0)
/dev/sda1 1: 1536 767: NULL(0:0)
/dev/sdb1 0: 0 2271: NULL(0:0)
/dev/sdb2 0: 0 31: NULL(0:0)
Adding PE range: start PE 0 length 2271 on /dev/sdb1
Archiving volume group "lvgrptstnlvm" metadata (seqno 109).
Adjusting mirror image count of root
Setting logging type to mirrored
Allowing allocation on /dev/sdb1 start PE 0 length 2271
Parallel PVs at LE 0 length 1536: /dev/sda1
Trying allocation using contiguous policy.
Still need 1538 total extents:
1 (1 data/0 parity) parallel areas of 1536 extents each
2 mirror logs of 1 extents each
Considering allocation area 0 as /dev/sdb1 start PE 0 length 1536
leaving 735.
Trying allocation using cling policy.
Still need 1538 total extents:
1 (1 data/0 parity) parallel areas of 1536 extents each
2 mirror logs of 1 extents each
Considering allocation area 0 as /dev/sdb1 start PE 0 length 1536
leaving 735.
Trying allocation using normal policy.
Cling_to_allocated is set
Still need 1538 total extents:
1 (1 data/0 parity) parallel areas of 1536 extents each
2 mirror logs of 1 extents each
Cling_to_allocated is not set
Still need 1538 total extents:
1 (1 data/0 parity) parallel areas of 1536 extents each
2 mirror logs of 1 extents each
Considering allocation area 0 as /dev/sdb1 start PE 0 length 1536
leaving 735.
Found 1 areas for 1 parallel areas and 2 log areas so far.
Considering allocation area 1 as /dev/sdb1 start PE 0 length 735
leaving 0.
Insufficient suitable allocatable extents for logical volume : 1536 more
required
Unable to allocate extents for mirror(s).
Unlock: Memlock counters: locked:0 critical:0 daemon:0 suspended:0
Syncing device names
Unlocking /run/lock/lvm/V_lvgrptstnlvm
_undo_flock /run/lock/lvm/V_lvgrptstnlvm
Closed /dev/sda1
Closed /dev/sdb1
Closed /dev/sdb2
Freeing VG lvgrptstnlvm at 0x2732230.
[-- Attachment #2: Type: text/html, Size: 15404 bytes --]
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [linux-lvm] I can't have the mirror_log mirrored, LVM complains "there is no suitable space"
2013-07-04 11:43 ` Alessandro MACUZ
@ 2013-07-04 14:27 ` Alessandro MACUZ
2013-07-04 16:40 ` Alasdair G Kergon
0 siblings, 1 reply; 10+ messages in thread
From: Alessandro MACUZ @ 2013-07-04 14:27 UTC (permalink / raw)
To: Alessandro MACUZ, LVM general discussion and development
[-- Attachment #1: Type: text/plain, Size: 11600 bytes --]
2013/7/4 Alessandro MACUZ <alessandro.macuz@gmail.com>
> 2013/7/4 Alasdair G Kergon <agk@redhat.com>
>
>> On Tue, Jul 02, 2013 at 02:14:01AM +0200, Alessandro MACUZ wrote:
>> > Why "*lvconvert -i 5 -m1 --mirrorlog mirrored /dev/lvgrptstnlvm/root
>> > /dev/sdb1*" doesn't work whereas
>> > "*lvconvert -m1 /dev/lvgrptstnlvm/root /dev/sdb1*" does? The space to be
>> > allocated differs by just one PE.
>>
>> Exactly which version of lvm2 are you using?
>> Is it 2.02.97 or later? If not, you should try a newer version.
>> To debug, you then need to run the command with -vvvv added to the command
>> line. Post a link to this output if you want others to look.
>
>
I downloaded
https://git.fedorahosted.org/cgit/lvm2.git/snapshot/lvm2-2_02_98.tar.gz and
compiled/installed via
./configure
make
make install
on top of a Knoppix Live DVD
No errors in compiling and installing it.
Unfortunately I get the same error. This is the output of LVM2 2.02.98
command:
root@Microknoppix:/tmp/lvm2-2_02_98# lvs -a -o+devices
LV VG Attr LSize Pool Origin Data% Move Log Copy%
Convert Devices
root lvgrptstnlvm -wi-a---- 6.00g
/dev/sda1(0)
root@Microknoppix:/tmp/lvm2-2_02_98# lvconvert -vvv -m1 --mirrorlog
mirrored --alloc normal /dev/lvgrptstnlvm/root /dev/sdb1
Setting activation/monitoring to 0
Processing: lvconvert -vvv -m1 --mirrorlog mirrored --alloc normal
/dev/lvgrptstnlvm/root /dev/sdb1
O_DIRECT will be used
Setting global/locking_type to 1
Setting global/wait_for_locks to 1
File-based locking selected.
Setting global/locking_dir to /run/lock/lvm
Setting global/prioritise_write_locks to 1
Setting activation/mirror_region_size to 512
Getting target version for mirror
dm version OF [16384] (*1)
dm versions OF [16384] (*1)
Found mirror target v1.12.1.
Getting target version for mirror
dm versions OF [16384] (*1)
Found mirror target v1.12.1.
Locking /run/lock/lvm/V_lvgrptstnlvm WB
_do_flock /run/lock/lvm/V_lvgrptstnlvm:aux WB
_do_flock /run/lock/lvm/V_lvgrptstnlvm WB
_undo_flock /run/lock/lvm/V_lvgrptstnlvm:aux
Opened /dev/ram0 RO O_DIRECT
/dev/ram0: block size is 4096 bytes
/dev/ram0: No label detected
Closed /dev/ram0
dm status (252:0) OF [16384] (*1)
/dev/lvgrptstnlvm/root_mlog_mimage_0: Reserved internal LV device
lvgrptstnlvm/root_mlog_mimage_0 not usable.
/dev/lvgrptstnlvm/root_mlog_mimage_0: Skipping unusable device
Opened /dev/ram RO O_DIRECT
/dev/ram: block size is 4096 bytes
/dev/ram: No label detected
Closed /dev/ram
Opened /dev/sda1 RO O_DIRECT
/dev/sda1: block size is 4096 bytes
/dev/sda1: lvm2 label detected at sector 1
lvmcache: /dev/sda1: now in VG #orphans_lvm2 (#orphans_lvm2) with 0
mdas
/dev/sda1: Found metadata at 67584 size 1470 (in area at 4096 size
192512) for lvgrptstnlvm (DxeZ11-9H0a-LSu7-DzkC-21nf-qolp-4rPTBp)
lvmcache: /dev/sda1: now in VG lvgrptstnlvm with 1 mdas
lvmcache: /dev/sda1: setting lvgrptstnlvm VGID to
DxeZ119H0aLSu7DzkC21nfqolp4rPTBp
lvmcache: /dev/sda1: VG lvgrptstnlvm: Set creation host to
Microknoppix.
dm status (252:1) OF [16384] (*1)
/dev/lvgrptstnlvm/root_mlog_mimage_1: Reserved internal LV device
lvgrptstnlvm/root_mlog_mimage_1 not usable.
/dev/lvgrptstnlvm/root_mlog_mimage_1: Skipping unusable device
Opened /dev/ram2 RO O_DIRECT
/dev/ram2: block size is 4096 bytes
/dev/ram2: No label detected
Closed /dev/ram2
dm status (252:2) OF [16384] (*1)
/dev/dm-2: Skipping unusable device
Opened /dev/ram3 RO O_DIRECT
/dev/ram3: block size is 4096 bytes
/dev/ram3: No label detected
Closed /dev/ram3
dm status (252:3) OF [16384] (*1)
/dev/dm-3: Skipping unusable device
Opened /dev/ram4 RO O_DIRECT
/dev/ram4: block size is 4096 bytes
/dev/ram4: No label detected
Closed /dev/ram4
dm status (252:4) OF [16384] (*1)
/dev/dm-4: Skipping unusable device
Opened /dev/ram5 RO O_DIRECT
/dev/ram5: block size is 4096 bytes
/dev/ram5: No label detected
Closed /dev/ram5
dm status (252:5) OF [16384] (*1)
Opened /dev/lvgrptstnlvm/root RO O_DIRECT
/dev/lvgrptstnlvm/root: size is 12582912 sectors
Closed /dev/lvgrptstnlvm/root
/dev/lvgrptstnlvm/root: size is 12582912 sectors
Opened /dev/lvgrptstnlvm/root RO O_DIRECT
/dev/lvgrptstnlvm/root: block size is 4096 bytes
Closed /dev/lvgrptstnlvm/root
Using /dev/lvgrptstnlvm/root
Opened /dev/lvgrptstnlvm/root RO O_DIRECT
/dev/lvgrptstnlvm/root: block size is 4096 bytes
/dev/lvgrptstnlvm/root: No label detected
Closed /dev/lvgrptstnlvm/root
Opened /dev/ram6 RO O_DIRECT
/dev/ram6: block size is 4096 bytes
/dev/ram6: No label detected
Closed /dev/ram6
Opened /dev/ram7 RO O_DIRECT
/dev/ram7: block size is 4096 bytes
/dev/ram7: No label detected
Closed /dev/ram7
Opened /dev/ram8 RO O_DIRECT
/dev/ram8: block size is 4096 bytes
/dev/ram8: No label detected
Closed /dev/ram8
Opened /dev/ram9 RO O_DIRECT
/dev/ram9: block size is 4096 bytes
/dev/ram9: No label detected
Closed /dev/ram9
Opened /dev/ram10 RO O_DIRECT
/dev/ram10: block size is 4096 bytes
/dev/ram10: No label detected
Closed /dev/ram10
Opened /dev/ram11 RO O_DIRECT
/dev/ram11: block size is 4096 bytes
/dev/ram11: No label detected
Closed /dev/ram11
Opened /dev/ram12 RO O_DIRECT
/dev/ram12: block size is 4096 bytes
/dev/ram12: No label detected
Closed /dev/ram12
Opened /dev/ram13 RO O_DIRECT
/dev/ram13: block size is 4096 bytes
/dev/ram13: No label detected
Closed /dev/ram13
Opened /dev/ram14 RO O_DIRECT
/dev/ram14: block size is 4096 bytes
/dev/ram14: No label detected
Closed /dev/ram14
Opened /dev/ram15 RO O_DIRECT
/dev/ram15: block size is 4096 bytes
/dev/ram15: No label detected
Closed /dev/ram15
Opened /dev/sdb1 RO O_DIRECT
/dev/sdb1: block size is 4096 bytes
/dev/sdb1: lvm2 label detected at sector 1
lvmcache: /dev/sdb1: now in VG #orphans_lvm2 (#orphans_lvm2) with 0
mdas
/dev/sdb1: Found metadata at 31232 size 1470 (in area at 4096 size
520192) for lvgrptstnlvm (DxeZ11-9H0a-LSu7-DzkC-21nf-qolp-4rPTBp)
lvmcache: /dev/sdb1: now in VG lvgrptstnlvm
(DxeZ119H0aLSu7DzkC21nfqolp4rPTBp) with 1 mdas
Opened /dev/sdb2 RO O_DIRECT
/dev/sdb2: block size is 4096 bytes
/dev/sdb2: lvm2 label detected at sector 1
lvmcache: /dev/sdb2: now in VG #orphans_lvm2 (#orphans_lvm2) with 0
mdas
/dev/sdb2: Found metadata at 29696 size 1470 (in area at 4096 size
1044480) for lvgrptstnlvm (DxeZ11-9H0a-LSu7-DzkC-21nf-qolp-4rPTBp)
lvmcache: /dev/sdb2: now in VG lvgrptstnlvm
(DxeZ119H0aLSu7DzkC21nfqolp4rPTBp) with 1 mdas
Opened /dev/sdc RO O_DIRECT
/dev/sdc: block size is 4096 bytes
/dev/sdc: lvm2 label detected at sector 1
lvmcache: /dev/sdc: now in VG #orphans_lvm2 (#orphans_lvm2) with 0
mdas
/dev/sdc: Found metadata at 28160 size 1470 (in area at 4096 size
1044480) for lvgrptstnlvm (DxeZ11-9H0a-LSu7-DzkC-21nf-qolp-4rPTBp)
lvmcache: /dev/sdc: now in VG lvgrptstnlvm
(DxeZ119H0aLSu7DzkC21nfqolp4rPTBp) with 1 mdas
Using cached label for /dev/sda1
Using cached label for /dev/sdb1
Using cached label for /dev/sdb2
Using cached label for /dev/sdc
Allocated VG lvgrptstnlvm at 0x8194c58.
Using cached label for /dev/sda1
Using cached label for /dev/sdb1
Using cached label for /dev/sdb2
Using cached label for /dev/sdc
Read lvgrptstnlvm metadata (119) from /dev/sda1 at 67584 size 1470
Allocated VG lvgrptstnlvm at 0x8198c60.
Using cached label for /dev/sda1
Using cached label for /dev/sdb1
Using cached label for /dev/sdb2
Using cached label for /dev/sdc
Read lvgrptstnlvm metadata (119) from /dev/sdb1 at 31232 size 1470
Freeing VG lvgrptstnlvm at 0x8198c60.
Allocated VG lvgrptstnlvm at 0x8198c60.
Using cached label for /dev/sda1
Using cached label for /dev/sdb1
Using cached label for /dev/sdb2
Using cached label for /dev/sdc
Read lvgrptstnlvm metadata (119) from /dev/sdb2 at 29696 size 1470
Freeing VG lvgrptstnlvm at 0x8198c60.
Allocated VG lvgrptstnlvm at 0x8198c60.
Using cached label for /dev/sda1
Using cached label for /dev/sdb1
Using cached label for /dev/sdb2
Using cached label for /dev/sdc
Read lvgrptstnlvm metadata (119) from /dev/sdc at 28160 size 1470
Freeing VG lvgrptstnlvm at 0x8198c60.
/dev/sda1 0: 0 1536: root(0:0)
/dev/sda1 1: 1536 767: NULL(0:0)
/dev/sdb1 0: 0 2271: NULL(0:0)
/dev/sdb2 0: 0 31: NULL(0:0)
/dev/sdc 0: 0 7: NULL(0:0)
Adding PE range: start PE 0 length 2271 on /dev/sdb1
Archiving volume group "lvgrptstnlvm" metadata (seqno 119).
Adjusting mirror image count of root
Setting logging type to mirrored
allocation/mirror_logs_require_separate_pvs not found in config:
defaulting to 0
allocation/maximise_cling not found in config: defaulting to 1
Allowing allocation on /dev/sdb1 start PE 0 length 2271
Parallel PVs at LE 0 length 1536: /dev/sda1
Trying allocation using contiguous policy.
Still need 1538 total extents:
1 (1 data/0 parity) parallel areas of 1536 extents each
2 mirror logs of 1 extents each
Considering allocation area 0 as /dev/sdb1 start PE 0 length 1536
leaving 735.
Trying allocation using cling policy.
Cling_to_allocated is set
Still need 1538 total extents:
1 (1 data/0 parity) parallel areas of 1536 extents each
2 mirror logs of 1 extents each
Trying allocation using normal policy.
Cling_to_allocated is set
Still need 1538 total extents:
1 (1 data/0 parity) parallel areas of 1536 extents each
2 mirror logs of 1 extents each
Cling_to_allocated is not set
Still need 1538 total extents:
1 (1 data/0 parity) parallel areas of 1536 extents each
2 mirror logs of 1 extents each
Considering allocation area 0 as /dev/sdb1 start PE 0 length 1536
leaving 735.
Found 1 areas for 1 parallel areas and 2 log areas so far.
Considering allocation area 1 as /dev/sdb1 start PE 0 length 735
leaving 0.
Insufficient suitable allocatable extents for logical volume : 1536 more
required
Unable to allocate extents for mirror(s).
Unlock: Memlock counters: locked:0 critical:0 daemon:0 suspended:0
Syncing device names
Unlocking /run/lock/lvm/V_lvgrptstnlvm
_undo_flock /run/lock/lvm/V_lvgrptstnlvm
Closed /dev/sda1
Closed /dev/sdb1
Closed /dev/sdb2
Closed /dev/sdc
Freeing VG lvgrptstnlvm at 0x8194c58.
root@Microknoppix:/tmp/lvm2-2_02_98#
Alex
[-- Attachment #2: Type: text/html, Size: 14862 bytes --]
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: [linux-lvm] I can't have the mirror_log mirrored, LVM complains "there is no suitable space"
2013-07-04 14:27 ` Alessandro MACUZ
@ 2013-07-04 16:40 ` Alasdair G Kergon
0 siblings, 0 replies; 10+ messages in thread
From: Alasdair G Kergon @ 2013-07-04 16:40 UTC (permalink / raw)
To: Alessandro MACUZ; +Cc: LVM general discussion and development
On Thu, Jul 04, 2013 at 04:27:51PM +0200, Alessandro MACUZ wrote:
> root@Microknoppix:/tmp/lvm2-2_02_98# lvconvert -vvv -m1 --mirrorlog
> mirrored --alloc normal /dev/lvgrptstnlvm/root /dev/sdb1
So you want to convert an existing LV into a mirror (-m1) with a mirrored log
with the default allocation policy allocating all new extents from /dev/sdb1.
The current layout:
> /dev/sda1 0: 0 1536: root(0:0)
> /dev/sda1 1: 1536 767: NULL(0:0)
> /dev/sdb1 0: 0 2271: NULL(0:0)
> /dev/sdb2 0: 0 31: NULL(0:0)
> /dev/sdc 0: 0 7: NULL(0:0)
The Physical Extents that can used for allocation during this process:
> Adding PE range: start PE 0 length 2271 on /dev/sdb1
Details of the allocation requested:
> Allowing allocation on /dev/sdb1 start PE 0 length 2271
> Parallel PVs at LE 0 length 1536: /dev/sda1
> Still need 1538 total extents:
> 1 (1 data/0 parity) parallel areas of 1536 extents each
> 2 mirror logs of 1 extents each
So it is looking for 1536 extents on a disk that is not /dev/sda1
and 2 further extents for the mirrored log on different disks from each other.
But it only has one disk available - /dev/sdb1 - so this will fail unless
you go down to --alloc anywhere.
So what should you do?
If you want a mirrored log, decide where to put it and provide the command
with additional space on another disk to hold it.
So let it use part of /dev/sda1 perhaps by appending '/dev/sda1:1536' to
the command or if that isn't enough, try something like '/dev/sdb2:0 /dev/sdc:0'.
Alasdair
^ permalink raw reply [flat|nested] 10+ messages in thread
end of thread, other threads:[~2013-07-04 16:40 UTC | newest]
Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-07-02 0:14 [linux-lvm] I can't have the mirror_log mirrored, LVM complains "there is no suitable space" Alessandro MACUZ
2013-07-02 16:08 ` Alessandro MACUZ
2013-07-02 16:24 ` Alessandro MACUZ
2013-07-03 22:44 ` Alessandro MACUZ
2013-07-04 10:55 ` matthew patton
2013-07-04 12:45 ` Alessandro MACUZ
2013-07-04 11:18 ` Alasdair G Kergon
2013-07-04 11:43 ` Alessandro MACUZ
2013-07-04 14:27 ` Alessandro MACUZ
2013-07-04 16:40 ` Alasdair G Kergon
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.