Hello everyone!<div><br></div><div>I was able to get debian 2.6.32-5 source patched with lustre and was able to mount and copy some files in to the new file system.  I only tried x86_64 builds and applied SLES11 patches.  So I wanted to share this with everyone.  Or maybe pkg maintainer can add some patches to current debian build and maintain it.  I do not have regression scripts or don't know enough about Lustre so I can't guarantee if this is fully working, so please do not use this for your production machines until one of packaging experts can validate that this is stable.</div>
<div><br></div><div>I followed instructions at <a href="http://wiki.lustre.org/index.php/Debian_Install">http://wiki.lustre.org/index.php/Debian_Install</a>.  Instead of 2.6.18 I've downloaded 2.6.32.  Everything went smoothly until kernel patching step.  I had to do following to get it working.</div>
<div><br></div><div><div>- Copy 2.6-sles11-2.6.32.series to 2.6.32-vanilla.series  (configure detects debian source as 2.6.32-vanilla)</div><div>- Remove cacheflush_remove_mark_rodata.patch from 2.6.32-vanilla.series (This one is already in current debian patches).</div>
<div>- Eliminated some warnings.  This step may not be necessary.  There are more, but it wasn't anything that I would be using so I didn't bother.  None of these are related to Lustre.</div><div>  - <a href="http://git.kernel.org/?p=linux/kernel/git/hjl/linux-2.6.37.y.git;a=commitdiff_plain;h=2c5ce9c1b8eb927c131a31d4466e24e00647e9cb">http://git.kernel.org/?p=linux/kernel/git/hjl/linux-2.6.37.y.git;a=commitdiff_plain;h=2c5ce9c1b8eb927c131a31d4466e24e00647e9cb</a></div>
<div>  - <a href="http://www.mail-archive.com/acpi-bugzilla@lists.sourceforge.net/msg30180.html">http://www.mail-archive.com/acpi-bugzilla@lists.sourceforge.net/msg30180.html</a></div><div>  - <a href="http://answers.softpicks.net/answers/topic/-patch-6-6-virtio-fix-section-mismatch-warnings-2160406-1.htm">http://answers.softpicks.net/answers/topic/-patch-6-6-virtio-fix-section-mismatch-warnings-2160406-1.htm</a></div>
<div>- CONFIG_SCSI_PROC_FS=y added to .config.  Without this symbol will be missed and can't compile.</div><div>- added EXPORT_SYMBOL(jbd2_log_start_commit); to fs/jbd2/journal.c.  Otherwise ldiskfs module load will fail.</div>
</div><div><br></div><div>Then kernel compiles ok with make-kpkg.</div><div><br></div><div>Lustre kernel module compile took alot more effort.  m-a a-i fails.  It doesn't know what kernel it was dealing with so I had to fool it in the autoMakefile.  In ldiskfs/ldiskfs/autoMakefile, set LDISKFS_SERIES to 2.6-sles11.series. (Or maybe create 2.6.32-vanilla.series and set it here?)</div>
<div><br></div><div>Below are the patches I had to make to patches in order to get it working.</div><div> </div><div><div>diff -urN lustre/ldiskfs/kernel_patches/patches/ext4-big-endian-check-2.6-sles11.patch lustre_latest/ldiskfs/kernel_patches/patches/ext4-big-endian-check-2.6-sles11.patch</div>
<div>--- lustre/ldiskfs/kernel_patches/patches/ext4-big-endian-check-2.6-sles11.patch2010-06-24 23:23:17.000000000 -0500</div><div>+++ lustre_latest/ldiskfs/kernel_patches/patches/ext4-big-endian-check-2.6-sles11.patch 2011-05-23 03:13:23.000000000 -0500</div>
<div>@@ -11,19 +11,16 @@</div><div>  ext4_fsblk_t ext4_block_bitmap(struct super_block *sb,</div><div>                               struct ext4_group_desc *bg)</div><div>  {</div><div>-@@ -1291,7 +1293,7 @@ enum {</div><div>
+@@ -1291,6 +1293,7 @@ enum {</div><div>        Opt_stripe, Opt_delalloc, Opt_nodelalloc,</div><div>        Opt_block_validity, Opt_noblock_validity,</div><div>        Opt_inode_readahead_blks, Opt_journal_ioprio,</div><div>
--      Opt_discard, Opt_nodiscard,</div><div>-+      Opt_discard, Opt_nodiscard, Opt_bigendian_extents,</div><div>++      Opt_bigendian_extents,</div><div>        Opt_iopen, Opt_noiopen, Opt_iopen_nopriv,</div><div>  };</div>
<div>  </div><div>-@@ -1353,6 +1355,7 @@ static const match_table_t tokens = {</div><div>+@@ -1353,4 +1355,5 @@ static const match_table_t tokens = {</div><div>        {Opt_noauto_da_alloc, "noauto_da_alloc"},</div>
<div>-       {Opt_discard, "discard"},</div><div>-       {Opt_nodiscard, "nodiscard"},</div><div> +      {Opt_bigendian_extents, "bigendian_extents"},</div><div>        {Opt_err, NULL},</div>
<div>  };</div><div>diff -urN lustre/ldiskfs/kernel_patches/patches/ext4-lustre-i_version.patch lustre_latest/ldiskfs/kernel_patches/patches/ext4-lustre-i_version.patch</div><div>--- lustre/ldiskfs/kernel_patches/patches/ext4-lustre-i_version.patch   2010-06-24 23:23:17.000000000 -0500</div>
<div>+++ lustre_latest/ldiskfs/kernel_patches/patches/ext4-lustre-i_version.patch   2011-05-23 03:14:38.000000000 -0500</div><div>@@ -12,9 +12,9 @@</div><div>   * storage for cached extent</div><div>   */</div><div> @@ -138,6 +140,8 @@ struct ext4_inode_info {</div>
<div>-        */</div><div>-       tid_t i_sync_tid;</div><div>-       tid_t i_datasync_tid;</div><div>+       struct list_head i_aio_dio_complete_list;</div><div>+       /* current io_end structure for async DIO write*/</div>
<div>+       ext4_io_end_t *cur_aio_dio;</div><div> +</div><div> +      __u64 i_fs_version;</div><div>  };</div><div>diff -urN lustre/ldiskfs/kernel_patches/patches/ext4-mballoc-extra-checks-sles11.patch lustre_latest/ldiskfs/kernel_patches/patches/ext4-mballoc-extra-checks-sles11.patch</div>
<div>--- lustre/ldiskfs/kernel_patches/patches/ext4-mballoc-extra-checks-sles11.patch2010-06-24 23:23:17.000000000 -0500</div><div>+++ lustre_latest/ldiskfs/kernel_patches/patches/ext4-mballoc-extra-checks-sles11.patch 2011-05-23 03:12:13.000000000 -0500</div>
<div>@@ -123,7 +123,7 @@</div><div>        ext4_lock_group(sb, group);</div><div>        memcpy(&sg, ext4_get_group_info(sb, group), i);</div><div>        ext4_unlock_group(sb, group);</div><div>-       ext4_mb_unload_buddy(&e4b);</div>
<div>+       ext4_mb_release_desc(&e4b);</div><div>  </div><div> -      seq_printf(seq, "#%-5u: %-5u %-5u %-5u [", group, sg.info.bb_free,</div><div> +      seq_printf(seq, "#%-5u: %-5u %-5u %-5u %-5u [", group,</div>
<div>diff -urN lustre/ldiskfs/kernel_patches/patches/ext4-mmp-sles11.patch lustre_latest/ldiskfs/kernel_patches/patches/ext4-mmp-sles11.patch</div><div>--- lustre/ldiskfs/kernel_patches/patches/ext4-mmp-sles11.patch 2010-06-24 23:23:17.000000000 -0500</div>
<div>+++ lustre_latest/ldiskfs/kernel_patches/patches/ext4-mmp-sles11.patch  2011-05-23 03:10:09.000000000 -0500</div><div>@@ -397,6 +397,10 @@</div><div>        }</div><div> +      if (sbi->s_mmp_tsk)</div><div> +              kthread_stop(sbi->s_mmp_tsk);</div>
<div>+       percpu_counter_destroy(&sbi->s_freeblocks_counter);</div><div>+       percpu_counter_destroy(&sbi->s_freeinodes_counter);</div><div>+       percpu_counter_destroy(&sbi->s_dirs_counter);</div>
<div>+       percpu_counter_destroy(&sbi->s_dirtyblocks_counter);</div><div>  failed_mount2:</div><div>        for (i = 0; i < db_count; i++)</div><div>                brelse(sbi->s_group_desc[i]);</div><div>
diff -urN lustre/ldiskfs/kernel_patches/patches/ext4-osd-iop-common-sles11.patch lustre_latest/ldiskfs/kernel_patches/patches/ext4-osd-iop-common-sles11.patch</div><div>--- lustre/ldiskfs/kernel_patches/patches/ext4-osd-iop-common-sles11.patch     2010-06-24 23:23:17.000000000 -0500</div>
<div>+++ lustre_latest/ldiskfs/kernel_patches/patches/ext4-osd-iop-common-sles11.patch       2011-05-23 03:19:24.000000000 -0500</div><div>@@ -119,7 +119,7 @@</div><div> -retry:</div><div> -      handle = ext4_journal_start(dir, EXT4_DATA_TRANS_BLOCKS(dir->i_sb) +</div>
<div> -                                      EXT4_INDEX_EXTRA_TRANS_BLOCKS + 3 +</div><div>--                                      EXT4_MAXQUOTAS_INIT_BLOCKS(dir->i_sb));</div><div>+-                                      2*EXT4_QUOTA_INIT_BLOCKS(dir->i_sb));</div>
<div>        if (IS_ERR(handle))</div><div>                return PTR_ERR(handle);</div><div>  </div><div>diff -urN lustre/ldiskfs/kernel_patches/patches/ext4-pdir-fix.patch lustre_latest/ldiskfs/kernel_patches/patches/ext4-pdir-fix.patch</div>
<div>--- lustre/ldiskfs/kernel_patches/patches/ext4-pdir-fix.patch   2010-06-24 23:23:17.000000000 -0500</div><div>+++ lustre_latest/ldiskfs/kernel_patches/patches/ext4-pdir-fix.patch    2011-05-23 03:18:23.000000000 -0500</div>
<div>@@ -6,13 +6,13 @@</div><div>  #include <linux/blockgroup_lock.h></div><div>  #include <linux/percpu_counter.h></div><div> +#include <linux/dynlocks.h></div><div>- #ifdef __KERNEL__</div><div>- #include <linux/compat.h></div>
<div>- #endif</div><div>+</div><div>+ #define USE_I_FS_VERSION</div><div>+</div><div> @@ -56,7 +57,9 @@ struct ext4_inode_info {</div><div>        __u32   i_flags;</div><div>-       __u32   i_dtime;</div><div>        ext4_fsblk_t    i_file_acl;</div>
<div>+       __u32   i_dtime;</div><div> -</div><div> +      /* following fields for parallel directory operations -bzzz */</div><div> +      struct dynlock   i_htree_lock;</div><div>diff -urN lustre/ldiskfs/kernel_patches/patches/ext4-prealloc-sles11.patch lustre_latest/ldiskfs/kernel_patches/patches/ext4-prealloc-sles11.patch</div>
<div>--- lustre/ldiskfs/kernel_patches/patches/ext4-prealloc-sles11.patch    2010-06-24 23:23:17.000000000 -0500</div><div>+++ lustre_latest/ldiskfs/kernel_patches/patches/ext4-prealloc-sles11.patch    2011-05-23 03:10:59.000000000 -0500</div>
<div>@@ -330,7 +330,7 @@</div><div>  </div><div>        /* don't use group allocation for large files */</div><div>        size = max(size, isize);</div><div>--      if (size > sbi->s_mb_stream_request) {</div><div>
+-      if (size >= sbi->s_mb_stream_request) {</div><div> +      if (size > sbi->s_mb_large_req) {</div><div>                ac->ac_flags |= EXT4_MB_STREAM_ALLOC;</div><div>                return;</div><div>
diff -urN lustre/ldiskfs/kernel_patches/patches/iopen-sles11.patch lustre_latest/ldiskfs/kernel_patches/patches/iopen-sles11.patch</div><div>--- lustre/ldiskfs/kernel_patches/patches/iopen-sles11.patch    2010-06-24 23:23:17.000000000 -0500</div>
<div>+++ lustre_latest/ldiskfs/kernel_patches/patches/iopen-sles11.patch     2011-05-23 03:08:50.000000000 -0500</div><div>@@ -345,10 +345,10 @@</div><div> ===================================================================</div>
<div> --- linux-2.6.27.21-0.1.orig/fs/ext4/super.c</div><div> +++ linux-2.6.27.21-0.1/fs/ext4/super.c</div><div>-@@ -955,6 +955,7 @@ enum {</div><div>+@@ -955,5 +955,6 @@ enum {</div><div>        Opt_block_validity, Opt_noblock_validity,</div>
<div>-       Opt_inode_readahead_blks, Opt_journal_ioprio,</div><div>-       Opt_discard, Opt_nodiscard,</div><div>+-      Opt_inode_readahead_blks, Opt_journal_ioprio</div><div>++      Opt_inode_readahead_blks, Opt_journal_ioprio,</div>
<div> +      Opt_iopen, Opt_noiopen, Opt_iopen_nopriv,</div><div>  };</div><div>  </div><div>@@ -501,10 +501,9 @@</div><div> ===================================================================</div><div> --- linux-2.6.27.21-0.1.orig/fs/ext4/ext4.h</div>
<div> +++ linux-2.6.27.21-0.1/fs/ext4/ext4.h</div><div>-@@ -540,6 +540,8 @@ do {                                                             \</div><div>+@@ -540,5 +540,7 @@ do {                                                             \</div>
<div>  #define EXT4_MOUNT_DATA_ERR_ABORT     0x10000000 /* Abort on file data write */</div><div>  #define EXT4_MOUNT_BLOCK_VALIDITY     0x20000000 /* Block validity checking */</div><div>- #define EXT4_MOUNT_DISCARD            0x40000000 /* Issue DISCARD requests */</div>
<div> +#define EXT4_MOUNT_IOPEN              0x80000000 /* Allow access via iopen */</div><div> +#define EXT4_MOUNT_IOPEN_NOPRIV       0x100000000ULL /* Make iopen world-readable */</div><div> </div><div>diff -urN lustre/ldiskfs/kernel_patches/series/ldiskfs-2.6-sles11.series lustre_latest/ldiskfs/kernel_patches/series/ldiskfs-2.6-sles11.series</div>
<div>--- lustre/ldiskfs/kernel_patches/series/ldiskfs-2.6-sles11.series      2010-06-24 23:23:17.000000000 -0500</div><div>+++ lustre_latest/ldiskfs/kernel_patches/series/ldiskfs-2.6-sles11.series      2011-05-23 03:19:44.000000000 -0500</div>
<div>@@ -27,5 +27,4 @@</div><div> ext4-disable-write-bar-by-default.patch</div><div> ext4-mballoc-skip-grps.patch</div><div> ext4-disable-mb-cache-sles11.patch</div><div>-ext4-bug23780-remove-i_data_sem-from-walk_space.patch</div>
<div> ext4-fiemap-2.6-rhel5.patch</div></div><div><br></div><div> Personally I am not very familiar with packaging so I just did make and make install to get the modules (running m-a a-i wiped out my changes once!).  Then I copied updated directory in to new linux kernel module directory and ran depmod -a.  I had to recompile for that last step in the kernel (journal.c) but it started working after that.  It has been less than 5 hours since I got it running so I can't tell much if it is working well or not yet but at least it doesn't show any error messages.</div>
<div><br></div><div>Regards,</div><div>Hong</div>