Can't mount external ext4 hdd (Device or resource busy)

Asked by ichhaankur

I have a backup drive that I can't mount using nautilus or the mount command. I get the following error:
e2fsck: Device or resource busy while trying to open /dev/sdb1
Is another program using it?

As far as I can tell no other program is using it, because I started my computer and plugged in the drive.

I suspect that the drive was unmounted improperly and has some kind of "in use" flag on it. How do I fix this?

Thanks.

Question information

Language:
English Edit question
Status:
Answered
For:
Ubuntu util-linux Edit question
Assignee:
No assignee Edit question
Last query:
Last reply:
Revision history for this message
ichhaankur (n-arju-lx) said :
#1

GParted 0.6.2

Libparted 2.3
Check and repair file system (ext4) on /dev/sdb1 00:00:00 ( ERROR )

calibrate /dev/sdb1 00:00:00 ( SUCCESS )

path: /dev/sdb1
start: 63
end: 1953520064
size: 1953520002 (931.51 GiB)
check file system on /dev/sdb1 for errors and (if possible) fix them 00:00:00 ( ERROR )

e2fsck -f -y -v /dev/sdb1

Filesystem mounted or opened exclusively by another program?
e2fsck 1.41.12 (17-May-2010)
e2fsck: Device or resource busy while trying to open /dev/sdb1

========================================

Revision history for this message
actionparsnip (andrew-woodhead666) said :
#2

Can you give the output of:

mount; sudo fdisk -l

Thanks

Can you also detail how you go about disconnecting the device after use.

By the way, you can only mount partitions not drives. /dev/sdb is the drive, /dev/sdb1 is the first primary partition. Windows incorrectly calls partitions, drives which confuses users when they use an OS which correctly names things.

Revision history for this message
ichhaankur (n-arju-lx) said :
#3

Thanks for the input. Here are the results:

ichha@desktop:~$ mount
/dev/sda8 on / type ext4 (rw,errors=remount-ro,commit=0)
proc on /proc type proc (rw,noexec,nosuid,nodev)
none on /sys type sysfs (rw,noexec,nosuid,nodev)
fusectl on /sys/fs/fuse/connections type fusectl (rw)
none on /sys/kernel/debug type debugfs (rw)
none on /sys/kernel/security type securityfs (rw)
none on /dev type devtmpfs (rw,mode=0755)
none on /dev/pts type devpts (rw,noexec,nosuid,gid=5,mode=0620)
none on /dev/shm type tmpfs (rw,nosuid,nodev)
none on /var/run type tmpfs (rw,nosuid,mode=0755)
none on /var/lock type tmpfs (rw,noexec,nosuid,nodev)
/dev/sda7 on /home type ext4 (rw,commit=0)
binfmt_misc on /proc/sys/fs/binfmt_misc type binfmt_misc (rw,noexec,nosuid,nodev)
gvfs-fuse-daemon on /home/ichha/.gvfs type fuse.gvfs-fuse-daemon (rw,nosuid,nodev,user=ichha)

Disk /dev/sda: 160.0 GB, 160041885696 bytes
255 heads, 63 sectors/track, 19457 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0xecfa0195

   Device Boot Start End Blocks Id System
/dev/sda1 1 1567 12586896 27 Unknown
/dev/sda2 * 1568 1580 104422+ 7 HPFS/NTFS
/dev/sda3 1581 8435 55055944+ 7 HPFS/NTFS
/dev/sda4 8435 19336 87565313 5 Extended
/dev/sda5 8435 10461 16276480 83 Linux
/dev/sda6 10461 11069 4881408 82 Linux swap / Solaris
/dev/sda7 11069 18364 58593280 83 Linux
/dev/sda8 18364 19336 7811072 83 Linux

Disk /dev/sdb: 1000.2 GB, 1000204886016 bytes
255 heads, 63 sectors/track, 121601 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x000a10c7

   Device Boot Start End Blocks Id System
/dev/sdb1 1 121601 976760001 83 Linux

Revision history for this message
ichhaankur (n-arju-lx) said :
#4

Thanks for the input. Here are the results:

ichha@desktop:~$ mount
/dev/sda8 on / type ext4 (rw,errors=remount-ro,commit=0)
proc on /proc type proc (rw,noexec,nosuid,nodev)
none on /sys type sysfs (rw,noexec,nosuid,nodev)
fusectl on /sys/fs/fuse/connections type fusectl (rw)
none on /sys/kernel/debug type debugfs (rw)
none on /sys/kernel/security type securityfs (rw)
none on /dev type devtmpfs (rw,mode=0755)
none on /dev/pts type devpts (rw,noexec,nosuid,gid=5,mode=0620)
none on /dev/shm type tmpfs (rw,nosuid,nodev)
none on /var/run type tmpfs (rw,nosuid,mode=0755)
none on /var/lock type tmpfs (rw,noexec,nosuid,nodev)
/dev/sda7 on /home type ext4 (rw,commit=0)
binfmt_misc on /proc/sys/fs/binfmt_misc type binfmt_misc (rw,noexec,nosuid,nodev)
gvfs-fuse-daemon on /home/ichha/.gvfs type fuse.gvfs-fuse-daemon (rw,nosuid,nodev,user=ichha)

