Whamcloud - gitweb
b=17895
authorkalpak <kalpak>
Mon, 2 Feb 2009 07:17:47 +0000 (07:17 +0000)
committerkalpak <kalpak>
Mon, 2 Feb 2009 07:17:47 +0000 (07:17 +0000)
i=adilger
i=alex

While using HA for Lustre servers with Linux RAID, it is possible that MMP will not detect multiple mounts. To make this work we need to unplug the device queue in RAID when the MMP block is being written. Also while reading the MMP block, we should read it from disk and not the cached one.

lustre/ChangeLog
lustre/kernel_patches/patches/md-mmp-unplug-dev-sles10.patch [new file with mode: 0644]
lustre/kernel_patches/patches/md-mmp-unplug-dev.patch [new file with mode: 0644]
lustre/kernel_patches/series/2.6-rhel4.series
lustre/kernel_patches/series/2.6-rhel5.series
lustre/kernel_patches/series/2.6-sles10.series
lustre/kernel_patches/series/2.6.22-vanilla.series

index 2112105..e8cb1df 100644 (file)
@@ -98,6 +98,16 @@ Details    : MSG_CONNECT_INITIAL is not set on the initial MDS->OST connect.
             and the MDS export cannot be reused on the OSTs until it gets
             evicted.
 
+Severity   : major
+Frequency  : rare, only if using MMP with Linux RAID
+Bugzilla   : 17895
+Description: MMP doesn't work with Linux RAID
+Details    : While using HA for Lustre servers with Linux RAID, it is possible
+            that MMP will not detect multiple mounts. To make this work we
+            need to unplug the device queue in RAID when the MMP block is being
+            written. Also while reading the MMP block, we should read it from
+            disk and not the cached one.
+
 --------------------------------------------------------------------------
 2009-01-15 Sun Microsystems, Inc.
        * version 1.6.7
diff --git a/lustre/kernel_patches/patches/md-mmp-unplug-dev-sles10.patch b/lustre/kernel_patches/patches/md-mmp-unplug-dev-sles10.patch
new file mode 100644 (file)
index 0000000..8bfdef3
--- /dev/null
@@ -0,0 +1,22 @@
+Index: linux-2.6.16.60-0.33/drivers/md/raid5.c
+===================================================================
+--- linux-2.6.16.60-0.33.orig/drivers/md/raid5.c
++++ linux-2.6.16.60-0.33/drivers/md/raid5.c
+@@ -900,6 +900,8 @@ static int add_stripe_bio(struct stripe_
+               bi->bi_next = *bip;
+       *bip = bi;
+       bi->bi_phys_segments ++;
++      if (bio_sync(bi) && !forwrite)
++              clear_bit(R5_UPTODATE, &sh->dev[dd_idx].flags); /* force to read from disk. */
+       spin_unlock_irq(&conf->device_lock);
+       spin_unlock(&sh->lock);
+@@ -1617,6 +1619,8 @@ static int make_request (request_queue_t
+               bi->bi_end_io(bi, bytes, 0);
+       }
+       spin_unlock_irq(&conf->device_lock);
++      if (bio_sync(bi))
++              raid5_unplug_device(q);
+       return 0;
+ }
diff --git a/lustre/kernel_patches/patches/md-mmp-unplug-dev.patch b/lustre/kernel_patches/patches/md-mmp-unplug-dev.patch
new file mode 100644 (file)
index 0000000..0334abd
--- /dev/null
@@ -0,0 +1,22 @@
+Index: linux-2.6.22.14/drivers/md/raid5.c
+===================================================================
+--- linux-2.6.22.14.orig/drivers/md/raid5.c
++++ linux-2.6.22.14/drivers/md/raid5.c
+@@ -1268,6 +1268,8 @@ static int add_stripe_bio(struct stripe_
+               bi->bi_next = *bip;
+       *bip = bi;
+       bi->bi_phys_segments ++;
++      if (bio_sync(bi) && !forwrite)
++              clear_bit(R5_UPTODATE, &sh->dev[dd_idx].flags); /* force to read from disk. */
+       spin_unlock_irq(&conf->device_lock);
+       spin_unlock(&sh->lock);
+@@ -2972,6 +2974,8 @@ static int make_request(request_queue_t 
+                             test_bit(BIO_UPTODATE, &bi->bi_flags)
+                               ? 0 : -EIO);
+       }
++      if (bio_sync(bi))
++              raid5_unplug_device(q);
+       return 0;
+ }
index 8cdcacb..6f7c5dd 100644 (file)
@@ -39,3 +39,4 @@ quota-deadlock-on-pagelock-ext3.patch
 vfs-keep-inode-hashed-for-clear-inode.patch
 modpost_external_module_updates_rhel4.patch
 mpt-fusion-downgrade-to-3_02_73-rhel4.patch
+md-mmp-unplug-dev-sles10.patch
index c1bfc94..71e15ef 100644 (file)
@@ -20,3 +20,4 @@ md-rebuild-policy.patch
 md-soft-lockups.patch
 jbd-journal-chksum-2.6.18-vanilla.patch
 quota-large-limits-rhel5.patch
+md-mmp-unplug-dev.patch
index 9a86b21..f36093d 100644 (file)
@@ -14,3 +14,4 @@ quota-fix-oops-in-invalidate_dquots.patch
 fmode-exec-2.6-sles10.patch
 jbd-journal-chksum-2.6-sles10.patch
 quota-large-limits-sles10.patch
+md-mmp-unplug-dev-sles10.patch
index 2d29ae1..b1f1b08 100644 (file)
@@ -11,3 +11,4 @@ export-2.6.18-vanilla.patch
 export-show_task-2.6.18-vanilla.patch 
 sd_iostats-2.6.22-vanilla.patch
 quota-large-limits-rhel5.patch
+md-mmp-unplug-dev.patch