USB external disk stopped showing up on the desktop
SlackwareThis Forum is for the discussion of Slackware 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.
USB external disk stopped showing up on the desktop
I have an external 300GB USB drive. This has been happily showing up on my desktop for some time now with an appropriate little icon. I had configured it to automount, which it duly did. All was well. Until this evening.
Now, when I plug the disk in, I get no such icon. The curious thing is the disks show up just fine in fdisk -l, and I can mount them manually using the mount command as root. The same situation arises with my two other external disks (all USB hard drives, not flash drives).
I've checked whether this is just a problem with my kde profile by logging in to KDE as another user, but no joy there either. So it seems to be independent of KDE.
As a fix, I could set up the old udev rules I used to have and edit mount points for them in /etc/fstab, but this is not ideal because something which was working has now ceased to do so.
This happened to me a little while ago, but I wanted to change my partitioning, so it seemed like an opportune time to reinstall and start from scratch. After the fresh install, everything started working as expected. But now, it's gone back to not working.
My thoughts are this is a hal/udev problem, and I've tried stopping and restarting each individually, but nothing's making any difference. Even a reboot didn't fix it!
Any thoughts welcome
edit: I should add the disk's label shows up fine in /dev/disk/by-label, so it seems udev is doing its bit.
edit2: more reading done, and I've checked the contents of /media/.hal-mtab and it's empty when the disk is plugged in. Presumably it's not supposed to be? Does this mean it's hal?
At the command line, run lsusb before and after plugging in the drive. Your USB drive should appear in the list. If not then start there.
If the drive appears in the lsusb list, then udev is working. Next look at HAL polling. Run ps ax | grep polling. You should see an entry for the USB device nodes.
Also check KDE. Open the KDE Control Center. Select the Desktop tree, select the Behavior option, then select the Device Icons tab. Ensure Unmounted Removable Medium is selected.
While in the Control Center, open the KDE Components tree, select Service Manager, then ensure both KDED Media Manager and Media Notifier Daemon are enabled to start and currently running.
At the command line, run lsusb before and after plugging in the drive. Your USB drive should appear in the list. If not then start there.
Code:
pwc101@dorothy:~> /sbin/lsusb
Bus 004 Device 004: ID 045e:0040 Microsoft Corp. Wheel Mouse Optical
Bus 004 Device 003: ID 0bc2:0502 Seagate RSS LLC
Bus 004 Device 002: ID 05e3:0608 Genesys Logic, Inc. USB-2.0 4-Port HUB
Bus 004 Device 001: ID 0000:0000
Bus 003 Device 001: ID 0000:0000
Bus 002 Device 001: ID 0000:0000
Bus 001 Device 001: ID 0000:0000
pwc101@dorothy:~>
My external disk is a Seagate drive, so it's showing up fine in there.
Quote:
Originally Posted by Woodsman
If the drive appears in the lsusb list, then udev is working. Next look at HAL polling. Run ps ax | grep polling. You should see an entry for the USB device nodes
I get no output for USB, only for my DVD drive (/dev/hdc), it seems.
Quote:
Originally Posted by Woodsman
Also check KDE. Open the KDE Control Center. Select the Desktop tree, select the Behavior option, then select the Device Icons tab. Ensure Unmounted Removable Medium is selected.
This is already ticked.
Quote:
Originally Posted by Woodsman
While in the Control Center, open the KDE Components tree, select Service Manager, then ensure both KDED Media Manager and Media Notifier Daemon are enabled to start and currently running.
Both these services are running.
So it seems that hald has stopped polling for usb devices? Odd...
Is this fixable?
Last edited by pwc101; 08-13-2008 at 01:43 AM.
Reason: formatting
I'm no HAL guru, but check for files in /etc/hal/fdi/information. Possibly there is a file there for your USB hard drive that is disabling polling.
That directory was empty (as were all the others a level up).
The trouble is it's stopped working for all devices, not just a particular external disk.
I'm stumped, but I'm going to try restoring /etc from a backup of before it happened. If that solves the problem, then I'll try and find out exactly what broke, and post it here.
Ok, well, I backed up /etc, then deleted it (that was weird!), restored it from my backed up tarball and rebooted. The problem persists, so it seems to be outside of some config file in /etc. The only other place I can think where the problem might lay is in /dev.
Next on the todo list is remove hal and reinstall it (which doesn't feel like a solution!), although I've not got high hopes...
Distribution: Slackware64 14.2 and current, SlackwareARM current
Posts: 1,646
Rep:
Does it also happen in Xfce? You said you used a fresh KDE profile, but I would double check this way that it is really not KDE's fault. Else I have no real ideas, maybe remove all removable devices, stop hald and delete the files in /var/run/hald and /var/cache/hald if there are any left?
I'm not expert for this in any way but these things came to my mind. I hope it may help
Does it also happen in Xfce? You said you used a fresh KDE profile, but I would double check this way that it is really not KDE's fault. Else I have no real ideas, maybe remove all removable devices, stop hald and delete the files in /var/run/hald and /var/cache/hald if there are any left?
I'm not expert for this in any way but these things came to my mind. I hope it may help
I've tried using an Xfce profile, but don't get any media icons on the desktop, only Trash, Home, Filesystem and System icons.
Clearing out /var/chache/hald and /var/run/hald didn't fix it either.
I haven't yet tried uninstalling and reinstalling hal, but will try, just in case.
As an aside, I've realised I quite like Xfce and might stick with it. Every cloud has a silver lining, I suppose!
I was just about to start a new thread because I'm having a similar problem. I wonder if it has something to do with the latest update in KDE in slackware-current? That's the only thing that I've done recently (as far as I remember) and now USB storage devices and CD/DVD have stopped automounting and showing up in Konqueror's Show Media (system:/media).
Like you I can mount manually and my USB devices appear when I run lsusb. However, there are no processes running when I do ps ax | grep polling.
Also (if relevant), in Peripherals -> Storage Media -> Advanced, the options for Enable HAL backend and Enable CD polling are greyed out (though they are checked).
I was just about to start a new thread because I'm having a similar problem. I wonder if it has something to do with the latest update in KDE in slackware-current? That's the only thing that I've done recently (as far as I remember) and now USB storage devices and CD/DVD have stopped automounting and showing up in Konqueror's Show Media (system:/media).
Like you I can mount manually and my USB devices appear when I run lsusb. However, there are no processes running when I do ps ax | grep polling.
Also (if relevant), in Peripherals -> Storage Media -> Advanced, the options for Enable HAL backend and Enable CD polling are greyed out (though they are checked).
Any ideas?
I hate to say it, but I have the exact same problem here.
One thing to check is if you have parted installed, as per changelog (current):
Quote:
Thu Sep 11 00:49:16 CDT 2008
l/parted-1.8.8-i486-1.tgz: Moved from /extra (this is now a HAL dependency).
I haven't tried it, but I switched to XFCE, and everything seems to work fine, although strangely automounting also works in my girlfriend's profile, which uses KDE.
18:50:59.028 [I] blockdev.c:502: Probing storage device /dev/sda
Run started hald-probe-storage (10000) (0)
! full path is '/usr/lib/hal/hald-probe-storage', program_dir is '/usr/lib/hal'
/usr/lib/hal/hald-probe-storage: error while loading shared libraries: libvolume_id.so.1: cannot open shared object file: No such file or directory
WAS it the exact same problem--rewriteable media--or was it cd/dvds? (including rewritable ones accessed read-only) The answer may be that some POSIX OSes may ruin rewritable media if you remove them while they are mounted: I have had a USB hard disc and several USB sticks ruined, seemingly after taking them out mounted, so if it is important, plug it into the back where you may think of umounting before going to remove. I have never seen KDE automatically unmount a device: I do not think it can--the Linux kernel will not, AFAIK.
WAS it the exact same problem--rewriteable media--or was it cd/dvds? (including rewritable ones accessed read-only) The answer may be that some POSIX OSes may ruin rewritable media if you remove them while they are mounted: I have had a USB hard disc and several USB sticks ruined, seemingly after taking them out mounted, so if it is important, plug it into the back where you may think of umounting before going to remove. I have never seen KDE automatically unmount a device: I do not think it can--the Linux kernel will not, AFAIK.
--David
Yes, the problem was USB storage devices not being mounted by hal and showing up on the desktop.
AFAIK it is impossible to automagically unmount a device when you simply pull it out.
WAS it the exact same problem--rewriteable media--or was it cd/dvds? (including rewritable ones accessed read-only) The answer may be that some POSIX OSes may ruin rewritable media if you remove them while they are mounted: I have had a USB hard disc and several USB sticks ruined, seemingly after taking them out mounted, so if it is important, plug it into the back where you may think of umounting before going to remove. I have never seen KDE automatically unmount a device: I do not think it can--the Linux kernel will not, AFAIK.
--David
Windows is the same as *nix in this regard. Removeable media like USB drives must be 'safely removed' in Windows to avoid corruption. I don't know whether Windows or Linux have different odds of corruption, but it is really required to do this step in either OS regardless. Pulling a USB stick in ANY OS without unmounting it with software tools is a bad idea. Windows doesn't automatically unmount USB sticks either (and I realize Windows doesn't actually 'mount' partitions, so my terminology and even my general overview here is incorrect -- but my point is still valid). It is akin to removing a hard drive while still in use, which is obviously not a good thing. I have removed a USB stick without unmounting it once (from Slackware 12.0 or 12.1 -- I don't remember how long ago it was), but it suffered no corruption. There are really only two cases where Windows is 'safer' than Linux. Floppy drives don't need to be unmounted (but if you eject the disk while it is being written to it could be disatrous. Also, who uses floppies nowadays?) and CDs (though there is really no chance of ruining a read-only CD whether it is unmounted before ejecting or not. Also, KDE automatically unmounts the CD for me through HAL when I press the CD drive's eject button). FUD has no place here.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.