Adding Disk Space to an Instance
- You may require additional disk space when running an EC2 instance
- A new EBS volume may be created and mounted to your instance as follows:
- From the management console, select "Volumes" and then "Create Volume"
- In the menu, you can select a type, size, and zone and specify a snapshot of data to preload onto the volume
- Right click the new volume and select "Attach Volume"
- Specify the instance to attach to (must be in the same region as the volume) and name the device ("/dev/sdf")
- Next you must connect to the instance and mount device.
lsblk
sudo mkfs -t ext3 /dev/xvdf
sudo mkdir newDir
sudo mount /dev/xvdf newDir
lsblk
- "lsblk" lists available devices and where they are mounted. Take note if your devices' name has been changed
- "mkfs" will create a file system on that device
- "mount" will mount the device to the specified directory
|