The page has been translated by Gen AI.

Connect to Server

When using a volume on the server, a connect or disconnect operation is required.
On the Block Storage Details page, add a connected server, then access the server to perform connection operations (Mount, Disk Online). After use, perform disconnection operations (Umount, Disk Offline) and then remove the connected server.

Connect to Server (Mount, Disk Online)

To use the volume added to the connected server, you must log into the server and perform the connection tasks (Mount, Disk Online). Follow the steps below.

Linux operating system

Example configuration for server connection
  • Server OS: LINUX
  • Mount location: /data
  • Volume size: 24 GB
  • File system: ext3, ext4, xfs etc
  • Additional allocated disk: /dev/vdb
  1. Click the All Services > Compute > Virtual Server menu. Navigate to the Service Home page of Virtual Server.
  2. Click the Block Storage menu. Go to the Block Storage List page.
  3. On the Block Storage List page, click the resource to be used on the connected server. Navigate to the Block Storage Details page.
  4. After verifying the server in the Connection Server item, connect.
  5. Refer to the steps below to mount the volume (Mount).
  • Switch to root privileges

    $ sudo -i
    
  • Check Disk

    # lsblk
    NAME    MAJ:MIN  RM   SIZE RO TYPE MOUNTPOINT
    vda       252:0   0    24G  0 disk
    ├─vda1    252:1   0  23.9G  0 part [SWAP]
    └─vda14   252:14  0     4M  0 part /
    └─vda15   252:15  0   106M  0 part /boot/efi
    vdb       252:16  0    24G  0 disk
    
  • Create partition

    # fdisk /dev/vdb
    Command (m for help): n
    
    Partition type:
       p   primary (0 primary, 0 extended, 4 free)
       e   extended
    Select (default p): p
    Partition number (1-4, default 1): 1
    First sector (2048-50331646, default 2048):
    Last sector, +/-sectors or +/-size{K,M,G,T,P} (2048-50331646, default 50331646):
    
    Created a new partition 1 of type 'Linux' and of size 24 GiB.
    
    Command (m for help): w
    The partition table has been altered!
    Calling ioctl() to re-read partition table.
    Syncing disks.
    
  • Partition format setting (example: ext4)

    # lsblk
    NAME    MAJ:MIN  RM   SIZE RO TYPE MOUNTPOINT
    vda       252:0   0    24G  0 disk
    ├─vda1    252:1   0  23.9G  0 part [SWAP]
    └─vda14   252:14  0     4M  0 part /
    └─vda15   252:15  0   106M  0 part /boot/efi
    vdb       252:16  0    24G  0 disk
    └─vdb1    252:17  0    24G  0 part
    
    # mkfs.ext4 /dev/vdb1
    mke2fs 1.46.5 (30-Dec-2021)
    ...
    Writing superblocks and filesystem accounting information: done
    
  • Volume Mount

    # mkdir /data
    
    # mount /dev/vdb1 /data
    
    # lsblk
    NAME    MAJ:MIN  RM   SIZE RO TYPE MOUNTPOINT
    vda       252:0   0    24G  0 disk
    ├─vda1    252:1   0  23.9G  0 part [SWAP]
    └─vda14   252:14  0     4M  0 part /
    └─vda15   252:15  0   106M  0 part /boot/efi
    vdb       252:16  0    24G  0 disk
    └─vdb1    252:17  0    24G  0 part /data
    
    # vi /etc/fstab
    (추가) /dev/vdb1     /data       ext4     defaults   0 0
    

ItemExplanation
cat /etc/fstabFile system information file
  • Used when the server is running
df -hCheck the total disk usage of mounted disks
fdisk -lCheck partition information
  • Physical disks are represented by letters such as a, b, c like /dev/sda, /dev/sdb, /dev/sdc. Disk partitions are represented by numbers such as 1, 2, 3 like /dev/sda1, /dev/sda2, /dev/sda3
Table. Mount command reference
commandExplanation
mCheck the usage of the fdisk command
nCreate a new partition
pVerify the updated partition information
tChange the system ID of the partition
wSave partition information and exit fdisk.
Table. Partition creation command (fdisk) reference

Windows operating system

  1. Click the All Services > Compute > Virtual Server menu. Navigate to the Virtual Server Service Home page.
  2. Click the Block Storage menu. You will be taken to the Block Storage List page.
  3. On the Block Storage List page, click the resource to be used on the connected server. You will be taken to the Block Storage Details page.
  4. Connection Server item, verify the server and then connect.
  5. Refer to the steps below to connect the volume (Disk Online).
  • After right-clicking the Windows Start icon, run Computer Management.

  • In the Computer Management tree structure, select Storage > Disk Management

  • Check Disk

    Mount

  • Disk Online

    Mount

  • Disk initialization

    Mount

    Mount
  • Partition format

    Mount

    Mount
    Mount
  • Check volume

    Mount

Disconnect server (Umount, Disk Offline)

Access the server, perform the disconnect operations (Umount, Disk Offline), and then disconnect the server from the Console.

Follow the next procedure.

Caution
  • If you disconnect the server from the console without performing the disconnect operations (Umount, Disk Offlline) on the server, a server state error (Hang) may occur.
    • Be sure to perform the OS tasks first.
  • For the OS default volume, you cannot modify the connected server or cancel the service.

Linux operating system

  1. Click the All Services > Compute > Virtual Server menu. Navigate to the Service Home page of Virtual Server.
  2. Click the Block Storage menu. Navigate to the Block Storage List page.
  3. On the Block Storage List page, click the resource to detach the attached server. You will be taken to the Block Storage Details page.
  4. After verifying the server in the Connection Server item, connect.
  5. Refer to the steps below to unmount the volume(Umount).
    • Volume Umount
  # umount /dev/vdb1 /data

  # lsblk
  NAME    MAJ:MIN  RM   SIZE RO TYPE MOUNTPOINT
  vda       252:0   0    24G  0 disk
  ├─vda1    252:1   0  23.9G  0 part [SWAP]
  └─vda14   252:14  0     4M  0 part /
  └─vda15   252:15  0   106M  0 part /boot/efi
  vdb       252:16  0    24G  0 disk
  └─vdb1    252:17  0    24G  0 part

  # vi /etc/fstab
  (삭제) /dev/vdb1     /data       ext4     defaults   0 0

Windows operating system

  1. Click the All Services > Compute > Virtual Server menu. Navigate to the Service Home page of Virtual Server.

  2. Click the Block Storage menu. Go to the Block Storage List page.

  3. Block Storage List page, click the resource to detach the connected server. Navigate to the Block Storage Details page.

  4. In the Connection Server field, verify the server before connecting.

  5. Unmount the mounted file system.

  6. Please follow the procedure below to detach the volume (Disk Offline).

    • Right-click the Windows Start icon, then run Computer Management.

    • In the Computer Management tree structure, select Storage > Disk Management

    • Right-click the disk to be removed, then run Offline

      Umount
    • Check disk status

      Umount
How-to guides
Use Snapshot