[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <532DBFC8.4020202@gmail.com>
Date: Sat, 22 Mar 2014 17:52:24 +0100
From: Francis Moreau <francis.moro@...il.com>
To: LKML <linux-kernel@...r.kernel.org>
Subject: Can't umount /mnt/dev after calling dd(1) and with /mnt/dev is a
bind mount
Hello,
I'm posting here because it might be a behaviour related to the kernel
internals that I can't explain from my user point of view :)
Basically I'm doing this:
mount -o bind /dev/ /mnt/dev &&
chroot /mnt dd bs=440 conv=notrunc count=1 if=gptmbr.bin of=/dev/loop0
umount /mnt/dev
but umount gives the following error: "umount: /mnt/dev: target is busy"
I tried to see if any processes were still using a file in dev with
fuser(1) but there weren't. Futhermore inserting a call to fuser(1)
right before umount fixed the issue, so it really seems a timing issue.
stracing umount showed that umount failed here:
umount("/mnt/dev", 0) = -1 EBUSY (Device or resource busy)
I replaced the bind mount of /dev by:
mount -t devtmpfs none /mnt/dev
and it worked.
Could anybody tell me what I'm doing wrong ?
Thanks.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists