Bug 1198 - loop deadlock on block-backed writes
loop deadlock on block-backed writes
Product: IO/Storage
Classification: Unclassified
Component: Block Layer
i386 Linux
: P2 normal
Assigned To: Jens Axboe
Depends on:
  Show dependency treegraph
Reported: 2003-09-08 03:05 UTC by Fruhwirth Clemens
Modified: 2005-11-17 00:09 UTC (History)
0 users

See Also:
Kernel Version: 2.6.0-test4
Tree: Mainline
Regression: ---


Description Fruhwirth Clemens 2003-09-08 03:05:58 UTC
Block-backed loop devices can cause a deadlock.

How to reproduce:

You need ~100mb partition.
Boot with mem=32m (otherwise the cache will be to big in the most cases) 

swapoff -a
losetup /dev/loop0 /dev/hdXX
for i in `seq 1 10`; do
 dd if=/dev/zero of=/dev/loop0 &

Now the box "should" freeze. This doesn't happen with filebased read/write
or blockbased read. Jari's loop survives this stress test without problems.
So probably we should continue with merging his loop changes.

This is likely because blockbased writes take a different way through loop.c,
just have a look.
Comment 1 Dominik Brodowski 2005-11-16 14:29:18 UTC
Is this still a bug in recent kernels, like 2.6.14?
Comment 2 Fruhwirth Clemens 2005-11-17 00:09:56 UTC
I'm not interested to test (the initial report was in 2003). I switched over to
dm-crypt long time ago. Linux kernel bug tracking is a total mess and below all
standard seen elsewhere.

However, thanks for asking.

Note You need to log in before you can comment on or make changes to this bug.