Automated Growroot for EL7

Latest response

When deploying RHEL instances to services like AWS, one typically uses an template with a default partitioning-scheme (or, no partitioning at all). Because of the vintage of the EL6 kernel, it used to be necessary to include the dracut-modules-growroot RPM from EPEL into to template.

I'd assumed that the same functionality was built into RHEL 7. I'd made this assumption since the RHEL 7 kernel has better support for re-writing live partition-tables and since there doesn't appear to be an equivalent RPM in the EPEL 7 repositories. However, when I launch my RHEL 7 AMIs and specify a larger-than-default size for the boot disk, it's not automagically picked up by the OS. While I can live-repartition the boot drive with the standard dracut modules, I get the dreaded:

Error: Partition(s) 2 on /dev/xvda have been written, but we have been unable to inform the kernel of the change, probably because it/they are in use.  As a result, the old partition(s) will remain in use.  You should reboot now before making further changes.

From partprobe when I attempt to make the space available. If I want the space to be usable, I need to reboot.

I dug through the stock dracut RPMs' modules, and I'm not seeing one that attempts a growroot operation. Before I muck about with trying to port the functionality from the EPEL 6 RPM to an RHEL 7 RPM, is there RHEL 7-native functionality that I'm overlooking?

Responses