Adding a volume to an instance
Adding a volume
If you want to add a new volume to an existing instance, go to Provisioning → Instances and select the instance you are interested in.
Then press on the Action drop-down menu in the upper right corner and select the Reconfigure option.
When the Reconfigure Instance window appears, press the "+" button next to the volume field.
If you want to add more than one volume, just press the "+" button again.
The volume "data-1" was added in the instance creation form.
By default, all newly created volumes are of the HDD type. If you want to add an SSD volume, please contact with WEkEO Support.
You can change the volume name in the new left field, and in the right, you can change the volume size in gigabytes (GB).
Click the "Reconfigure" button if you want to finish the reconfiguration process and create new volume for the instance.
WARNING: Resize actions for this instance will cause node(s) to be restarted.
You can see the newly added volumes in the "Storage" tab in the instance menu.
Creating a filesystem
First connect to the instance via SSH.
ssh -i <private_key> <user>@<floating_ip>
Execute the "lsblk" command:
to check if new volumes have been attached to the instance.
The volume "vdb" (data-1) was added in the instance creation form. The volume that was added by the reconfiguration option is "vdc" (data-2).
Execute the command below to create a file system for the new volume:
sudo mkfs.ext4 /dev/<disk>
<disk> - volume name, which you can check with the "lsblk" command, for example “vdb”.
Then create a new directory under which the new volume will be mounted.
sudo mkdir /<mount_dir>
Then add the following line to the end of the “/etc/fstab” file. To do this you must open the /etc/fstab file with any editor, for example nano.
sudo nano /etc/fstab
/dev/<disk> /<mount_dir> ext4 defaults 0 1
Thanks to that, after restarting the instance, these volumes will be automatically mounted.
Mounting a volume
Finally, mount the volume by executing the command:
sudo mount /<mount_dir>
and check if the volumes are correctly mounted.
After mounting the volume, you can go to the place where it was mounted and save your data.