According to google's documentation:
If you create or resize a root persistent disk or create a disk from an image or a snapshot, your virtual machine instance can automatically resize the partition to recognize the additional space after you restart the instance.
As long as its one of the supported OSes
CentOS 6 & CentOS 7 v20160418 or newer Yes. These images will automatically resize root partitions up to 2 TB. Even if the disk is larger than 2 TB, the operating system only recognizes up to 2 TB.
Source Image: centos-7-v20170523
However, /dev/sda1 does not seem to have been re-partitioned to consume the additional space.
[redacted@redacted ~]$ sudo lsblk NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT sda 8:0 0 30G 0 disk └─sda1 8:1 0 10G 0 part / [redacted@redacted ~]# df -h Filesystem Size Used Avail Use% Mounted on /dev/sda1 10G 8.0G 2.0G 81% / devtmpfs 3.7G 0 3.7G 0% /dev tmpfs 3.7G 0 3.7G 0% /dev/shm tmpfs 3.7G 8.3M 3.7G 1% /run tmpfs 3.7G 0 3.7G 0% /sys/fs/cgroup tmpfs 749M 0 749M 0% /run/user/1000
I have attempted to restart the instance a few times, as well as increase the size(was originally 25 but upped to 30 to try and get it to re-partition)
I've attempted xfs_growfs on the disk, but no luck there
[redacted@redacted ~]# xfs_growfs /dev/sda1 -D 7864320 meta-data=/dev/sda1 isize=256 agcount=4, agsize=655296 blks = sectsz=4096 attr=2, projid32bit=1 = crc=0 finobt=0 spinodes=0 data = bsize=4096 blocks=2621184, imaxpct=25 = sunit=0 swidth=0 blks naming =version 2 bsize=4096 ascii-ci=0 ftype=0 log =internal bsize=4096 blocks=2560, version=2 = sectsz=4096 sunit=1 blks, lazy-count=1 realtime =none extsz=4096 blocks=0, rtextents=0 data size 7864320 too large, maximum is 2621184
I'm somewhat stumped as to why this isn't working. The only other option maybe to attach-disk it to another instance and then resize the partition form there, however I'd like to get it working this way, since the above mentioned method would be a lot more work, and is more prone to mistakes.