Using The Mount Command in Linux

Objective

Preparing a local directory to mount an external device in Linux.

Prerequisites

  1. Linux Machine

Steps

Step 1: Check and Select Disk to Mount

Check available disks by using the following command.

lsblk

In this example, we are booting from sdc, and we want to mount the sda3 drive to this instance.

Step 2: Mounting the SDA3 Drive

Make a folder which will be your mount point, remember to take note of the directory and the name. Create the folder with the following command.

mkdir targetfolder

Mount the sda3 drive with the following command.

mount /dev/sda3 /root/targetfolder

Note that the syntax of the command is

mount <drive_to_mount> <mount_location>

Step 3: Verifying the Mounted Drive

Verify whether the device has been mounted by navigating to the target folder using the following command.

cd targetfolder

Step 4: Unmounting a Mounted Device

You can unmount a currently mounted device by using the following command.

umount /dev/sda3
Updated on September 21, 2020

Was this article helpful?

Related Articles

Need Help?
Submit a ticket to us and let our professional team assists you

Support Billing Sales
Support
Billing
Sales