I am running CentOS 7 and using the XVF filesystem type (no LVM). I thought with kernel 3.8 an higher (I am running 3.10) that I could use growpart to grow my mounted root volume on boot and not have to rely on dracut/initramfs (the packages I previously used in CentOS 6 are not available yet on CentOS 7).
I placed the growpart module in the cloud_init_modules section of cloud.cfg. I checked the logs after first boot and it attempted to run but failed.
When running grow part manually (after first boot), I get the following output.
Code: Select all
[root@playground03 cloud]# growpart /dev/vda 2 failed [pt_update:1] pt_update /dev/vda 2 partx: /dev/vda: error updating partition 2 FAILED: pt_resize failed ***** WARNING: Resize failed, attempting to revert ****** Re-reading the partition table ... BLKRRPART: Device or resource busy sfdisk: The command to re-read the partition table failed. Run partprobe(8), kpartx(8) or reboot your system now, before using mkfs ***** Appears to have gone OK ****
Is the right/only answer to use LVM and extend my root partition that way?
Code: Select all
[root@playground03 cloud]# uname -a Linux playground03.bo.aquto.internal 3.10.0-123.8.1.el7.x86_64 #1 SMP Mon Sep 22 19:06:58 UTC 2014 x86_64 x86_64 x86_64 GNU/Linux [root@playground03 cloud]# yum list "cloud*" Loaded plugins: fastestmirror Loading mirror speeds from cached hostfile * base: mirror.es.its.nyu.edu * extras: centos.mirrors.tds.net * updates: mirrors.greenmountainaccess.net Installed Packages cloud-init.x86_64 0.7.5-10.el7.centos.1 @extras cloud-utils.x86_64 0.27-20.el7.centos @extras cloud-utils-growpart.x86_64 0.27-20.el7.centos @extras [root@playground03 cloud]#