[Bugs] [Bug 1161311] DHT + rebalance :- DATA LOSS - while file is in migration, creation of Hard-link and unlink of original file ends in data loss(both files are missing from mount and backend

bugzilla at redhat.com bugzilla at redhat.com
Tue Feb 17 16:07:47 UTC 2015


https://bugzilla.redhat.com/show_bug.cgi?id=1161311



--- Comment #4 from Anand Avati <aavati at redhat.com> ---
COMMIT: http://review.gluster.org/9105 committed in master by Raghavendra G
(rgowdapp at redhat.com) 
------
commit 7c6da2f7ceea2956197641b6cdb1e2f79cdb063e
Author: Shyam <srangana at redhat.com>
Date:   Wed Nov 12 10:12:13 2014 -0500

    cluster/dht: Fix dht_link to follow files under migration

    Currently if a file is under migration, a hardlink to that file
    is lost post migration of the file. This is due to the fact that
    the hard link is created against the cached subvol of the source
    and as the source is under migration, it shifts to a linkto file
    post migration. Thus losing the hardlink.

    This change follows the stat information that triggers a phase1/2
    detection for a file under migration, to create the link on the new
    subvol that the source file is migrating to. Thereby preserving the
    hard link post migration.

    NOTES:
    The test case added create a ~1GB file, so that we can catch the file
    during migration, smaller files may not capture this state and the
    test may fail.
    Even if migration of the file fails, we would only be left with stale
    linkto files on the subvol that the source was migrating to, which is
    not a problem.
    This change would create a double linkto, i.e new target hashed subvol
    would point to old source cached subol, which would point to the real
    cached subvol. This double redirection although not handled directly in
    DHT, works as lookup searches everywhere on hitting linkto files. The
    downside is that it never heals the new target hashed subvol linkto
    file, which is another bug to be resolved (does not cause functional
    impact).

    Change-Id: I871e6885b15e65e05bfe70a0b0180605493cb534
    BUG: 1161311
    Signed-off-by: Shyam <srangana at redhat.com>
    Reviewed-on: http://review.gluster.org/9105
    Tested-by: Gluster Build System <jenkins at build.gluster.com>
    Reviewed-by: N Balachandran <nbalacha at redhat.com>
    Reviewed-by: susant palai <spalai at redhat.com>
    Reviewed-by: venkatesh somyajulu <vsomyaju at redhat.com>
    Reviewed-by: Raghavendra G <rgowdapp at redhat.com>
    Tested-by: Raghavendra G <rgowdapp at redhat.com>

-- 
You are receiving this mail because:
You are on the CC list for the bug.
Unsubscribe from this bug https://bugzilla.redhat.com/token.cgi?t=Qv0LwY7eo6&a=cc_unsubscribe


More information about the Bugs mailing list