Bug 1710701

Summary: AFR-v2 does not log before attempting data self-heal
Product: [Red Hat Storage] Red Hat Gluster Storage Reporter: Ravishankar N <ravishankar>
Component: replicateAssignee: Ravishankar N <ravishankar>
Status: CLOSED ERRATA QA Contact: Nag Pavan Chilakam <nchilaka>
Severity: high Docs Contact:
Priority: unspecified    
Version: rhgs-3.5CC: rhs-bugs, sheggodu, storage-qa-internal, vdas
Target Milestone: ---   
Target Release: RHGS 3.5.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: glusterfs-6.0-6 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2019-10-30 12:21:27 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 1696809    

Description Ravishankar N 2019-05-16 06:37:12 UTC
This bug was initially created as a copy of Bug #1707746

I am copying this bug because: This log is very useful in knowing data self-heal is being attempted. There are many steps involved between "performing data selfheal" and "Completed data selfheal".  Without "performing data selfheal" message, it is not possible to know from the logs that shd is actually picking up the file that needs data heal when you trigger index heal. More so if the self-heal actually fails and doesn't reach th "Completed" stage.  So I'm proposing it for rhgs-3.5.0 to aid debugging experience.

==================================================
afr: log before attempting data self-heal.

    I was working on a blog about troubleshooting AFR issues and I wanted to copy
    the messages logged by self-heal for my blog. I then realized that AFR-v2 is not
    logging *before* attempting data heal while it logs it for metadata and entry
    heals.

    I [MSGID: 108026] [afr-self-heal-entry.c:883:afr_selfheal_entry_do]
    0-testvol-replicate-0: performing entry selfheal on
    d120c0cf-6e87-454b-965b-0d83a4c752bb
    I [MSGID: 108026] [afr-self-heal-common.c:1741:afr_log_selfheal]
    0-testvol-replicate-0: Completed entry selfheal on
    d120c0cf-6e87-454b-965b-0d83a4c752bb. sources=[0] 2  sinks=1
    I [MSGID: 108026] [afr-self-heal-common.c:1741:afr_log_selfheal]
    0-testvol-replicate-0: Completed data selfheal on
    a9b5f183-21eb-4fb3-a342-287d3a7dddc5. sources=[0] 2  sinks=1
    I [MSGID: 108026] [afr-self-heal-metadata.c:52:__afr_selfheal_metadata_do]
    0-testvol-replicate-0: performing metadata selfheal on
    a9b5f183-21eb-4fb3-a342-287d3a7dddc5
    I [MSGID: 108026] [afr-self-heal-common.c:1741:afr_log_selfheal]
    0-testvol-replicate-0: Completed metadata selfheal on
    a9b5f183-21eb-4fb3-a342-287d3a7dddc5. sources=[0] 2  sinks=1

    Adding it in this patch. Now there is a 'performing' and a corresponding
    'Completed' message for every type of heal.
==================================================

Comment 11 errata-xmlrpc 2019-10-30 12:21:27 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHEA-2019:3249