Bug 1223738

Summary: Allow only lookup and delete operation on file that is in split-brain
Product: [Red Hat Storage] Red Hat Gluster Storage Reporter: Shruti Sampat <ssampat>
Component: replicateAssignee: Ravishankar N <ravishankar>
Status: CLOSED ERRATA QA Contact: Shruti Sampat <ssampat>
Severity: medium Docs Contact:
Priority: medium    
Version: rhgs-3.1CC: asrivast, nsathyan, rhs-bugs, storage-qa-internal
Target Milestone: ---   
Target Release: RHGS 3.1.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: glusterfs-3.7.1-6 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
: 1235007 (view as bug list) Environment:
Last Closed: 2015-07-29 04:44:31 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:    
Bug Blocks: 1202842, 1223636, 1235007, 1235934    

Description Shruti Sampat 2015-05-21 11:21:20 UTC
Description of problem:
------------------------

Any operations on a file that is in data or meta-data split-brain should not be allowed, with the exception of lookups and deletes. 

Version-Release number of selected component (if applicable):
--------------------------------------------------------------
glusterfs-3.7.0-2.el6rhs.x86_64

How reproducible:
------------------
N/A

Steps to Reproduce:
--------------------
N/A

Actual results:
----------------

Operations other than lookup and delete (like stat, truncate etc.) are allowed on files in split-brain.

Expected results:
------------------

Allow only lookup and delete on a file that is in split-brain.

Additional info:

Comment 7 Shruti Sampat 2015-07-08 07:13:27 UTC
Verified as fixed in glusterfs-3.7.1-6

See details of test case below -

1. File in data and metadata split-brain - expected behavior is that all data and metadata operations with the exception of lookup and delete should *not* be allowed. Observations -

stat and readlink - these should be disallowed, but with performance translators turned on these are allowed as the call does not reach afr. With performance translators disabled, these are correctly blocked.

Data operations like cat, truncate, fallocate are disallowed as expected.

Metadata operations like getxattr and setxattr are disallowed as expected.

2. Directory in entry split-brain - expected behavior is that all data, metadata and entry operations are allowed. Observations -

All data and metadata operations like readdir, getxattr, setxattr are allowed as expected. All entry operations like mkdir, link, mknod, create, symlink, rename, unlink, rmdir are allowed as expected.

3. Directory in metadata split-brain - Expected is that all entry operations are allowed and that all metadata operations are disallowed. Observations -

All data and entry operations like readdir, mkdir, link, mkdnod, create, symlink, rename, unlink and rmdir are allowed as expected.

Metadata operations like getxattr and setxattr are disallowed as expected.

Comment 8 errata-xmlrpc 2015-07-29 04:44:31 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://rhn.redhat.com/errata/RHSA-2015-1495.html