Disk /dev/sda: 160.0 GB, 160041885696 bytes
255 heads, 63 sectors/track, 19457 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0xecfa0195

   Device Boot Start End Blocks Id System
/dev/sda1 1 1567 12586896 27 Unknown
/dev/sda2 * 1568 1580 104422+ 7 HPFS/NTFS
/dev/sda3 1581 8435 55055944+ 7 HPFS/NTFS
/dev/sda4 8435 19336 87565313 5 Extended
/dev/sda5 8435 10461 16276480 83 Linux
/dev/sda6 10461 11069 4881408 82 Linux swap / Solaris
/dev/sda7 11069 18364 58593280 83 Linux
/dev/sda8 18364 19336 7811072 83 Linux

Disk /dev/sdb: 1000.2 GB, 1000204886016 bytes
255 heads, 63 sectors/track, 121601 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x000a10c7

   Device Boot Start End Blocks Id System
/dev/sdb1 1 121601 976760001 83 Linux

Revision history for this message
ichhaankur (n-arju-lx) said :
#5

I usually unmount the partition and then unplug the device.

Revision history for this message
ichhaankur (n-arju-lx) said :
#6

This time power failed, and I think that's what caused the problem.

Revision history for this message
delance (olivier-delance) said :
#7

An idea. Could you install Gparted, then run System->Administration->Gparted, unmount partition if mounted and check from Gparted. Doing by a different way could provide more data.

Revision history for this message
ichhaankur (n-arju-lx) said :
#8

I tried that as well. The partition was not mounted, but it was locked by another program, as reported by GParted. I wasn't able to run a check.

Revision history for this message
delance (olivier-delance) said :
#9

Could you report exact error message ?
Did you use hibernation functionality ?
Can you run command:
   sudo lsof /dev/sdb1
and report result

Revision history for this message
Sebastian Powell (telattract) said :
#10

I apologize I did not mean to be a source for answers about Ubuntu ...It is
actually I that needs help for I am brand new to this system and have very
little skill sets when it comes to knowing my way around....I do apologize,
I can assure you though that the level of knowledge and help that I have
received amongst the Open Source / Launch Pad and Overall Ubuntu help
experience has been more than adequate, in fact down right helpful...so I AM
SURE SOMEONE WILL ANSWER YOUR QUESTIONS PROPERLY AND BEST OF LUCK!

Respectfully,

Sebastian Powell

On Sat, Jan 1, 2011 at 2:10 AM, delance <
<email address hidden>> wrote:

> Question #139173 on util-linux in ubuntu changed:
> https://answers.launchpad.net/ubuntu/+source/util-linux/+question/139173
>
> delance posted a new comment:
> Could you report exact error message ?
> Did you use hibernation functionality ?
> Can you run command:
> sudo lsof /dev/sdb1
> and report result
>
> --
> You received this question notification because you are an answer
> contact for Ubuntu.
>

Revision history for this message
ichhaankur (n-arju-lx) said :
#11

Here is the full error message:

GParted 0.6.2

Libparted 2.3
Check and repair file system (ext4) on /dev/sdb1 00:00:00 ( ERROR )

calibrate /dev/sdb1 00:00:00 ( SUCCESS )

path: /dev/sdb1
start: 63
end: 1953520064
size: 1953520002 (931.51 GiB)
check file system on /dev/sdb1 for errors and (if possible) fix them 00:00:00 ( ERROR )

e2fsck -f -y -v /dev/sdb1

Filesystem mounted or opened exclusively by another program?
e2fsck 1.41.12 (17-May-2010)
e2fsck: Device or resource busy while trying to open /dev/sdb1

Revision history for this message
Jeruvy (jeruvy) said :
#12

Just to clarify, did the power fail on this while mounted to this machine you are working on?

Revision history for this message
ichhaankur (n-arju-lx) said :
#13

$ sudo lsof /dev/sdb1

lsof: WARNING: can't stat() fuse.gvfs-fuse-daemon file system /home/nihal/.gvfs
      Output information may be incomplete.

Revision history for this message
ichhaankur (n-arju-lx) said :
#14

Jeruvy: yes. That's what happened. Unfortunately the hdd was not on ups. The computer was.

Can you help with this problem?

Provide an answer of your own, or ask ichhaankur for more information if necessary.

To post a message you must log in.