AWS steps and commands to increase disk size (Also included steps for the file system to detect new changes)

Most of us are using aws instances to run models for large datasets. Sometimes, there is a possibility that the initial disk that you allocated doesn’t have the required space to load the dataset. In this case, you can go to aws console and increase the size of the disk.

Following are the steps to be followed:

  • This link is available on the instance summary page. You need to scroll down in instance description tab and click on the disk who size you want to increase which is more likely going to be /dev/sda1.

  • Click on the volume id which has been underlined. In this case, it is vol- 05e7db6b077d36f63.

  • Click on Actions -> Modify Volume

Change the size as required and click on modify. You will get a confirmation at this point. You can verify this after a few minutes on your machine by running lsblk command.

At this time only the disk size has been increased but the changes have not been detected by the underlying file system. You need to follow the steps from till the 4th step so that your filesystem recognizes the new changes.


@vpatlolla what disk space AWS messages were you getting? I keep getting “No space left on device” when trying to make a new directory on AWS (weirdly, I am still about to upload files to my instance via scp though). I looked into my AWS storage situation and found the following. It appears /dev/xvda1 is 100% full. Is that the sign that I need to increase disk size? Or am I just not using my storage space as is efficiently?

You should t be writing under that dir. did you cd up there?

Oh sorry read it wrong. Yep your drive is full

Thank you @parrt! I was so frustrated not even knowing what the situation was. I followed Vinay’s instructions and expanded my instance space. Thank you @vpatlolla!

1 Like