From: Nikitas Angelinas Date: Mon, 5 Dec 2011 22:31:12 +0000 (+0000) Subject: LU-717 ldiskfs: MRP-222 Replace sysname with nodename in MMP X-Git-Tag: 2.1.53~46 X-Git-Url: https://git.whamcloud.com/?p=fs%2Flustre-release.git;a=commitdiff_plain;h=b938b88935d44bd4d16ba48c7a97941676254c11 LU-717 ldiskfs: MRP-222 Replace sysname with nodename in MMP sysname holds "Linux" by default, i.e. what appears when doing a "uname -s"; nodename should be used to print the machine's hostname, i.e. what is returned when doing a "uname -n" or "hostname", and what gethostname(2)/sethostname(2) manipulate, in order to notify the administrator of the node which is contending to mount the filesystem. Andreas says this was introduced when porting the MMP patches from RHEL5 to RHEL6, and then also pushed upstream to ext4; a patch for upstream ext4 has already been submitted. Signed-off-by: Nikitas Angelinas Change-Id: I207bf145d114a9981b5a6add4bbf92ca76f71840 Reviewed-by: Andrew Perepechko Reviewed-on: http://review.whamcloud.com/1419 Tested-by: Hudson Tested-by: Maloo Reviewed-by: Andreas Dilger --- diff --git a/ldiskfs/kernel_patches/patches/ext4-mmp-rhel6.patch b/ldiskfs/kernel_patches/patches/ext4-mmp-rhel6.patch index e2942a9..9d37b39 100644 --- a/ldiskfs/kernel_patches/patches/ext4-mmp-rhel6.patch +++ b/ldiskfs/kernel_patches/patches/ext4-mmp-rhel6.patch @@ -268,7 +268,7 @@ Index: linux-stage/fs/ext4/mmp.c + mmp->mmp_check_interval = cpu_to_le16(mmp_check_interval); + bdevname(bh->b_bdev, mmp->mmp_bdevname); + -+ memcpy(mmp->mmp_nodename, init_utsname()->sysname, ++ memcpy(mmp->mmp_nodename, init_utsname()->nodename, + sizeof(mmp->mmp_nodename)); + + while (!kthread_should_stop()) { diff --git a/ldiskfs/kernel_patches/patches/ext4-mmp-sles11.patch b/ldiskfs/kernel_patches/patches/ext4-mmp-sles11.patch index 756263d..d7d5694 100644 --- a/ldiskfs/kernel_patches/patches/ext4-mmp-sles11.patch +++ b/ldiskfs/kernel_patches/patches/ext4-mmp-sles11.patch @@ -139,7 +139,7 @@ Index: linux-stage/fs/ext4/super.c + mmp->mmp_check_interval = cpu_to_le16(mmp_check_interval); + bdevname(bh->b_bdev, mmp->mmp_bdevname); + -+ memcpy(mmp->mmp_nodename, init_utsname()->sysname, ++ memcpy(mmp->mmp_nodename, init_utsname()->nodename, + sizeof(mmp->mmp_nodename)); + + while (!kthread_should_stop()) {