lkml.org 
[lkml]   [1999]   [May]   [10]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: loop device
On Mon, May 10, 1999 at 12:05:31AM -0400, W. Michael Petullo wrote:
> Mounting a filesystem image with `mount -t ext2 -o loop=/dev/loop1 foo
> bar` works fine -- the first time. Unmounting it also works. However
> once I have executed the above mount/unmount commands, any successive
> mount using /dev/loop1 fails with: "ioctl: LOOP_SET_FD: Device or resource
> busy."

We've had this before.. you've got /etc/mtab as a symlink to /proc/mounts,
haven't you?

When mount is used to create a loop device, it attempts to record the
fact that it has done so in /etc/mtab so it knows to delete it on umount.
If /etc/mtab is a symlink to /proc/mounts then this is not possible.
You must therefore use losetup to delete the mount yourself.

--
Matthew Wilcox <willy@bofh.ai>
"Windows and MacOS are products, contrived by engineers in the service of
specific companies. Unix, by contrast, is not so much a product as it is a
painstakingly compiled oral history of the hacker subculture." - N Stephenson

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:51    [from the cache]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and my Meterkast|Read the blog