Bug 1479118 - AFR entry self heal removes a directory's .glusterfs symlink.
AFR entry self heal removes a directory's .glusterfs symlink.
Status: MODIFIED
Product: GlusterFS
Classification: Community
Component: posix (Show other bugs)
3.12
Unspecified Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Ravishankar N
: Triaged
Depends On: 1477169
Blocks:
  Show dependency treegraph
 
Reported: 2017-08-07 23:15 EDT by Ravishankar N
Modified: 2017-08-08 08:25 EDT (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: 1477169
Environment:
Last Closed:
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Ravishankar N 2017-08-07 23:15:23 EDT
+++ This bug was initially created as a clone of Bug #1477169 +++

Description of problem:
$subject

How reproducible:
100%

Steps to Reproduce:
-Create 1x2 replica, fuse mount it
-mkdir fuse_mount/d1
-mkdir fuse_mount/d1/dir
-mkdir fuse_mount/d2
-kill one brick and rename the dir: `mv fuse_mount/d1/dir use_mount/d2`
-Bring all bricks up and trigger heal.

Actual results:
fuse_mount/d2/dir won't have any gfid symlink.

Additional info:
For replica 3 volume, the heal won't even complete, see the .t attached.

--- Additional comment from Worker Ant on 2017-08-01 08:06:07 EDT ---

REVIEW: https://review.gluster.org/17945 (posix: add sanity checks for removing the gfid symlink for directories) posted (#1) for review on master by Ravishankar N (ravishankar@redhat.com)

--- Additional comment from Worker Ant on 2017-08-02 10:59:12 EDT ---

REVIEW: https://review.gluster.org/17945 (posix: add sanity checks for removing the gfid symlink for directories) posted (#2) for review on master by Ravishankar N (ravishankar@redhat.com)

--- Additional comment from Worker Ant on 2017-08-04 11:54:05 EDT ---

COMMIT: https://review.gluster.org/17945 committed in master by Jeff Darcy (jeff@pl.atyp.us) 
------
commit 42c057a6d1a03dd2825a278393acb15d52220c8d
Author: Ravishankar N <ravishankar@redhat.com>
Date:   Mon Jul 31 23:38:20 2017 +0530

    posix: add sanity checks for removing the gfid symlink for directories
    
    ...during mkdir and rmdir. Otherwise, during entry self-heal, the
    directory could be left out without a .glusterfs symlink causing fops like
    opendir, readdir to fail.  The only chance the missing symlink will be
    created is when a fresh lookup comes on it.
    
    Change-Id: I2e1cf1bce8962ea80187edd8f6d73e0a09cf9f8e
    BUG: 1477169
    Signed-off-by: Ravishankar N <ravishankar@redhat.com>
    Reviewed-on: https://review.gluster.org/17945
    Smoke: Gluster Build System <jenkins@build.gluster.org>
    CentOS-regression: Gluster Build System <jenkins@build.gluster.org>
    Reviewed-by: Raghavendra Bhat <raghavendra@redhat.com>
Comment 1 Worker Ant 2017-08-07 23:30:32 EDT
REVIEW: https://review.gluster.org/17991 (posix: add sanity checks for removing the gfid symlink for directories) posted (#1) for review on release-3.12 by Ravishankar N (ravishankar@redhat.com)
Comment 2 Worker Ant 2017-08-08 08:24:06 EDT
COMMIT: https://review.gluster.org/17991 committed in release-3.12 by Shyamsundar Ranganathan (srangana@redhat.com) 
------
commit 25ebb4d36fddb75f19c78e015aa8e9374964a5bb
Author: Ravishankar N <ravishankar@redhat.com>
Date:   Mon Jul 31 23:38:20 2017 +0530

    posix: add sanity checks for removing the gfid symlink for directories
    
    ...during mkdir and rmdir. Otherwise, during entry self-heal, the
    directory could be left out without a .glusterfs symlink causing fops like
    opendir, readdir to fail.  The only chance the missing symlink will be
    created is when a fresh lookup comes on it.
    
    > Reviewed-on: https://review.gluster.org/17945
    > Smoke: Gluster Build System <jenkins@build.gluster.org>
    > CentOS-regression: Gluster Build System <jenkins@build.gluster.org>
    > Reviewed-by: Raghavendra Bhat <raghavendra@redhat.com>
    (cherry picked from commit 42c057a6d1a03dd2825a278393acb15d52220c8d)
    
    Change-Id: I2e1cf1bce8962ea80187edd8f6d73e0a09cf9f8e
    BUG: 1479118
    Signed-off-by: Ravishankar N <ravishankar@redhat.com>
    Reviewed-on: https://review.gluster.org/17991
    Smoke: Gluster Build System <jenkins@build.gluster.org>
    CentOS-regression: Gluster Build System <jenkins@build.gluster.org>
    Reviewed-by: Shyamsundar Ranganathan <srangana@redhat.com>

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