0

I have an Amazon EBS volume that I'm using as a backing store for MongoDB, and I want to extend it.

The volume holds a single partition, which is an LVM partition type. That partition belongs to a single physical volume, which belongs to a single volume group, which exposes a single logical volume, which is formatted to the XFS filesystem.

I extend the volume in AWS successfully, but I cannot find any instructions online on how to resize a partition in linux non-destructively.

pvresize does not work

lvextend does not work

What do?

Thanks,

0

Partitions are P.I.T.A. But you can create new partition, and do vgextend $VG $NEWPARTITION.

This has a caveat of course: partitions on single disk are treated as separate devices, so LVM might create a mirror/RAID1 on two partitions.

But as you are on Amazon EBS, I assume you are not using RAIDs (EBS does keep data safe for you, and handles snapshots). And you plan to use the entire partition for LV, so you are safe.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.