I have spce in volume group but it can not increase the size of logical volume
Dear All
I have almost 108 Gb space .but when i increase the size of logical volume .it can not increase the size of logical volume. i use the following command herer is my detail of vgdisplay VG Name xen-vol System ID Format lvm2 Metadata Areas 2 Metadata Sequence No 8 VG Access read/write VG Status resizable MAX LV 0 Cur LV 2 Open LV 2 Max PV 0 Cur PV 2 Act PV 2 VG Size 150.01 GiB PE Size 4.00 MiB Total PE 38402 Alloc PE / Size 10502 / 41.02 GiB Free PE / Size 27900 / 108.98 GiB VG UUID fbfxhr-x3l3-EJCj-gwVp-tgox-1POl-x1ScSt Here is lvdisplay details lvdisplay --- Logical volume --- LV Name /dev/xen-vol/lvmtest-swap VG Name xen-vol LV UUID ZTV6g3-YLGv-QgoY-U5bp-UAdc-fOxD-i22lK2 LV Write Access read/write LV Status available # open 1 LV Size 1.00 GiB Current LE 256 Segments 1 Allocation inherit Read ahead sectors auto - currently set to 256 Block device 254:0 --- Logical volume --- LV Name /dev/xen-vol/lvmtest-disk VG Name xen-vol LV UUID uiaLoC-1Z4r-EW6S-NzxM-D4hM-4KVD-e00Ou4 LV Write Access read/write LV Status available # open 1 LV Size 40.02 GiB Current LE 10246 Segments 1 Allocation inherit Read ahead sectors auto - currently set to 256 Block device 254:1 lvextend -v -L +10G /dev/xen-vol/lvmtest-disk after that i also use resize2fs /dev/xvda2 kindly help me in this regards Thank you |
Can we have your fdisk -l output as well? And can you edit your post to include the output from the commands in Code tags. its so frustrating to read through the output this way.
|
you said "it can not" but not said anything useful about what actually happens. Are you getting error message you're not sharing with us etc.?
|
i have volume group
Quote:
Here is my fdisk -l output here attached 2 harddisk i use /dev/sdb which size is 200GB.i create LVM on this disk and i use debian squeez Disk /dev/sda: 250.1 GB, 250059350016 bytes 255 heads, 63 sectors/track, 30401 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk identifier: 0x0002152b Device Boot Start End Blocks Id System /dev/sda1 1 499 4002816 82 Linux swap / Solaris Partition 1 does not end on cylinder boundary. /dev/sda2 499 30402 240193537 5 Extended /dev/sda5 499 30402 240193536 83 Linux Disk /dev/sdb: 200.0 GB, 200049647616 bytes 255 heads, 63 sectors/track, 24321 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk identifier: 0x00029984 Device Boot Start End Blocks Id System /dev/sdb1 1 13055 104864256 8e Linux LVM /dev/sdb2 13056 19583 52436160 8e Linux LVM Disk /dev/dm-0: 1073 MB, 1073741824 bytes 255 heads, 63 sectors/track, 130 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk identifier: 0x00000000 Disk /dev/dm-0 doesn't contain a valid partition table Disk /dev/dm-1: 43.0 GB, 42974838784 bytes 255 heads, 63 sectors/track, 5224 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk identifier: 0x00000000 Disk /dev/dm-1 doesn't contain a valid partition table hera is my clear output of Vgdisplay Vgdisplay VG Name xen-vol System ID Format lvm2 Metadata Areas 2 Metadata Sequence No 8 VG Access read/write VG Status resizable MAX LV 0 Cur LV 2 Open LV 2 Max PV 0 Cur PV 2 Act PV 2 VG Size 150.01 GiB PE Size 4.00 MiB Total PE 38402 Alloc PE / Size 10502 / 41.02 GiB Free PE / Size 27900 / 108.98 GiB VG UUID fbfxhr-x3l3-EJCj-gwVp-tgox-1POl-x1ScSt and here is my clear lvdisply out put lvdisplay --- Logical volume --- LV Name /dev/xen-vol/lvmtest-swap VG Name xen-vol LV UUID ZTV6g3-YLGv-QgoY-U5bp-UAdc-fOxD-i22lK2 LV Write Access read/write LV Status available # open 1 LV Size 1.00 GiB Current LE 256 Segments 1 Allocation inherit Read ahead sectors auto - currently set to 256 Block device 254:0 --- Logical volume --- LV Name /dev/xen-vol/lvmtest-disk VG Name xen-vol LV UUID uiaLoC-1Z4r-EW6S-NzxM-D4hM-4KVD-e00Ou4 LV Write Access read/write LV Status available # open 1 LV Size 40.02 GiB Current LE 10246 Segments 1 Allocation inherit Read ahead sectors auto - currently set to 256 Block device 254:1 |
As I said before, please use Code tags so that it is easier for members to read the computer output.
|
What was the output from lvextend -v -L +10G /dev/xen-vol/lvmtest-disk?
Is /dev/xvda2 in resize2fs /dev/xvda2 intended to be the same device? Why is it not also /dev/xen-vol/lvmtest-disk? |
Why do you care what fdisk says? The VG is 150GB regardless of the physical disk it's on.
|
Quote:
Here is my fdisk -l output here attached 2 harddisk i use /dev/sdb which size is 200GB.i create LVM on this disk and i use debian squeez Disk /dev/sda: 250.1 GB, 250059350016 bytes 255 heads, 63 sectors/track, 30401 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk identifier: 0x0002152b Device Boot Start End Blocks Id System /dev/sda1 1 499 4002816 82 Linux swap / Solaris Partition 1 does not end on cylinder boundary. /dev/sda2 499 30402 240193537 5 Extended /dev/sda5 499 30402 240193536 83 Linux Disk /dev/sdb: 200.0 GB, 200049647616 bytes 255 heads, 63 sectors/track, 24321 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk identifier: 0x00029984 Device Boot Start End Blocks Id System /dev/sdb1 1 13055 104864256 8e Linux LVM /dev/sdb2 13056 19583 52436160 8e Linux LVM Disk /dev/dm-0: 1073 MB, 1073741824 bytes 255 heads, 63 sectors/track, 130 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk identifier: 0x00000000 Disk /dev/dm-0 doesn't contain a valid partition table Disk /dev/dm-1: 43.0 GB, 42974838784 bytes 255 heads, 63 sectors/track, 5224 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disk identifier: 0x00000000 Disk /dev/dm-1 doesn't contain a valid partition table hera is my clear output of Vgdisplay Vgdisplay VG Name "xen-vol" System "ID" Format "lvm2" Metadata Areas 2 Metadata Sequence No 8 VG Access "read/write" VG Status "resizable" MAX LV "0" Cur LV "2" Open LV "2" Max PV "0" Cur PV "2" Act PV "2" VG Size "150.01 GiB" PE Size "4.00 MiB" Total PE "38402" Alloc PE / Size "10502 / 41.02 GiB" Free PE / Size "27900 / 108.98 GiB" VG UUID fbfxhr-x3l3-EJCj-gwVp-tgox-1POl-x1ScSt and here is my clear lvdisply out put lvdisplay --- Logical volume --- LV Name "/dev/xen-vol/lvmtest-swap" VG Name "xen-vol" LV UUID "ZTV6g3-YLGv-QgoY-U5bp-UAdc-fOxD-i22lK2" LV Write Access "read/write" LV Status available # open 1 LV Size "1.00 GiB" Current LE "256" Segments "1" Allocation "inherit" Read ahead sectors "auto" - currently set to "256" Block device "254:0" --- Logical volume --- LV Name "/dev/xen-vol/lvmtest-disk" VG Name "xen-vol" LV UUID "uiaLoC-1Z4r-EW6S-NzxM-D4hM-4KVD-e00Ou4" LV Write Access "read/write" LV Status "available" # open "1" LV Size "40.02 GiB" Current LE "10246" Segments "1" Allocation "inherit" Read ahead sectors "auto" - currently set to "256" Block device "254:1" I use the following command for lvextend lvextend -v -L +10GB -n /dev/xen-vol/lvmtest-disk |
OK, this stuff you're posting isn't useful, and you're just repeating yourself. Can you answer the other questions you've been asked please?
|
Quote:
Finding volume group xen-vol Archiving volume group "xen-vol" metadata (seqno 8). Extending logical volume lvmtest-disk to 50.02 GiB Found volume group "xen-vol" Found volume group "xen-vol" Loading xen--vol-lvmtest--disk table (254:1) Suspending xen--vol-lvmtest--disk (254:1) with device flush Found volume group "xen-vol" Resuming xen--vol-lvmtest--disk (254:1) Creating volume group backup "/etc/lvm/backup/xen-vol" (seqno 9). Logical volume lvmtest-disk successfully resized But when i login to virtual machine it size not increase even i execute this command also resize2fs /dev/xvda2 it also show me size has been increased but when i check by df -h command the size is old one. |
You asked how to make an LV larger. You mentioned nothign at all about virtual machines. Is the LV larger or not?
|
Quote:
when i run lvextend -v -L +10G -n /dev/xen-vol/lvmtest-disk on host machine it show me the following message Finding volume group xen-vol Archiving volume group "xen-vol" metadata (seqno 8). Extending logical volume lvmtest-disk to 50.02 GiB Found volume group "xen-vol" Found volume group "xen-vol" Loading xen--vol-lvmtest--disk table (254:1) Suspending xen--vol-lvmtest--disk (254:1) with device flush Found volume group "xen-vol" Resuming xen--vol-lvmtest--disk (254:1) Creating volume group backup "/etc/lvm/backup/xen-vol" (seqno 9). Logical volume lvmtest-disk successfully resized when i log in to the virtual machine by following command xm console lvmtest and run the following command resize2f /dev/svda2 it also show block size has increased when i check by df -h command it show me the old hard disk size means changes not reflected on it. |
is the ***LV*** larger? Forget anything on it. One thing at a time.
|
i have volume group
Quote:
i just want to increse the size to virtual machine disk |
you've shown us the lvdisplay, you've shown us a command's output. did the lv get larger or not?
|
All times are GMT -5. The time now is 03:29 AM. |