Bug 1316517 - [Tier]: Creation of hardlink on tiered volume failed with EXISTS
[Tier]: Creation of hardlink on tiered volume failed with EXISTS
Status: POST
Product: GlusterFS
Classification: Community
Component: tiering (Show other bugs)
mainline
x86_64 Linux
unspecified Severity high
: ---
: ---
Assigned To: Mohammed Rafi KC
bugs@gluster.org
tier-fuse-nfs-samba
: ZStream
Depends On: 1305490
Blocks: 1268895
  Show dependency treegraph
 
Reported: 2016-03-10 06:49 EST by Mohammed Rafi KC
Modified: 2016-10-19 03:11 EDT (History)
7 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: 1305490
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)
Comment 1 Vijay Bellur 2016-03-10 06:52:47 EST
REVIEW: http://review.gluster.org/13672 (tier: link file creation fails when file moved from hot to cold) posted (#1) for review on master by mohammed rafi  kc (rkavunga@redhat.com)
Comment 2 Mohammed Rafi KC 2016-03-10 09:01:41 EST
Upstream patch : http://review.gluster.org/#/c/13672/

This patch will solve the race condition with linkfile creation

When the file is in hot tier and linkfile in cold tier


1) Hardlink created on cold tier for linkfile
2) if Link creation on hot tier success then send success to application
3) else if Link creation on hot tier fails
 4) Do a lookup on hot tier with source path.
 5) if source is present
    5.1 if (gfid differ)               // File can recreate with different gfid
        5.2.1 make link call success
    5.2 else if same gfid
        5.2.1 fail the link call
 6) else if source is not present       // Either migrated or deleted
    6.1 Do lookup on dst loc in cold tier
    6.2 if (dst is not present)
        6.2.1 Created link was deleted. Fail the link call
    6.3 else if dst is present
        6.3.1 if it is linkto file // source could have deleted
            6.3.1.1 if gfid is same
               6.3.1.1.1 delete the linkfile
               6.3.1.1.2 fail the link call
            6.3.1.2 else if gfid differ
               6.3.1.2.1 Fail the link call
        6.3.2 else if it is a regular file
            6.3.2.1 if gfid is same
               6.3.2.1.1 Success the link call.
            6.3.2.2 else if gfid is different
               6.3.2.2.1 Fail the link call.
                 
7) End
Comment 3 Vijay Bellur 2016-03-10 09:22:29 EST
REVIEW: http://review.gluster.org/13672 (tier: link file creation fails when file moved from hot to cold) posted (#2) for review on master by mohammed rafi  kc (rkavunga@redhat.com)
Comment 4 Vijay Bellur 2016-03-10 12:10:13 EST
REVIEW: http://review.gluster.org/13672 (tier: link file creation fails when file moved from hot to cold) posted (#3) for review on master by mohammed rafi  kc (rkavunga@redhat.com)
Comment 5 Vijay Bellur 2016-03-11 04:01:18 EST
REVIEW: http://review.gluster.org/13672 (tier: link file creation fails when file moved from hot to cold) posted (#4) for review on master by mohammed rafi  kc (rkavunga@redhat.com)
Comment 6 Vijay Bellur 2016-03-14 06:02:52 EDT
REVIEW: http://review.gluster.org/13672 (tier: link file creation fails when file moved from hot to cold) posted (#5) for review on master by mohammed rafi  kc (rkavunga@redhat.com)
Comment 7 Mike McCune 2016-03-28 19:28:22 EDT
This bug was accidentally moved from POST to MODIFIED via an error in automation, please see mmccune@redhat.com with any questions

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