Linux - HardwareThis forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I have a 4T Toshiba usb drive that gets mounted on boot, with a symlink to /mnt/toshiba in my home directory.
When accessing my computer via ssh (sftp from Midnight Commander) from remote, it would hang and I'd have to dump the terminal. When I ssh from a command line, it would take me to my home directory, and I could cd to sub-directories, but I could not "ls" within my home dir; again it would hang, but I can at least ctrl-C out of it
I have found that there are two directories that will hang like this, my ~ dir, and the /mnt dir, and have decided that the usb drive is the culprit. However, I can't seem to umount the toshiba ext drive, it'll just sit there and do nothing until I ctrl-C out of it. (umount /mnt/toshiba) Any suggestions on how I can un-mount this usb drive? I won't be in a position to have physical access to the computer for several days.
With Debian, after plugging in a USB drive, when you go to access it, it is automatically mounted to /media/user/DriveLabel.
If it is automatically mounted elsewhere at bootup suggests there is an entry in /etc/fstab for the USB drive.
As sudo or root, edit the /etc/fstab file and comment out the line associated with the USB drive by adding a hash "#" at the begging of the line and it will not be mounted.
It is best to create a folder in your home directory, something like "External-USB" or whatever and use that as the mount point in /etc/fstab file. This would eliminate the need for a symlink.
Many/most external USB drives go dormant (stop spinning) when not accessed within a certain amount of time. The hangs you are experiencing may be related to this feature. When trying to access it remotely, might be best to run command as sudo or root: mount -a before trying to access it or leave it unmounted and mount it before trying to access it.
Last edited by Brains; 02-06-2023 at 10:49 PM.
Reason: Spelling
With Debian, after plugging in a USB drive, when you go to access it, it is automatically mounted to /media/user/DriveLabel.
If it is automatically mounted elsewhere at bootup suggests there is an entry in /etc/fstab for the USB drive.
As sudo or root, edit the /etc/fstab file and comment out the line associated with the USB drive by adding a hash "#" at the begging of the line and it will not be mounted.
It is best to create a folder in your home directory, something like "External-USB" or whatever and use that as the mount point in /etc/fstab file. This would eliminate the need for a symlink.
Many/most external USB drives go dormant (stop spinning) when not accessed within a certain amount of time. The hangs you are experiencing may be related to this feature. When trying to access it remotely, might be best to run command as sudo or root: mount -a before trying to access it or leave it unmounted and mount it before trying to access it.
I put it in fstab myself, after a catastrophic HD failure under Mint, I loaded Debian on another HD, but Debian would not auto-mount it after plugging it in. (as it used to do under Mint) Mounting it using fstab in /mnt/toshiba, it has run for many months flawlessly, and did a middle of the night rsync as a cron event each night, so it would seem that the usb HD drive is failing / has failed, but it took me going to the physical location and un-plugging the thing, modifying fstab and crontab, and re-starting before I could access my home directory or /mnt.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.