The easiest way enlarge an EBS volume is obviously by creating a snapshot ,create a new volume using that snapshot with a higher capacity. Unfortunately, once you mount the new EBS volume,you will notice that it’s size is the same. Below are the tips how to fix it.
If filesystem of the volume is EXT3:
I got a chance to create a snapshot of 200Gb EBS volume previously formatted using EXT3. After the snapshot which takes a little longer, need to create another 500GB volume from the snapshot because the older EBS about to be filled up with more data. Following steps posted by izyboyd found at:
Procedure to enlarge ext3 EBS volume from snapshot
Update: Commands for enalarging EXT3
umount /mnt/ebs1 # ElasticFox -> volumes -> right click -> create a new snapshot from this volume # ElasticFox -> snapshots -> right click -> create new volume from this snapshot (with increased size) # ElasticFox -> volumes -> right click ->; attach /dev/sdi fdisk /dev/sdi # Type 'd' to delete the primary partition # Type 'n' for new partition # Type 'p' for primary # Type '1' for 1st # Type Enter for 1st cylinder # Type Enter for last cylinder (full disk) # Partition is not bootable, so 'a' not necessary # Type 'w' to finish e2fsck -f /dev/sdi resize2fs -p /dev/sdi fsck -f -y /dev/sdi mount -t ext3 /dev/sdi /mnt/ebs1
It’s was easy, though the time it takes to snapshot and wait for e2fsck command to finish takes sometime. I leave it overnight to finish the process. It’s important to do e2fsck to the new volume to ensure integrity of data.
If filesystem of the volume is XFS:
While EXT3 volume need to be unmounted while executing the resize, XFS is very simple and can be resize while it’s mounted and live using the command xfs_growfs.
The link of the post messages is at:
Increase XFS EBS volume size
Update: Commands for enlarging XFS
umount /mnt/ebs1 # ElasticFox -> volumes -> right click -> create a new snapshot from this volume # ElasticFox -> snapshots-> right click -> create new volume from this snapshot (with increased size) # ElasticFox -> volumes -> right click -> attach /dev/sdi mount /dev/sdi /mnt/ebs1 xfs_growfs /mnt/ebs1
Whether using EXT3 or XFS in the next volume in EC2, the links above are very helpful. Anybody have a chance snapshotting bigger than 500GB volume? How long does it takes for you to finish?