views:

4050

answers:

4

I'm quite impressed with Amazon's EC2 and EBS services. I wanted to know if it is possible to grow an EBS Volume.

For example: If I have a 50 GB volume and I start to run out of space, can I bump it up to 100 GB when required?

+5  A: 

You can't simply 'bump in' more space on the fly if you need it, but you can resize the partition with a snapshot.

Steps do to this:

  1. unmount ebs volume
  2. create a ebs snapshot
  3. add new volume with more space
  4. recreate partition table and resize filesystem
  5. mount the new ebs volume

Look at http://aws.amazon.com/ebs/ - EBS Snapshot:

Snapshots can also be used to instantiate multiple new volumes, expand the size of a volume or move volumes across Availability Zones. When a new volume is created, there is the option to create it based on an existing Amazon S3 snapshot. In that scenario, the new volume begins as an exact replica of the original volume. By optionally specifying a different volume size or a different Availability Zone, this functionality can be used as a way to increase the size of an existing volume or to create duplicate volumes in new Availability Zones. If you choose to use snapshots to resize your volume, you need to be sure your file system or application supports resizing a device.

echox
+6  A: 

You can grow the storage, but it can't be done on the fly. You'll need to take a snapshot of the current block, add a new, larger block and re-attach your snapshot.

There's a simple walkthrough here based on using Amazon's EC2 command line tools

ConroyP
Second link is broken. Should maybe be: http://docs.amazonwebservices.com/AWSEC2/2009-11-30/CommandLineReference/
Andrew B.
@Andrew B Thanks, link updated now.
ConroyP
+1  A: 

I have written a tutorial to grow the size of your ebs volume at - http://aws-musings.com/how-to-expand-your-ebs-volume/

Vaibhav Puranik
+2  A: 

As long a you are okay with a few minutes of downtime, Eric Hammond has written a good article on resizing the root disk on a running EBS instance: http://alestic.com/2010/02/ec2-resize-running-ebs-root

Jeff Bauer