You can create and attach new volumes in four main contexts:
No matter how you create a new volume, before it’s ready for use for the first time, you’ll need to format and mount it.
You can create a new volume at any time by using the Create menu.
You can manage all the volumes associated with your account by following the Volumes link:
You can create and attach a new volume or attach an existing volume at the same time you create a Droplet in the Add block storage section. When you choose to add a volume, the selection of regions for the Droplet will be automatically limited to those regions where block storage is available.
When you’ve already created a Droplet and it is located in a region with block storage support, you can create and manage volumes on its Volumes page:
When you first create a new volume, you will need to format it to create a file system. You generally only have to do this once because formatting a volume erases all the data on it. Every time you attach a formatted volume to a Droplet, you will need to mount it so your Droplet can access it.
You can choose to automatically format and mount a volume for first-time use on supported distributions. When auto-mounting is available, it is selected by default. Otherwise, it will be grayed out and the manual option will be selected.
By default, Ext4 is selected as the default filesystem because of its stability, backwards compatibility, and mature support and tooling. You can also choose XFS, which specializes in performance for large data files.
Regardless of which filesystem you choose, the volume will be auto-mounted into the
/mnt directory with the options
Automatic mounting is done via systemd on distributions that support it. You can find the mount unit files at
/etc/systemd/system/mnt-volume_*.mount and the udev rules that control the configuration at
On non-systemd distributions, like Ubuntu 14.04, Debian 7, and CentOS 6, automatic mounting is done via
fstab using the same commands and options that are provided in the control panel’s instructions for manual formatting and mounting.
You can manually format and mount all volumes. Droplet-specific directions are available in the volume’s More menu under Config instructions.
These customized directions have three parts that you can copy to paste directly into a terminal from your local machine. The three parts are:
SSH to your Droplet, which includes the SSH command with the Droplet’s IP address filled in.
If you’ve disabled
root logins or are working with CoreOS, FreeBSD, or RancherOS, you’ll need to substitute the appropriate user for
Format the volume: One time only, which includes the commands to set up a filesystem with the Droplet’s IP address and the SCSI ID of the volume pre-filled. Generally, this is a one-time-only task; when you format a volume it destroys all existing data.
By default, this command uses the Ext4 filesystem. If you prefer, you can use the same commands to format the volume with XFS by changing
Mount the volume, which includes the commands to create a mount point, mount the volume, and set the volume to automatically mount when you reboot. The specific SCSI ID of the volume is pre-filled.
Once a volume is formatted and mounted, it is ready to use.