Bug 1208124 - BitRot :- checksum value stored in xattr is different than actual value for some file (checksum is truncated if it has terminating character as part of checksum itself)
Summary: BitRot :- checksum value stored in xattr is different than actual value for s...
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: GlusterFS
Classification: Community
Component: bitrot
Version: mainline
Hardware: x86_64
OS: Linux
medium
high
Target Milestone: ---
Assignee: Venky Shankar
QA Contact:
bugs@gluster.org
URL:
Whiteboard:
Depends On:
Blocks: qe_tracker_everglades
TreeView+ depends on / blocked
 
Reported: 2015-04-01 12:56 UTC by Rachana Patel
Modified: 2019-05-11 11:34 UTC (History)
3 users (show)

Fixed In Version: glusterfs-3.8.0
Clone Of:
: 1224222 (view as bug list)
Environment:
Last Closed: 2019-05-11 11:34:48 UTC
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Embargoed:


Attachments (Terms of Use)

Description Rachana Patel 2015-04-01 12:56:46 UTC
Description of problem:
=======================
If checksum value has terminating character in checksum value, it truncates remaining part before storing in xattr. Hence checksum value is different then stored value


Version-Release number of selected component (if applicable):
=============================================================
0.803.gitf64666f.el6.x86_64

How reproducible:
=================
always

Steps to Reproduce:
===================
1. create and mount volume.
2. enable bitrot
3. create few files.
4. verify the checksum for each file

[root@rhs-client44 ~]# sha256sum /pavanbrick7/r1/rhs-client37.lab.eng.blr.redhat.com/linux-3.19/arch/alpha/include/asm/cache.h
439634a7ce7919c5b05afe05495219a3cbbcf5ced2c45f003c1db8d37a08cbd3  /pavanbrick7/r1/rhs-client37.lab.eng.blr.redhat.com/linux-3.19/arch/alpha/include/asm/cache.h
[root@rhs-client44 ~]# getfattr -d -m . -e hex /pavanbrick7/r1/rhs-client37.lab.eng.blr.redhat.com/linux-3.19/arch/alpha/include/asm/cache.h
getfattr: Removing leading '/' from absolute path names
# file: pavanbrick7/r1/rhs-client37.lab.eng.blr.redhat.com/linux-3.19/arch/alpha/include/asm/cache.h
trusted.gfid=0x3e6e212be7fa4e83861ac4224b008c16
trusted.glusterfs.bit-rot.signature=0x01000000000000000100000000000000439634a7ce7919c5b05afe05495219a3cbbcf5ced2c45f
trusted.glusterfs.bit-rot.version=0x0100000000000000551a6a04000b30ee


checksum has - 00 so remaing part (3c1db8d37a08cbd3) is truncated in trusted.glusterfs.bit-rot.signature


Actual Result:-
===============
checksum mismatch

Comment 1 Venky Shankar 2015-04-10 10:07:31 UTC
Patch[1] contains fixes for this bug which is already merged, hence moving bug to MODIFIED.

[1]: http://review.gluster.org/10118


Note You need to log in before you can comment on or make changes to this bug.