NavigationContentFooter
Jump toSuggest an edit

Unmounting a Block Storage volume

Reviewed on 28 May 2024Published on 23 November 2023

Unmounting a Block Storage volume

It is important to unmount a volume from the operating system using the umount command to avoid data loss before removing the volume from the machine.

Before you start

To complete the actions presented below, you must have:

  • A Scaleway account logged into the console
  • Owner status or IAM permissions allowing you to perform actions in the intended Organization
  • Created an SSH key
  • Created an Instance with an additional Block Storage volume
  1. Open a terminal and use the following command to connect to your Instance. Make sure that you replace <your_instance_ip> with your Instance’s IP. You can also find the SSH command in your Instance’s Overview tab in the Scaleway console.

    ssh root@<your_instance_ip>
  2. Use lsblk to check where your volume is mounted. You should see an output similar to the following:

    root@scw-heuristic-shtern:~# lsblk
    NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINTS
    sdb 8:0 0 18.6G 0 disk /mnt/block-volume
  3. Unmount the volume to remove it from your current setup. Replace /mnt/block-volume with your mount point.

    umount /mnt/block-volume
  4. Check that the volume is no longer mounted in the system with lsblk. We can see in the example below that sdb is no longer mounted at /mnt/block-volume.

    root@scw-festive-agnesi:~# lsblk
    NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT
    sdb 8:0 0 18.6G 0 disk
    Important

    Remember to edit the /etc/fstab file and delete the line corresponding to your block volume if you have used Persistent Mounting.

Refer to the dedicated documentation for more information about managing your Block Storage volumes.

API DocsScaleway consoleDedibox consoleScaleway LearningScaleway.comPricingBlogCareers
© 2023-2024 – Scaleway