junneyang / zumastor

Automatically exported from code.google.com/p/zumastor
0 stars 1 forks source link

mkfs.xfs hanging in 2.6.24 trunk UML tests #96

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. cd zumastor/cbtb/uml
2. ./smoke-etch.sh

What is the expected output? What do you see instead?
  Completion of the test run and PASS/FAIL for each of the smoke tests
  Instead, the mkfs.xfs in the first test hangs indefinitely at:
  + mkfs.xfs -f /dev/mapper/testvol

slogin {IPADDR} -l root
The mkfs.xfs is in D state and unkillable.  The device /dev/mapper/testvol
can still be written to using dd.

unassigned:/dev/mapper# time dd if=/dev/zero count=4k bs=4k
of=/dev/mapper/testvol
4096+0 records in
4096+0 records out
16777216 bytes (17 MB) copied, 0.14837 seconds, 113 MB/s

Performing a larger write though hangs.

unassigned:/dev/mapper# time dd if=/dev/zero count=32k bs=32k
of=/dev/mapper/testvol

On host: cd /tmp/zuma-uml.aAJBXG
du -sh *
Every 2.0s: du -sh hda.img hdb.img hdc.img              Wed Mar 26 13:06:52
2008
66M     hda.img
1.9M    hdb.img
17M     hdc.img

Every 2.0s: du -sh hda.img hdb.img hdc.img              Wed Mar 26 13:08:04
2008
66M     hda.img
1.9M    hdb.img
17M     hdc.img
Every 2.0s: du -sh hda.img hdb.img hdc.img              Wed Mar 26 13:18:27
2008
67M     hda.img
1.9M    hdb.img
17M     hdc.img

   It looks to me like the patches in the 2.6.24 zumastor branch still have
a serious I/O problem under UML.

Original issue reported on code.google.com by drake.di...@gmail.com on 26 Mar 2008 at 8:19

GoogleCodeExporter commented 9 years ago
I think this is a duplicate of Issue 76. Still valid to have.
I'm attaching a mkfs.ext3 sysrq from a test machine. The Mkfs stops when 
calling 
fsync on the ddsnap device.

Original comment by williama...@gmail.com on 27 Mar 2008 at 12:44

Attachments:

GoogleCodeExporter commented 9 years ago
I think the problem is caused by the changes on bio_endio introduced since 
2.6.24
kernel. Will, could you try the patch below after applying bio_throttle.patch? 
It
solves the hanging on my uml test. Let me know if it works for you.

--- linux-2.6.24.2/fs/bio.c     2008-04-01 10:19:43.000000000 -0700
+++ linux-2.6.24.2.new/fs/bio.c 2008-04-01 12:37:40.000000000 -0700
@@ -1007,15 +1007,15 @@ void bio_endio(struct bio *bio, int erro
        else if (!test_bit(BIO_UPTODATE, &bio->bi_flags))
                error = -EIO;

-       if (bio->bi_end_io)
-               bio->bi_end_io(bio, error);
-
-       if (!bio->bi_size && bio->bi_queue) {
+       if (bio->bi_queue) {
                struct request_queue *q = bio->bi_queue;
                atomic_add(bio->bi_max_vecs, &q->available);
                bio->bi_queue = NULL; /* 0xdeadbeef? */
                wake_up(&q->throttle_wait);
        }
+
+       if (bio->bi_end_io)
+               bio->bi_end_io(bio, error);
 }

 void bio_pair_release(struct bio_pair *bp)

Jiaying

Original comment by jiayin...@gmail.com on 1 Apr 2008 at 7:42

GoogleCodeExporter commented 9 years ago
I had to tweak the patch to get it to apply, building now.

Original comment by williama...@gmail.com on 1 Apr 2008 at 8:09

Attachments: