How to Resize a DigitalOcean Volume
Quickly resize a DigitalOcean volume in the control panel and with one command. Expand your filesystem's capacity without downtime.

When your DigitalOcean volume runs out of space, here’s the quickest way to expand it. In most cases, you only need one command after increasing the size in the control panel.
Quick Steps
- Increase volume size in DigitalOcean control panel
- Run one command on your server
- Done!
Step 1: Increase Volume Size in DigitalOcean Control Panel
- Go to Volumes in your DigitalOcean control panel
- Click on your volume
- Click Resize Volume
- Enter the new size and confirm
Step 2: Check Current Status (Optional)
You’ll likely see something like:
Step 3: Resize the Filesystem
This is the magic command that does everything:
Replace /dev/sda with your actual device name (check with df -h to see yours).
Expected output:
Step 4: Verify Success
Before:
After:
Success! You now have additional free space available.
Why This Works
The magic: resize2fs performs an online resize, meaning it expands the filesystem while it’s still mounted and in use. No downtime required!
What If It Doesn’t Work?
In rare cases, you might need additional steps, but 90% of the time, the simple command above is all you need.
If you get errors, try:
Quick Automation Script
Save this for future resizes:
That’s It!
No complex unmounting, no partition table editing, no reboots. Just:
- Resize in DigitalOcean panel
- Run
sudo resize2fs /dev/sda - Enjoy your extra space
The resize2fs command automatically detects the new volume size and expands the filesystem to use all available space. Simple and effective!