How to extend instance storage on Amazon EC2

AWS LogoI’ve just launched an EC2 instance from my own AMI. This time however I wanted it to have more storage so I increased the size of my disk space from 10 to 100GB.

Once the instance had launched I’ve noticed that – as before – only 10GB was actually available.

I’ve had this with other infrastructure before, and I knew that I had to extend the volume as well as the volume and the file system for the OS to recognise the extra space.

What puzzled me was the following error message when using the lvextend command:

Was I not using the command correctly? Had I miscalculated the space I had in addition? I checked again with fdisk -l:

Nope, I was right – but lvextend wasn’t happy.

The Solution

Amazon had already extended the volume – all I had to do was grow the file system:

Let’s check it out:

Sometimes things are actually easier than we think 😉

About Jay Versluis

Jay is a medical miracle known as a Super Survivor. He runs two YouTube channels, five websites and several podcast feeds. To see what else he's up to, and to support him on his mission to make the world a better place, check out his Patreon Campaign.

Add your voice!