andsens / build-debian-cloud

This project has been superseeded by andsens/bootstrap-vz and is no longer maintained - Script to create Debian Squeeze & Wheezy Amazon Machine Images (AMIs) and Google Compute Engine images
Other
117 stars 43 forks source link

Add LVM root volume support #82

Closed ssgelm closed 11 years ago

ssgelm commented 11 years ago

I ended up recreating the branch to squash the commits...

andsens commented 11 years ago

In the original PR you said

On first boot it will create a 3rd partition if there is extra space (e.g. by having specified a larger disk size), add it to the LVM VG and expand the volume.

"On first boot"...? I cannot see an insserv -r anywhere, isn't it on every boot?

ssgelm commented 11 years ago

That's a good point. The logic in the script is that if there is no third partition on the root disk and if there is enough free space for a third partition it creates it, adds it to LVM, then expands the FS onto it. Because amazon doesn't support resizing an EBS volume without snapshotting and creating a new volume this will generally have the effect of only running on the first boot. The only time the script could do anything otherwise would be if one accepted the original AMI size at first then snapshotted and created a larger EBS volume later.