Why Is My USB Not Mounting in Ubuntu?
When you plug the USB Drive into your Ubuntu Machine, it does not show up, and there is no error prompt to help you figure out the exact issue. Well, this guide has you covered.
USB Drives or Pendrives are the go-to devices whenever anyone wants to transfer data from one machine to another. Modern Operating Systems provide the best possible data-transfer mechanics to help you benefit from the pen drive. This includes automatically mounting and unmounting external drives, loading them into the file system, and automatically marking them with a drive letter.
However, sometimes, when you attach a USB Drive to your Ubuntu machine, nothing happens, and the drive doesn’t show inside the file system. There is also no prompt from the operating system regarding any failure. If this is your case, this post will act as a guide and explain the reasons for the issue and its solution.
Table of Contents
Let’s get started!
Why Is My USB Not Mounting in Ubuntu?
If the automounting is disabled or not working properly, the USB Drive doesn’t show up when attached to an Ubuntu Machine. Moreover, there might be a case where the USB drive doesn’t connect with the PC entirely due to a hardware fault, such as the USB Port or the USB Drive.
Besides these reasons, running multiple programs in one operating system session can sometimes mess with the services used to detect and automount external drives.
Let’s review the different methods that can help you resolve this issue.
Manually Mount the USB Drive in Ubuntu
As mentioned, USB drives are automatically mounted to the file system when connected to the PC. However, if the automounting is not working properly or it is turned off for any reason, then the USB drive will not be detected by Ubuntu. In this case, you will have to mount the USB drive manually.
To manually mount the USB Drive, open a new terminal session in your Ubuntu machine by pressing “CTRL + ALT + T” and create a new directory using the following command.
sudo mkdir /media/myusb
The newly created directory will be a mount point for your USB Drive. If you are prompted to provide the root/sudo password, then type the password and press the “Enter” key.
After that, change the read and write permissions of the directory by using the following command in the terminal.
sudo chmod +rw /media/myusb
You also need to change the ownership of your created directory and to do this, run the following command.
sudo chown {user}:{group} /media/myusb
However, place your user and group’s names in the above command and then press the “Enter” key to execute it.
After that, you need to find the Device ID of the USB Drive now attached to your Ubuntu PC. For this, run the following command in the terminal session.
sudo fdisk -l
This command will display a list of all the devices connected to your Ubuntu machine. Go through this list and find the ID of the Device that matches the information of your USB Drive.
Here, the name is SDB, and the Device ID is sdb1. You can now use this device ID to mount this device to your Ubuntu OS. If the USB runs a FAT32 file system, run the following command.
sudo mount -t vfat /dev/sdb1 /media/USB -o
However, if the USB Drive runs an NTFS File System, then you will have to execute the following command in the terminal.
sudo mount -t ntfs-3g /dev/sdb1 /media/USB
By executing the commands mentioned above, you will have the USB Drive successfully mounted within your Ubuntu Filesystem.
Change the USB Port
A broken or flawed USB Port might prevent the USB drive from connecting to the PC. A USB port can easily be damaged if something disrupts the tiny pins in the drive. Sometimes, if there is a blockage (residual dust, abnormal material) on the pins, the signal gets blocked, and the Port doesn’t function properly.
Whatever the case, you must ensure the USB Port is not damaged. To do this, you must remove the USB Drive from the port and plug it into any other port on your PC. If that doesn’t help you determine whether the Port is working correctly, you can remove the USB, attach any other device (mouse, keyboard, or OTG cable), and observe if Ubuntu recognizes them.
If other devices are also not picked by your PC, the USB port needs to be repaired.
Check if the USB Drive is Damaged
Similar to a damaged port, Ubuntu cannot recognize the device and add it to the file system if the USB itself is damaged. To ensure that the USB Drive is not damaged, simply remove the drive and attach it to any other PC.
If the other PC fails to recognize the USB drive, you will probably need a new USB Drive or repair the old one.
Reboot Your Ubuntu Machine
Whenever you start up your operating system, a new session begins. In this session, all of the necessary services are loaded and executed. If you have had a long session or run multiple applications, these applications can mess with the system services.
These temporary issues can be fixed by restarting the services or the PC. However, do not shut down the Ubuntu Machine and start it again, as it can leave the state of some services to “hibernate,” which will cause them not to restart properly.
Try performing a proper restart by clicking on the “power” icon on the top-right bar on your desktop and clicking on the option “Power off / Log Out.”
After that, choose “Restart” from the options instead of “Shut down” and wait for the PC to restart properly.
After the restart, log back into your user profile, connect the USB Drive, and see if it works.
Choosing Removable Device For Virtual Machines
If you are running Ubuntu on a virtual machine, whether through a virtual box or VMware, you need to select the host with access to this USB drive right after connecting it to the PC.
To correctly choose the host, remove the USB Drive, reconnect it again to the PC, and wait for the Removable Device Prompt to show up.
You will be able to see the Device Name within this prompt. To proceed to the host selection, click on the “OK” button, which will show you the “New USB Device Detected” Window.
Within this window, ensure that you select the option “Connect to a virtual machine,” and then select the “Ubuntu OS” from the List of Virtual Machine Names, and click on the “OK” button.
After this, you will need to wait a few moments for the drive to be added to the Ubuntu File System. Once the drive loads into the File System, you will be able to use it freely.
However, if you have turned off prompts and nothing shows up when you connect the USB Drive to the PC, then select the “VM” tab and hover over the option “Removable Devices.”
After that, hover over the name of the USB Drive that you want to attach to the Ubuntu Virtual Machine and then choose the option “Connect.”
After that, you will be prompted that the USB Device is about to be disconnected from the host and connected to the virtual machine. Click on the “OK” button to confirm, and wait for the Ubuntu OS to load the USB drive into the file system.
Choose the Correct USB Controller in VMware
If you are using VMWare to run your Ubuntu Virtual machine and even shifting the USB Drive to a virtual machine doesn’t work, then chances are that you are using the wrong USB Controllers. When working with Virtual Machines, you need to specify which USB controller will be used to shift over the USB device to the Virtual Machine.
If a USB 2.0 Controller is being used to connect a USB 3.0 device to the virtual machine, then the VM will not be able to detect the USB. To fix this USB Controller mismatch, right-click on the Virtual Machine’s name and open its “Settings.”
Under the “Hardware” tab, click on the “USB Controller” tab from the left-side navigation panel to open its configuration.
After that, click on the drop-down list next to the “USB compatibility” options and select “USB 3.1.” and then click on the “OK” button.
If the virtual machine is already running, these steps will cause it to restart. Once the restart is done, log in to your user profile and perform the previous method to shift over the USB Drive to the virtual machine. Once that is done, head inside the “Files” application. You will see that your USB Drive is now connected to your Ubuntu Virtual Machine.
You have successfully mounted your USB Drive to your Ubuntu VM’s File System.
Affordable VPS Hosting With Dracula Servers
Looking for reliable and budget-friendly Virtual Private Server (VPS) hosting? Look no further than Dracula Servers. Dracula Servers offers a range of VPS hosting plans tailored to meet diverse needs. With competitive pricing, robust performance, and a user-friendly interface, it’s an excellent choice for individuals and businesses alike.
Explore the Dracula Servers website to discover hosting solutions that align with your requirements and take your online presence to new heights with their affordable and efficient VPS hosting services.
Visit Dracula Servers and experience reliable VPS hosting without breaking the bank.
Conclusion
If your USB Drive is not automatically mounted into Ubuntu’s File System, try restarting your Ubuntu OS. System services sometimes bug and fail to detect a new USB Device’s connection. If that doesn’t work, you will have to follow the process mentioned in this guide to mount the drive to the file system manually.
Apart from automounting failure, hardware failure can also occur. The hardware failure can occur in the USB port to which the pen drive is attached and in the USB drive. Try attaching the USB Device to another PC to see if it works. To check the Port, try attaching a different USB Drive to it and see if the PC recognizes it.
However, if you are using Ubuntu on a Virtual Machine, you must ensure that you have shifted the USB Drive from the Host to the VM. Also, if you are working with VMware, you will have to configure the USB Controller to use the correct USB Compatibility mode while shifting the device to the Virtual Machine.
Check out More Linux Tutorials Here!