Linux - ServerThis forum is for the discussion of Linux Software used in a server related context.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
I am facing problem in extending of LVM it was successfully extended before but due to some reason i had to reduce it. Now when again I try to extend it it's give me an error message which is mentioned below please have a look and suggest me what should i do.
I issued below mentioned command:- lvextend -L +8000M /dev/My_VolGroup00/Home02
And got below error:-
Insufficient free space: 250 extents needed, but only 161 available
First thought is that there's not enough disk space available to extend your logical volume by 8Gb. You need to check before extending a logical volume if there are enough extents free. Using the commands pvdisplay, vgdisplay and lvdisplay should give you all the info you need.
If suppose there is no space so how could i free it because Its not allowing me to add in current logical volume. Without it i will not able to view that volumegroup.
Below are the outputs of LVM commands, please have a look.
PVDISPLAY O/P
[root@station1 ~]# pvdisplay
--- Physical volume ---
PV Name /dev/sda2
VG Name My_VolGroup00
PV Size 7.90 GB / not usable 23.41 MB
Allocatable yes (but full)
PE Size (KByte) 32768
Total PE 252
Free PE 0
Allocated PE 252
PV UUID NmUdFi-GoCh-2IZQ-DSJE-tX3L-irbf-lgSlRH
--- Physical volume ---
PV Name /dev/sdb1
VG Name My_VolGroup00
PV Size 8.00 GB / not usable 29.35 MB
Allocatable yes (but full)
PE Size (KByte) 32768
Total PE 255
Free PE 0
Allocated PE 255
PV UUID gN1kff-O0pA-PKbo-R21i-WCMu-OXe1-CXoc4K
--- Physical volume ---
PV Name /dev/sdc1
VG Name My_VolGroup00
PV Size 8.00 GB / not usable 29.35 MB
Allocatable yes (but full)
PE Size (KByte) 32768
Total PE 255
Free PE 0
Allocated PE 255
PV UUID rOcEU0-Dz3G-9V8s-XLDo-IPb0-Tnaq-42yif1
--- Physical volume ---
PV Name /dev/sdd1
VG Name My_VolGroup00
PV Size 8.00 GB / not usable 29.35 MB
Allocatable yes
PE Size (KByte) 32768
Total PE 255
Free PE 161
Allocated PE 94
PV UUID fgENfH-wDur-YFsX-sHzz-PcBu-6Q0Y-IaRv2A
VGDISPLAY O/P
[root@station1 ~]# vgdisplay
--- Volume group ---
VG Name My_VolGroup00
System ID
Format lvm2
Metadata Areas 4
Metadata Sequence No 8
VG Access read/write
VG Status resizable
MAX LV 0
Cur LV 4
Open LV 4
Max PV 0
Cur PV 4
Act PV 4
VG Size 31.78 GB
PE Size 32.00 MB
Total PE 1017
Alloc PE / Size 856 / 26.75 GB
Free PE / Size 161 / 5.03 GB
VG UUID ZR9iIH-edSc-dqvZ-Z7Ln-6Ylu-lckz-qEDq0Q
LVDISPLAY O/P
[root@station1 ~]# lvdisplay
--- Logical volume ---
LV Name /dev/My_VolGroup00/Root01
VG Name My_VolGroup00
LV UUID qtN1JL-UnKA-hDko-yn9v-EZFI-CxkD-pyv5gH
LV Write Access read/write
LV Status available
# open 1
LV Size 9.75 GB
Current LE 312
Segments 2
Allocation inherit
Read ahead sectors 0
Block device 253:0
--- Logical volume ---
LV Name /dev/My_VolGroup00/Home02
VG Name My_VolGroup00
LV UUID elT5lL-YY2x-6ZyZ-lHVe-SQde-Tmb1-CF1PKf
LV Write Access read/write
LV Status available
# open 1
LV Size 7.81 GB
Current LE 250
Segments 2
Allocation inherit
Read ahead sectors 0
Block device 253:1
--- Logical volume ---
LV Name /dev/My_VolGroup00/Var03
VG Name My_VolGroup00
LV UUID cihuCk-9v7W-lUhI-1c3T-Wuqu-Fbuq-38mZ2C
LV Write Access read/write
LV Status available
# open 1
LV Size 8.19 GB
Current LE 262
Segments 2
Allocation inherit
Read ahead sectors 0
Block device 253:2
--- Logical volume ---
LV Name /dev/My_VolGroup00/Swap00
VG Name My_VolGroup00
LV UUID giGfaN-56vw-FdXG-lMXb-PWcB-uSfd-pB3stQ
LV Write Access read/write
LV Status available
# open 1
LV Size 1.00 GB
Current LE 32
Segments 1
Allocation inherit
Read ahead sectors 0
Block device 253:3
I agree with Disillusionist. You only have those options listed. Your PE (Physical extent) size is 32Mb and you only have 161 PE's free on /dev/sdd1, the others are used up. So doing the math you get exactly what Disillusionist said, roughly 5Gb, and also those possibilities. I'd also go with option 1 or 3.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.