Bug 1374567
Summary: | [Bitrot]: Recovery fails of a corrupted hardlink (and the corresponding parent file) in a disperse volume | ||
---|---|---|---|
Product: | [Community] GlusterFS | Reporter: | Kotresh HR <khiremat> |
Component: | bitrot | Assignee: | Kotresh HR <khiremat> |
Status: | CLOSED CURRENTRELEASE | QA Contact: | |
Severity: | medium | Docs Contact: | bugs <bugs> |
Priority: | unspecified | ||
Version: | 3.9 | CC: | amukherj, aspandey, bmohanra, bugs, khiremat, pkarampu, rcyriac, rhinduja, rhs-bugs, rmekala, sanandpa |
Target Milestone: | --- | ||
Target Release: | --- | ||
Hardware: | Unspecified | ||
OS: | Unspecified | ||
Whiteboard: | |||
Fixed In Version: | v3.9.1 | Doc Type: | If docs needed, set a value |
Doc Text: | Story Points: | --- | |
Clone Of: | 1374565 | Environment: | |
Last Closed: | 2017-03-08 09:33:32 UTC | Type: | Bug |
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: | 1341934, 1373520, 1374564, 1374565 | ||
Bug Blocks: |
Description
Kotresh HR
2016-09-09 05:09:39 UTC
REVIEW: http://review.gluster.org/15434 (feature/bitrot: Fix recovery of corrupted hardlink) posted (#1) for review on release-3.9 by Kotresh HR (khiremat) COMMIT: http://review.gluster.org/15434 committed in release-3.9 by Aravinda VK (avishwan) ------ commit 8781ea7ddacc602b2f23689fa5f3415aec7253f1 Author: Kotresh HR <khiremat> Date: Tue Sep 6 18:28:42 2016 +0530 feature/bitrot: Fix recovery of corrupted hardlink Problem: When a file with hardlink is corrupted in ec volume, the recovery steps mentioned was not working. Only name and metadata was healing but not the data. Cause: The bad file marker in the inode context is not removed. Hence when self heal tries to open the file for data healing, it fails with EIO. Background: The bitrot deletes inode context during forget. Briefly, the recovery steps involves following steps. 1. Delete the entry marked with bad file xattr from backend. Delete all the hardlinks including .glusters hardlink as well. 2. Access the each hardlink of the file including original from the mount. The step 2 will send lookup to the brick where the files are deleted from backend and returns with ENOENT. On ENOENT, server xlator forgets the inode if there are no dentries associated with it. But in case hardlinks, the forget won't be called as dentries (other hardlink files) are associated with the inode. Hence bitrot stube won't delete it's context failing the data self heal. Fix: Bitrot-stub should delete the inode context on getting ENOENT during lookup. >Change-Id: Ice6adc18625799e7afd842ab33b3517c2be264c1 >BUG: 1373520 >Signed-off-by: Kotresh HR <khiremat> >Reviewed-on: http://review.gluster.org/15408 >Smoke: Gluster Build System <jenkins.org> >NetBSD-regression: NetBSD Build System <jenkins.org> >CentOS-regression: Gluster Build System <jenkins.org> >Reviewed-by: Raghavendra Bhat <raghavendra> (cherry picked from commit b86a7de9b5ea9dcd0a630dbe09fce6d9ad0d8944) Change-Id: Ice6adc18625799e7afd842ab33b3517c2be264c1 BUG: 1374567 Signed-off-by: Kotresh HR <khiremat> Reviewed-on: http://review.gluster.org/15434 Smoke: Gluster Build System <jenkins.org> CentOS-regression: Gluster Build System <jenkins.org> NetBSD-regression: NetBSD Build System <jenkins.org> Reviewed-by: Atin Mukherjee <amukherj> Reviewed-by: Aravinda VK <avishwan> |