ObjectiveThe procedure on how to mount USB drive on Kali Linux is no different from any other Linux distribution. Kali Linux was used by this guide to provide you with simple to follow steps on how to mount USB drive on Linux.
Operating System and Software Versions
- Operating System: - Kali Linux
RequirementsPrivileged access to your Kali Linux system will be required.
- # - requires given linux commands to be executed with root privileges either directly as a root user or by use of
- $ - requires given linux commands to be executed as a regular non-privileged user
BLUE SKY STUDIOS are looking for Linux Administrator to maintain and support the Studio's 450+ production Linux workstations, including daily interactions with the Studio’s digital animation artists.
LOCATION: Greenwich, Connecticut, USA
USB Block Device NameGiven you have already inserted your USB drive into your computer, we first need to determine a block device name of your USB partitions. The easiest way to approach this is by executing
fdisk -lcommand to list all drives and their associated partitions.
# fdisk -l ... ... Disk /dev/sdc: 1.9 GiB, 2064646144 bytes, 4032512 sectors Units: sectors of 1 * 512 = 512 bytes Sector size (logical/physical): 512 bytes / 512 bytes I/O size (minimum/optimal): 512 bytes / 512 bytes Disklabel type: dos Disk identifier: 0x0c56e3d1 Device Boot Start End Sectors Size Id Type /dev/sdc1 2048 4032511 4030464 1.9G b W95 FAT32Scan through the output of the above
fdisk -lcommand and find partition block name. In the example above it is
Create Mount PointNext, create a mount point to serve as a destination target directory for USB partition mount. This directory will after we mount the above USB partition contain all files stored your USB drive. Choose any name for your USB mount point directory, e.g.,
# mkdir /media/usb-drive
Mount USB driveAt this stage, we are ready to mount our USB drive partition. Execute, the below mount command while replacing the block device path ( /dev/sdc1 ) with the one you took a note about previously.
# mount /dev/sdc1 /media/usb-drive/
Access Your USB driveOptionally check to see whether your USB drive has been mounted correctly using the following linux command:
# mount | grep sdc1 /dev/sdc1 on /media/usb-drive type vfat (rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=utf8,shortname=mixed,errors=remount-ro)Access your files on your USB drive by navigating to the previously created mount point directory
# cd /media/usb-drive # ls
Unmount USBDo not remove your USB drive before you do not perform a proper umount otherwise your risk losing your data:
# umount /media/usb-drive
# ls -l /dev/disk/by-uuid/*Create a new
# echo "/dev/disk/by-uuid/1D83-5BFF /media/usb-drive vfat 0 0" >> /etc/fstabYour USB drive will now mount automatically after reboot. Please, note that the UUID uniqueness is not guaranteed. It is recommended to use partition tags instead, but that is a tale for another time.