Bug 1259995 - fd migration to new xlator graph after graph-switch fails for unlinked files.
fd migration to new xlator graph after graph-switch fails for unlinked files.
Status: CLOSED DUPLICATE of bug 990089
Product: GlusterFS
Classification: Community
Component: fuse (Show other bugs)
mainline
Unspecified Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: bugs@gluster.org
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2015-09-04 01:42 EDT by Raghavendra G
Modified: 2015-09-04 04:51 EDT (History)
2 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2015-09-04 04:51:40 EDT
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)
regression test to trigger fd-migration failure (671 bytes, application/x-shellscript)
2015-09-04 01:42 EDT, Raghavendra G
no flags Details

  None (edit)
Description Raghavendra G 2015-09-04 01:42:11 EDT
Created attachment 1070159 [details]
regression test to trigger fd-migration failure

Description of problem:

Consider following sequence of operations:
1. fd = open ("/mnt/glusterfs/file");
2. unlink ("/mnt/glusterfs/file");
3. Do a graph-switch, lets say by adding a new brick to volume.
4. migration of fd to new graph fails. This is because as part of migration we do a lookup and open. But, lookup fails as file is already deleted and hence migration fails and fd is marked bad.

In fact this test case is already present in our regression tests, though the test checks whether the fd is just marked as bad. But the expectation of filing this bug is that migration should succeed. This is possible since there is an fd opened on brick through old-graph and hence can be duped using dup syscall.

Of course the solution outlined here doesn't cover the case where file is not present on brick at all. For eg., a new brick was added to replica set and that new brick doesn't contain the file. Now, since the file is deleted, how do replica heals that file to another brick etc.

But atleast this can be solved for those cases where file was present on a brick and fd was already opened.

I've attached regression test which can trigger this failure.


Version-Release number of selected component (if applicable):


How reproducible:


Steps to Reproduce:
1.
2.
3.

Actual results:


Expected results:


Additional info:
Comment 1 Raghavendra G 2015-09-04 04:51:40 EDT

*** This bug has been marked as a duplicate of bug 990089 ***

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