LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 08-22-2004, 04:36 AM   #1
Moebius
Member
 
Registered: Dec 2002
Location: Milwaukee, WI
Distribution: Ubuntu, Kubuntu, Debian, CentOS
Posts: 216

Rep: Reputation: 30
umount - device is busy - with what???


Quite often when I try to umount a drive (my iPod for instance) it get an error saying it's busy. But it's quite clearly not. There are no applications open that are using it and I'm not in that drive in a shell. Is there a way to see what is keeping that device busy? I get this error with a number of different hard drives. Firewire and USB.

Thanks!
 
Old 08-22-2004, 04:46 AM   #2
david_ross
Moderator
 
Registered: Mar 2003
Location: Scotland
Distribution: Slackware, RedHat, Debian
Posts: 12,047

Rep: Reputation: 79
You could try using lsof. I have noticed in the past that some applications such as konqueror appear to stop you unmounting partitions while they are running.

What proccesses are running when you try to unount:
ps -ef
 
Old 08-22-2004, 06:27 AM   #3
amosf
Senior Member
 
Registered: Jun 2004
Location: Australia
Distribution: Mandriva/Slack - KDE
Posts: 1,672

Rep: Reputation: 46
try fuser on the mounted device... man fuser for details.
 
Old 08-23-2004, 04:10 AM   #4
Moebius
Member
 
Registered: Dec 2002
Location: Milwaukee, WI
Distribution: Ubuntu, Kubuntu, Debian, CentOS
Posts: 216

Original Poster
Rep: Reputation: 30
thanks amosf. That fuser app is helpful! It turned out that famd was keeping those drives busy for some reason. So I stopped the server, umounted the drives and restarted the service.

Thanks for the help.
 
Old 08-23-2004, 05:19 AM   #5
amosf
Senior Member
 
Registered: Jun 2004
Location: Australia
Distribution: Mandriva/Slack - KDE
Posts: 1,672

Rep: Reputation: 46
It's nearly always fam... it's the app that auto updates the file manager... Usually

fuser -k /device

will kill the fam process that is stopping you...
 
Old 08-29-2004, 02:22 PM   #6
Moebius
Member
 
Registered: Dec 2002
Location: Milwaukee, WI
Distribution: Ubuntu, Kubuntu, Debian, CentOS
Posts: 216

Original Poster
Rep: Reputation: 30
OK I'm having a new problem now where a drive isn't umounting even if fuser says there are no processed using it.

root@moebius /home/zac # umount /mnt/movies
umount: /mnt/movies: device is busy
umount: /mnt/movies: device is busy
root@moebius /home/zac # fuser -v /mnt/movies

USER PID ACCESS COMMAND
/mnt/movies root kernel mount /mnt/movies

any ideas here?
 
Old 08-29-2004, 03:12 PM   #7
Not now, John!
Member
 
Registered: Jul 2004
Distribution: LFS 5.1
Posts: 161

Rep: Reputation: 30
I always get that error message when I had been navigating some (zip, tar...) archive with KDE Konqueror. Apparently Konqueror caches files from that archive.
Also, same error message displays when I'm trying umount /mnt/disk, and my working directory is /mnt/disk.

I'm not sure what's causing problem to you.
It could be some caching thing.
Try browsing root directory of that disk and hit F5 (Refresh).
Do you still get same message?
 
Old 08-29-2004, 07:16 PM   #8
mikedeatworld
Member
 
Registered: Nov 2003
Location: Farmington Michigan
Distribution: UBUNTU - Slackware - SuSE 9.1 - Knoppix - Fedora
Posts: 828

Rep: Reputation: 30
Did you get your iPod to work with Linux?
 
Old 08-29-2004, 07:19 PM   #9
Moebius
Member
 
Registered: Dec 2002
Location: Milwaukee, WI
Distribution: Ubuntu, Kubuntu, Debian, CentOS
Posts: 216

Original Poster
Rep: Reputation: 30
mikedeatworld, yes i got my iPod working.
 
Old 08-30-2004, 04:19 AM   #10
chozas
LQ Newbie
 
Registered: Aug 2004
Distribution: Debian
Posts: 5

Rep: Reputation: 0
Have you tried to run fuser but with the option -m so it can give you the pid of the process using the device and then search it using ps -A
 
Old 09-01-2004, 02:53 PM   #11
streamy
LQ Newbie
 
Registered: Sep 2004
Posts: 1

Rep: Reputation: 0
The Konqueror can (will) block umounts when it is configured to keep one or more instances preloaded. Go to Konq settings, performance, and set instances to keep preloaded to 0.
 
Old 09-09-2004, 02:10 AM   #12
ajosshi
LQ Newbie
 
Registered: Sep 2004
Posts: 1

Rep: Reputation: 1
Smile "-l" option resolved the problem

I had encountered the same problem, and the "-l" option resolved the problem.

umount /mnt/movies -l

Please refer to the man-page of the umount for more detail.
 
1 members found this post helpful.
Old 09-09-2004, 07:33 AM   #13
SteveGodfrey
LQ Newbie
 
Registered: May 2004
Distribution: Fedora Core 2
Posts: 22

Rep: Reputation: 15
/usr/sbin/lsof +D /mnt/hdb

gives some useful info....
 
Old 10-16-2004, 06:40 PM   #14
melao
LQ Newbie
 
Registered: Oct 2004
Distribution: SuSE 9.1
Posts: 12

Rep: Reputation: 0
Quote:
Originally posted by Moebius
mikedeatworld, yes i got my iPod working.
Can you tell me how ? I just couldn't mount it!

Thanks.

Last edited by melao; 10-16-2004 at 06:44 PM.
 
Old 12-06-2004, 11:26 PM   #15
Steel_J
Member
 
Registered: Oct 2004
Location: Montreal, Canada
Distribution: Ubuntu 16.04 LTS
Posts: 359
Blog Entries: 1

Rep: Reputation: 31
Hello people!

I too use to have problems unmounting partitions for external USB and Firewire drives, samba partitions and NFS partitions and Floppy's and even CD players for god sakes.

Anyhow, I wrote a little script that fixes it.

The "umount" problems are intermittent so most of the time everything works ok, but for those times when it does not here is my easy solution and it as nothing to do with using fuser or killing obscure processes.

Here is my script:


Code:
#!/bin/bash

# This script is used to stop the xinetd service and restart it 

/etc/rc.d/init.d/xinetd stop

/etc/rc.d/init.d/xinetd start

exit
Save it in you favorite editor as "restart_xinetd" and as root, copy that script in your /USR/BIN directory.

Make sure while still in root to change it's permissions in console like so: chmod +rx restart_xinetd

Now whenever you get the dreaded " Device busy" error while unmounting, just open up a console, login as root (su) and type "restart_xinetd".

You'll be able to unmount anything you want after that and you wont kill any necessary processes or need to reboot.

This is a good workaround until a real fix is found for this bug on many distros.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
umount :device busy Pedroski Linux - Hardware 14 12-29-2004 03:37 PM
fam and umount says device is busy Brian1 Fedora 2 10-05-2004 07:33 PM
umount /var device busy winchester169 Linux - Networking 1 06-25-2004 07:53 PM
umount: /mnt/floppy: device is busy tryangle Linux - Newbie 4 11-10-2003 10:16 PM
umount: /mnt/a5: device is busy PTBmilo Linux - General 2 01-31-2003 10:48 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 03:07 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration