LVM resize

 
Thread Tools Search this Thread
Operating Systems Linux Red Hat LVM resize
# 1  
Old 08-29-2015
LVM resize

In RHEL7
I created an LVM partition with vfat filesystem
I am unable to reduce the size

for ext4 file system i sued below commands to reduce the lvm
Code:
# umout /lvm (mount point)
# e2fsck -f /dev/vgname/lvname
# resize2fs /dev/vgname/lvname 100M (Say from 200M)
# lvreduce -L 100M /dev/vgname/lvname

I was told the above commands should work for vfat file system.
However when i perform the e2fsck command i get error related to superblocks.
I couldn't get the exact error response since i did on lab.

I need to reduce lvm for vfat filesystem.

Last edited by vbe; 08-29-2015 at 05:40 AM.. Reason: code tags please
# 2  
Old 08-29-2015
You can't use e2fsck on a vfat file system. Try fsck -t vfat or fsck.msdos.
And, I'm not sure if and how you can resize a vfat fs. You may need to save the data to somewhere, resize the partition, and restore the data back.
# 3  
Old 09-07-2015
I would always use the -r flag on lvreduce and get the filesystem reduction AND logical volume reduction done in one step. I'm not familiar with vfat, so it might not apply. You would at least need to specify the type though as RudiC says.

Using the -r flag does the whole process, i.e. unmounts, reduces FS & LV and re-mounts, so:-
Code:
# umout /lvm (mount point)
# e2fsck -f /dev/vgname/lvname
# resize2fs /dev/vgname/lvname 100M (Say from 200M)
# lvreduce -L 100M /dev/vgname/lvname

becomes just:-
Code:
# lvreduce -t vfat -L 100M -r /dev/vgname/lvname


I hope that this helps,
Robin
This User Gave Thanks to rbatte1 For This Post:
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Solaris

Resize rpool

Hi, I have rpool about 500G. So i want to use 210G from rpool and assign mount point as /database. I seek in google and couldn't found it. Does anyone know how to achieve it? Thanks. (2 Replies)
Discussion started by: mzainal
2 Replies

2. AIX

Resize Lun

Good afternoon! Help with a solution I have AIX 7.1 works through vios I expanded Lun that it is necessary to make that aix saw this change and to expand the section lvm Sorry for my English (1 Reply)
Discussion started by: iformats
1 Replies

3. Shell Programming and Scripting

resize images

Is there a script or extension that I can look into that will re-size an allotment of images to a given size?? Id like to take images of a certain size and resize them but Im dont remember an install option that can do it if installed in ubuntu but I, also unsure in what code I will have to learn.... (2 Replies)
Discussion started by: graphicsman
2 Replies

4. HP-UX

Resize volume

Dear All, We have HP Unix 11.31. We have two VG, VG01 and VG02. In VG01 there are three mount point each of 100gb size. There is no data on below mount point /soft/01 /soft/02 /soft/03Is it possible to resize each of these mount point to 50 GB. So 150 GB will free and release from... (2 Replies)
Discussion started by: bhattnirav
2 Replies

5. UNIX for Dummies Questions & Answers

How to convert non LVM root partition to LVM?

Hi Guys, I m using redhat 6, I have installed root partition as non-LVM . Is there any way i can convert it to LVM? (1 Reply)
Discussion started by: pinga123
1 Replies

6. Shell Programming and Scripting

resize

Hello, I created a script that runs perfectly on 2 different account but I it will not run in 2 others (HP-UX). I noticed that the problem is caused by the resize command in the .profile of the problematic accounts. Since it is a prod server, I dont want to remove it witout knowing what it is... (4 Replies)
Discussion started by: drbiloukos
4 Replies

7. HP-UX

How to reduce LVM to create another LVM

Hi, I'm new to HP-UX. I have LVM on /var with 92Gig. I would like to reduce it to create another LVM for Oracle client with 800 meg or so. How to do it. I'm running 11.iv3 Thanks (4 Replies)
Discussion started by: lamoul
4 Replies

8. Filesystems, Disks and Memory

how to resize a file

hello every body. in a little bit of a jam here.if you all happen to know how to resize the tmp file in my linux system. I use a sabayon 3.5 on a x86 machine. itried to make a dvd image copy but the system gives me a error message telling me the temporary folder used to make images is too small.... (3 Replies)
Discussion started by: dvas83
3 Replies

9. UNIX for Advanced & Expert Users

resize filesystems

Dear All We have HP9000 rp7400 Server running with hp-ux 11i. Our Disk storage has two volume groups and are allocated as follows: 1. /#vgdisplay -v --- Volume groups --- VG Name /dev/vg00 VG Write Access read/write VG Status available... (1 Reply)
Discussion started by: mhbd
1 Replies

10. AIX

resize fs

Hello everyone I need to resize a filesystem /home I want to add 200mb and I have space on the disk with lsvg rootvg command I check this but I cant because has a mirror. Do you know some way that I can do this. Thanks in advance (1 Reply)
Discussion started by: lo-lp-kl
1 Replies
Login or Register to Ask a Question