Trying to Mount My Flash Drive (I think!)

This is with Zorin 16.3 Pro

Hi,

I have a flash drive that I formatted with the disk utility and then I noticed that it does not show up on the linux files utility. So, I tried to implement a mount procedure I saw on-line.

sudo -i

fdisk -l

and among the output:
Disk /dev/sda
(and includes “Disk model sandisk so it definitely “sees” the flash)

Then it said to create a target dir to be used as the USB mount point

mkdir /media/usb-drive

Then it said to execute the mount command to mount to the selected block device name to the created mount dir.

mount /dev/sda /media/usb-drive

Output:
/dev/sda already mounted or mount point busy

At this point I was on my own and don’t know how to continue. The mount point does not show up in the Files utility. I did check in Files for /dev from “Computer” and it shows file “sda” as being a block device (inode/blockdevice).

Anyway, I just want to be able to use the flash drive again.

How should I proceed?

Sometimes it’s the little things, df -h before and then again after inserting will give you your devices mount point clearly, however in this instance, /dev/sda is most likely the primary device you have Linux installed on unless you have performed an advanced installation.

Could you post the output of sudo fdisk -l and then df -h while the disk drive is removed and then again when inserted because you did write that it shows it as /dev/sda

/dev/sdb maybe your target unless of course there is multiple drives/CD/DVD etc.

1 Like

In addition to MrDeplorableUSA’s excellent comments I’d add that depending on how the drive was formatted you may need to change the ownership so that you can use as a standard user.

I typically run:
Give ownership to the logged in user (you)

sudo chown $USER [the new drive address (/dev/sdb)]

Add the drive to your group

sudo chgrp $USER [the new drive address (/dev/sdb)]

There is probably a better command that removes permissions so anyone can read and write to the drive but I don’t have it handy.

I also use lsblk to triple check the drives connected to the machine. “List the block devices and partitions”

lsblk will show the primary drive tree as /dev/sda with the partitions /dev/sda1…2…x

Hope this helps.

1 Like

Hey, thanks MrDeplorable for replying! And by the way, I was hoping Files would show the mounted flash drive.

Oh, and I definitely did not do a complicated. Just let Zorin do its thing.

BEFORE
$ sudo fdisk -l
Disk /dev/loop0: 55.68 MiB, 58363904 bytes, 113992 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

Disk /dev/loop1: 55.68 MiB, 58363904 bytes, 113992 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

Disk /dev/loop2: 42.73 MiB, 44785664 bytes, 87472 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

Disk /dev/loop3: 40.88 MiB, 42840064 bytes, 83672 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

Disk /dev/loop4: 40.44 MiB, 42393600 bytes, 82800 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

Disk /dev/sda: 238.49 GiB, 256060514304 bytes, 500118192 sectors
Disk model: SanDisk X400 M.2
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: 0xc3edf8fb

Device Boot Start End Sectors Size Id Type
/dev/sda1 * 2048 1050623 1048576 512M b W95 FAT32
/dev/sda2 1052670 500117503 499064834 238G 5 Extended
/dev/sda5 1052672 500117503 499064832 238G 83 Linux

$ sudo df -h
Filesystem Size Used Avail Use% Mounted on
udev 7.6G 0 7.6G 0% /dev
tmpfs 1.6G 1.9M 1.6G 1% /run
/dev/sda5 234G 55G 168G 25% /
tmpfs 7.7G 0 7.7G 0% /dev/shm
tmpfs 5.0M 0 5.0M 0% /run/lock
tmpfs 7.7G 0 7.7G 0% /sys/fs/cgroup
/dev/loop0 56M 56M 0 100% /snap/core18/2796
/dev/loop1 56M 56M 0 100% /snap/core18/2812
/dev/loop2 43M 43M 0 100% /snap/freecell-solitaire/2
/dev/loop3 41M 41M 0 100% /snap/snapd/20290
/dev/loop4 41M 41M 0 100% /snap/snapd/20671
/dev/sda1 511M 4.0K 511M 1% /boot/efi
tmpfs 1.6G 132K 1.6G 1% /run/user/1000

AFTER
$ sudo fdisk -l
Disk /dev/loop0: 55.68 MiB, 58363904 bytes, 113992 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

Disk /dev/loop1: 55.68 MiB, 58363904 bytes, 113992 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

Disk /dev/loop2: 42.73 MiB, 44785664 bytes, 87472 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

Disk /dev/loop3: 40.88 MiB, 42840064 bytes, 83672 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

Disk /dev/loop4: 40.44 MiB, 42393600 bytes, 82800 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

Disk /dev/sda: 238.49 GiB, 256060514304 bytes, 500118192 sectors
Disk model: SanDisk X400 M.2
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: 0xc3edf8fb

Device Boot Start End Sectors Size Id Type
/dev/sda1 * 2048 1050623 1048576 512M b W95 FAT32
/dev/sda2 1052670 500117503 499064834 238G 5 Extended
/dev/sda5 1052672 500117503 499064832 238G 83 Linux

