VK Cloud logo

Attaching and detaching file storage

Mounting and unmounting file storage, as well as writing and reading data, are available only on virtual machines VK Cloud.

Mounting file storage

The method of mounting file storage depends on the virtual machine operating system, Windows or Linux, and the protocol selected when creating the storage.

Windows

You can mount file storage via the NFS protocol in Windows using the Windows Server component — Client for NFS.

  1. Connect to the VK Cloud virtual machine.

  2. Install the Client for NFS from the Server Manager interface or using PowerShell:

    1. Open Server Manager and in the Manage menu, select Add Roles and Features.
    2. Go to the Installation Type section, select the Role-based or feature-based installation option, and click Next.
    3. Go to the Features section and select Client for NFS from the list.
    4. In the same list, expand the options Remote Server Administration Tools → Role Administration Tools → File Services Tools and select Services for NFS Management Tools. Click Next.
    5. Verify that all necessary components are selected and click Install.
    6. Wait for the installation to complete and restart the server.
  3. Change the client settings using Server Manager:

    1. In the Tools menu, select Services for NFS.
    2. Select Client for NFS and click the Display properties window icon.
    3. Set the required settings.
  4. Mount the file storage:

    mount <МОНТ POINT> <DRIVE_LETTER>:

    Here:

    • <MOUNT POINT> — the file storage address. To find it out, view the file storage information.
    • <DRIVE_LETTER> — an uppercase Latin letter that is not used by other drives.

Linux

  1. Connect to the VK Cloud virtual machine.

  2. Install the package for working with the NFS protocol:

    sudo apt-get install nfs-common
  3. Create a directory for mounting the storage:

    mkdir <DIRECTORY_NAME>
  4. Mount the file storage:

    mount -t nfs <MOUNT POINT> ./<DIRECTORY_NAME>

    Here:

    • <MOUNT POINT> — the file storage address. To find it out, view the file storage information.
    • <DIRECTORY_NAME> — the name of the previously created directory.

Unmounting file storage

The method of unmounting file storage depends on the virtual machine operating system and the protocol selected when creating the storage.

  1. Connect to the VK Cloud virtual machine.

  2. Unmount the file storage by running the command:

    umount <DRIVE_LETTER>:
Was this article helpful?