Monday, May 18, 2015

Remove just added volume from LVM



We did the following:





  1. Added a volume (500G) to the volume group

  2. Extended the logical volume on the volume group



We did not extend the filesystem on the logical volume.



Then we decided, that it is not a good idea.



Now we want to safely remove the volume again.




The plan:




  1. lvreduce the logical volume exactly to the file system

  2. vgreduce



Questions:





  1. How to exactly find out the size of the file system?

  2. Does LVM automatically detect, that the space provided by the new phyiscal volume is no longer used and allows unplugging of the volume?


Answer



Debian seems to create backups of the vg configuration at /etc/lvm/archive - it should be possible to use such an old config.


No comments:

Post a Comment