Linux system using the U disk method

  • 2020-05-12 06:38:21
  • OfStack

In the linux system, all the devices are files, so our U disk is also a file. The disk device is abstracted into sda file, and the U disk device is abstracted into sdb file.

1. View all device files.

In the linux file system, all device files are stored in /dev.

Enter cd /dev # into the dev folder

ls # view all files

The family called sda is a disk device, and the sdb family is an U disk device.

2. External device hardpoint

In linux, external devices need to be mounted in the /mnt folder.

cd /mnt# go to the /mnt folder

ls# lists all the files and finds none

mkdir usb # creates a folder named usb on which you will mount the usb device.

Mount the device using the mount command.

First check the specific name of U disk device in the /dev folder (starting with sdb, my U disk name is sdb4, if there are more than one, please try one by one, mine consists of two (sdb, sdb4)).

sudo mount-t vfat /dev/sdb4 /mnt/usb# mount the U disk device externally named sdb4 to the /mnt/usb folder.

cd /mnt/usb

ls# view all documents on U disk

Please uninstall the device umount /dev/sdb4 after use.

If it works, please like it.

If not, please leave a message.

Open the console and go to the device list folder. The absolute path to the dev folder is /dev

The ls command lists all files.


Related articles: