Note: "permalinks" may not be as permanent as we would like,
direct links of old sources may well be a few messages off.
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On 10/27/2010 01:36 PM, Sam Przyswa wrote: > Now I understand the difference but in this case what about if I extend > the size of the LVM logical volume "disk /dev/mapper/vg_foo_bar" ? Standard LVM resizing rules apply in either case; you must resize block devices starting at the bottom of the stack first. Example (note: untested, but you get the idea) Disk: /dev/sda = 50GB disk /dev/sda1 = 20GB partition LVM: pvcreate /dev/sda1 vgcreate MyVG /dev/sda1 lvcreate --name MyLogVol -l 100%FREE MyVG /dev/mapper/MyVG-MyLogVol = 20GB Logical Volume DRBD: /dev/drbd1 -> /dev/mapper/MyVG-MyLogVol = 20GB DRBD block device. LVM ontop of DRBD: pvcreate /dev/drbd1 vgcreate MyDRBDVG /dev/drbd1 lvcreate --name MyDRBDLogVol -l 100%FREE MyDRBDVG /dev/mapper/MyDRBDVG-MyDRBDLogVol = 20GB Logical Volume Filesystem: mke2fs -j /dev/mapper/MyDRBDVG-MyDRBDLogVol Resize base partition: /dev/sda1 -> 50GB (use fdisk) Resize first LVM: pvresize /dev/sda1 vgextend ... lvextend ... Resize DRBD: drbdam resize <resource> Resize upper LVM: pvresize /dev/drbd1 vgextend... lvextend... Resize filesystem: resize2fs /dev/mapper/MyDRBDVG-MyDRBDLogVol /dev/mapper/MyDRBDVG-MyDRBDLogVol = 50GB Logical Volume. - -- Mark Watts BSc RHCE Senior Systems Engineer, IPR Secure Managed Hosting www.QinetiQ.com QinetiQ - Delivering customer-focused solutions GPG Key: http://www.linux-corner.info/mwatts.gpg -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.10 (GNU/Linux) Comment: Using GnuPG with Fedora - http://enigmail.mozdev.org/ iEYEARECAAYFAkzIPQwACgkQBn4EFUVUIO1srQCfYfpVZZQkQWanv4QLvxAh4AzG e5MAn0DKfApDfnNVMTJgvJA1W9BESUd8 =FMlg -----END PGP SIGNATURE-----