Disk /dev/sdb: 29.3 GiB, 31457280000 bytes, 61440000 sectors
Disk model: UDisk
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: 0x107c9477
$ sudo df -h
Filesystem Size Used Avail Use% Mounted on
udev 7.6G 0 7.6G 0% /dev
tmpfs 1.6G 2.0M 1.6G 1% /run
/dev/sda5 234G 55G 168G 25% /
tmpfs 7.7G 0 7.7G 0% /dev/shm
tmpfs 5.0M 0 5.0M 0% /run/lock
tmpfs 7.7G 0 7.7G 0% /sys/fs/cgroup
/dev/loop0 56M 56M 0 100% /snap/core18/2796
/dev/loop1 56M 56M 0 100% /snap/core18/2812
/dev/loop2 43M 43M 0 100% /snap/freecell-solitaire/2
/dev/loop3 41M 41M 0 100% /snap/snapd/20290
/dev/loop4 41M 41M 0 100% /snap/snapd/20671
/dev/sda1 511M 4.0K 511M 1% /boot/efi
tmpfs 1.6G 132K 1.6G 1% /run/user/1000

Hey Norseman,

Thanks for replying! Well, I’ll hold off on that and share this. I would have anticipated the sda part of /dev/sda to be a directory. Anyway…

$ ls -l | grep sda
brw-rw---- 1 root disk 8, 0 Jan 25 09:27 sda
brw-rw---- 1 root disk 8, 1 Jan 25 09:27 sda1
brw-rw---- 1 root disk 8, 2 Jan 25 09:27 sda2
brw-rw---- 1 root disk 8, 5 Jan 25 09:27 sda5

$ cd /dev/sda
bash: cd: /dev/sda: Not a directory

But this is all new to me. Then I wonder about MrDeplorable referring to /dev/sda as a real basic pathname and so what is it doing being identified as my flash drive’s mount point?

This is the disk you need to mount:

Disk /dev/sdb: 29.3 GiB, 31457280000 bytes, 61440000 sectors
Disk model: UDisk
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: 0x107c9477

According to this output, /dev/sdb is not mounted, clearly attached just not mounted.

$ sudo df -h
Filesystem Size Used Avail Use% Mounted on
udev 7.6G 0 7.6G 0% /dev
tmpfs 1.6G 2.0M 1.6G 1% /run
/dev/sda5 234G 55G 168G 25% /
tmpfs 7.7G 0 7.7G 0% /dev/shm
tmpfs 5.0M 0 5.0M 0% /run/lock
tmpfs 7.7G 0 7.7G 0% /sys/fs/cgroup
/dev/loop0 56M 56M 0 100% /snap/core18/2796
/dev/loop1 56M 56M 0 100% /snap/core18/2812
/dev/loop2 43M 43M 0 100% /snap/freecell-solitaire/2
/dev/loop3 41M 41M 0 100% /snap/snapd/20290
/dev/loop4 41M 41M 0 100% /snap/snapd/20671
/dev/sda1 511M 4.0K 511M 1% /boot/efi
tmpfs 1.6G 132K 1.6G 1% /run/user/1000
[/quote]

You really need to be extremely careful with your /dev/sda and /dev/sdb since your OS installation is on /dev/sda. Make sure you’re typing the /dev/sdb correctly for your system even if your following a “how to”.

Since you already made the dir earlier all you should need to do is plug it in and mount it:

sudo mount /dev/sdb /media/usb-drive

Then as Norseman pointed out some systems create the drives with root(I believe Ubuntu and Zorin both do this but IDK, I don’t use either one anymore) so you can follow his advice in that post here:

HTH.

2 Likes

Oh man, just an fyi. I had a brainfart. Because my flash drive is a sandisk and /dev/sda says sandisk, I thought it was referencing my flash and not the drive in my computer.

Man!

I am curious, MrDeplorable. What linux distro do you use?

Well, it did not mount. Here is my output.

tony@zorin-1:/media$ sudo mount /dev/sdb /media/usb-drive
mount: /media/usb-drive: wrong fs type, bad option, bad superblock on /dev/sdb, missing codepage or helper program, or other error.

I use straight Debian(still ruining 11) except for wife and kids they use DebianEDU(based off of 11 as well) for their home school stuff and or central tower/server is also a DebianEDU.

As for the error, I’m assuming that the USB thumb drive was previously used with Windows but I would imagine Zorin would have the necessary filesystem type libraries installed to read it mounted a is.

Could you post the out of lsblock as well, with the drive inserted

1 Like

Here ya go:

$ tony@zorin-1:~/Documents/linux/issues/mounting$ lsblk > ./lsblk_after.txt
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT
loop0 7:0 0 55.7M 1 loop /snap/core18/2796
loop1 7:1 0 42.7M 1 loop /snap/freecell-solitaire/2
loop2 7:2 0 40.9M 1 loop /snap/snapd/20290
loop3 7:3 0 55.7M 1 loop /snap/core18/2812
loop4 7:4 0 40.4M 1 loop /snap/snapd/20671
sda 8:0 0 238.5G 0 disk
├─sda1 8:1 0 512M 0 part /boot/efi
├─sda2 8:2 0 1K 0 part
└─sda5 8:5 0 238G 0 part /
sdb 8:16 1 29.3G 0 disk

And thanks again!

As to the flash disk, I used the Disks utility to format it. I don’t remember the settings.