Volume Quickstart
Validated on 3 Oct 2019 • Last edited on 27 Sep 2023
Volumes are network-based block devices that provide additional data storage for Droplets. You can move them between Droplets, create disk images of them, and resize them at any time.
Add New Volumes to Droplets
You can add a new volume to an existing Droplet or while creating a new Droplet.
-
From the Create menu in the top right of the control panel, click Volumes, then choose an existing Droplet to attach the volume to in Select Droplet to attach to.
Alternatively, on the Droplet create page, in the Add block storage section, click Add Volume.
-
Choose the size of your volume, which can be from 1 GB to 16 TiB (16,384 GB).
-
Format and mount the volume. This is automatic for supported operating systems. Instructions for manual formatting and mounting are in the volume’s More menu under Config instructions.
Automatic and manual setup both format the volume with ext4, mount it into
/mnt
with the optionsdefaults,nofail,discard,noatime
, and update/etc/fstab
for persistent mounting across reboots.
Move Volumes to Different Droplets
You can move volumes between different Droplets in the same datacenter.
- Unmount the volume to prevent OS-level errors.
- Open the volume’s More menu and choose Detach from Droplet. Detaching a volume removes the volume from its current Droplet.
- In the same More menu, attach the volume to a different Droplet by choosing Attach to Droplet, then selecting the Droplet you want to use.
- Mount the volume to make it accessible to the new Droplet.
Increase the Size of Volumes
If you need more storage space, you can increase the size of a volume.
- Resize the volume itself. In the volume’s More menu, choose Increase size.
- In the Increase volume size window, enter a new size in GB (at least 1 GB larger than the current size) and click Resize volume.
- Expand the filesystem to use the additional space. For ext4, use
resize2fs
. For XFS, usexfs_growfs
.
Volumes are unpartitioned by default, but if you manually partitioned your volume when you created it, you need to expand the final partition before expanding the filesystem.
You cannot decrease the size of a volume because of the risk of data loss and filesystem corruption.
Delete Volumes
Deleting a volume permanently and irreversibly destroys the volume and its contents.
- Open the volume’s More menu and choose Delete.
- In the Delete volume window that opens, confirm the deletion.