Why is my block device busy?
valdis.kletnieks at vt.edu
Tue Jan 21 12:50:41 EST 2020
On Mon, 20 Jan 2020 12:51:15 +0000, Adam Trhon said:
> mount | grep mmc
You might want to dump the *entire* output of the mount command, and
see if something is mounted via an alias or devmapper entry, or if you're
using busybox and getting a stripped-down mount output.
You should also check with 'cat /proc/mounts'.
> EXT4-fs (mmcblk1p2): mounted filesystem with ordered data mode. Opts: (null)
Looks like something did mount a filesystem on the device. You probably should
figure out who/what did it before you scribble on the device.
> Next I modified the ext driver to print stack when mounting, and I got:
> Call Trace:
> ? ext4_calculate_overhead+0x520/0x520
Looks like what I'd expect to see when in the mount syscall. What were
you expecting to see here?
If you're trying to figure out who did the mount, the kernel stack trace probably
More often, you'll need to resort to something like this:
mv /bin/mount /bin/mount.real
cat > /bin/mount
exec /bin/mount.real $*
chmod +x /bin/mount
and then look at the parent process chain of the call in the ps output.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Size: 832 bytes
Desc: not available
More information about the Kernelnewbies