Re: GFS for Linux kernel 2.6.16

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Thomas Karsten wrote:
Does this mean that I just missed the time when the Linux kernel 2.6.16
was the recent one? Is the code nowhere stored, just developed in the
CVS?

Since the recent kernel version is 2.6.17 I assume that the GFS code was
already developed for 2.6.16. That's why I thought there has to be an
archive of all GFS versions somewhere (that matches the older kernel
versions, because they have been programmed for those in the past). Of
course, then I would not use the latest version of GFS but the version
that has been programmed for kernel 2.6.16.

Is there no other possibility for me than to "downgrade" it on my own
now?

Thanks,
Thomas
Hi Thomas,

CVS keeps all back versions of the code, but it's not necessarily easy to find a subset that works with a given kernel, unless it happens to be the one we're developing on. However, it shouldn't be too difficult to port the latest GFS to a different kernel.

The HEAD branch is currently set to compile against 2.6.18-rc4.
I don't know about 2.6.16 specifically, but there are only two changes necessary to
make the current HEAD branch compile against 2.6.17:

--- a/cluster/gfs-kernel/src/gfs/inode.c 2006-08-02 11:33:09.000000000 -0500 +++ b/cluster/gfs-kernel/src/gfs/inode.c 2006-08-11 14:10:26.000000000 -0500
@@ -97,7 +97,6 @@ inode_attr_in(struct gfs_inode *ip, stru
       inode->i_mtime.tv_sec = ip->i_di.di_mtime;
       inode->i_ctime.tv_sec = ip->i_di.di_ctime;
inode->i_atime.tv_nsec = inode->i_mtime.tv_nsec = inode->i_ctime.tv_nsec = 0;
-       inode->i_blksize = PAGE_SIZE;
       inode->i_blocks = ip->i_di.di_blocks <<
               (ip->i_sbd->sd_sb.sb_bsize_shift - GFS_BASIC_BLOCK_SHIFT);
       inode->i_generation = ip->i_di.di_header.mh_incarn;
--- a/cluster/gfs-kernel/src/gfs/gfs.h 2006-08-10 17:07:07.000000000 -0500
+++ b/cluster/gfs-kernel/src/gfs/gfs.h 2006-08-11 14:11:51.000000000 -0500
@@ -66,8 +67,8 @@

#define get_v2sdp(sb) ((struct gfs_sbd *)(sb)->s_fs_info)
#define set_v2sdp(sb, sdp) (sb)->s_fs_info = (sdp)
-#define get_v2ip(inode) ((struct gfs_inode *)(inode)->u.generic_ip)
-#define set_v2ip(inode, ip) (inode)->u.generic_ip = (ip)
+#define get_v2ip(inode) ((struct gfs_inode *)(inode)->i_private)
+#define set_v2ip(inode, ip) (inode)->i_private = (ip)
#define get_v2fp(file) ((struct gfs_file *)(file)->private_data)
#define set_v2fp(file, fp) (file)->private_data = (fp)
#define get_v2bd(bh) ((struct gfs_bufdata *)(bh)->b_private)

Without this patch, the symptom is this message:

acl.c:177: struct inode has no member named u

Some older kernels have issues with using mutexes vs. semaphores,
but that's easy to fix.

There's always the possibility of upgrading your kernel too.  :7)

Regards,

Bob Peterson
Red Hat Cluster Suite

--
Linux-cluster mailing list
Linux-cluster@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/linux-cluster

[Index of Archives]     [Corosync Cluster Engine]     [GFS]     [Linux Virtualization]     [Centos Virtualization]     [Centos]     [Linux RAID]     [Fedora Users]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite Camping]

  Powered by Linux