Skip to content

[Linux] How To Mount An USB Device

Last Updated on 2024-07-25 by Clay

Introduction

In Linux System, If we want to use USB device for accessing our data, we always need to connect our USB device to the computer, and then open the folder manager, click the USB device that computer detected.

But this is not a only way. Today I have a new situation: My USB device is connected at my computer, but I can't found the device in the path "/media/".

It was because we not use graphical desktop environment, there is no any file manager can mount the device automatically. So we need to use the command mount to mount our USB device to a folder.


Mount USB device

If we want to mount our USB device, first we need to find out the name of our USB device. We can use the following command:

lsblk


And we can see:

Take my computer as an example, "sda" is my system disk, so the "sdc" under it is my USB device (and its volume is the same as my USB device).

If we are not quite sure which device is our USB device, maybe you can use the following instruction to recheck:

sudo fdisk -l


So now we know which USB device is, and then mount it to a folder. I suggest creating a new USB folder:

sudo mkdir /mnt/usb


After we creating a new folder, use mount command and its format is mount <DEVICE_PARTITION> <FOLDER>:

sudo mount /dev/sdc1 /mnt/usb


In this way, we can see the contents of our USB device under the path "/mnt/usb/". Be note, the mount objection is partition not disk.

Okay, now we can access the data at our USB device.


Unmount USB Device

After the end of the working phase, we better use the umount command to complete the "unmount" action. This is also better for USB devices.

sudo umount /dev/sdc1


This concludes the record of mounting and unmounting USB devices in the Linux operating system.


References


Read more

If you want to refer to the practice of permanently mounting the hard disk on the computer, you may refer to what I wrote before: [Linux] How to mount a hard disk drive

Tags:

Leave a Reply