Lvm

De Admin -- TALEVAS.
(Différences entre les versions)
 
(Une révision intermédiaire par un utilisateur est masquée)
Ligne 27 : Ligne 27 :
 
This "too many metadata areas for pvresize" is telling you that pvresize doesn't know how to resize with metadata at the end of the device. Follow these steps as a workaround. These steps are potentially dangerous but have been tested and worked for me.
 
This "too many metadata areas for pvresize" is telling you that pvresize doesn't know how to resize with metadata at the end of the device. Follow these steps as a workaround. These steps are potentially dangerous but have been tested and worked for me.
  
 +
source => [http://wiki.tldp.org/LVM-on-RAID]
  
  
 
   1. vgcfgbackup -v -f /some/file volumeGroup
 
   1. vgcfgbackup -v -f /some/file volumeGroup
 
 
   2. vgchange -an volumeGroup
 
   2. vgchange -an volumeGroup
 
   3. pvcreate -ff --metadatacopies 1 --restorefile /some/file --uuid UUID /dev/device
 
   3. pvcreate -ff --metadatacopies 1 --restorefile /some/file --uuid UUID /dev/device

Version actuelle en date du 21 janvier 2010 à 16:43

Sommaire

LVM

pvcreate /dev/hdb
vgcreate my_volume_group /dev/hda1 /dev/hdb1
lvcreate -L1500 -ntestlv testvg

A ecrire


les volumes ne sont pas available lors du boot

vgchange -a e snapshots


RESIZE FS

# umount /mnt/DATA
# e2fsck -f /dev/vg01/data
# resize2fs -p /dev/vg01/data 50G
# lvresize -L 50G /dev/vg01/data
# mount /mnt/DATA/
# df -h |grep DATA
50G  180M   47G   1% /mnt/DATA

too many metadata areas for pvresize

This "too many metadata areas for pvresize" is telling you that pvresize doesn't know how to resize with metadata at the end of the device. Follow these steps as a workaround. These steps are potentially dangerous but have been tested and worked for me.

source => [1]


  1. vgcfgbackup -v -f /some/file volumeGroup
  2. vgchange -an volumeGroup
  3. pvcreate -ff --metadatacopies 1 --restorefile /some/file --uuid UUID /dev/device
  4. vgcfgrestore -v -f /some/file volumeGroup 
  5. pvresize /dev/device

Serrer les fessssssses !!