Fixing “No space left on device” issue in an ec2 instance

Madeesha’s Tech Space
2 min readDec 12, 2022

It is really common to receive “No space left on device” if you don’t allocate enough disk space to an ec2 instance. It can be occurred due to an unexpected large log file too. However most of the time, we can’t even run any command or login to the ec2 instance when we receive this error message from the kernel. In this case you can’t increase the EBS volume by logging to the instance. We can resolve this issue by attaching the root volume to a temporary instance, remove unwanted data from the volume and reattaching it to the original ec2. Let’s get into the…

--

--