<feed xmlns='http://www.w3.org/2005/Atom'>
<title>glusterfs.git/xlators/cluster/dht/src, branch v3.7dev</title>
<subtitle></subtitle>
<link rel='alternate' type='text/html' href='http://git.gluster.org/cgit/glusterfs.git/'/>
<entry>
<title>DHT/Create : Failing to identify a linkto file in lookup_everywhere_cbk path</title>
<updated>2014-07-17T19:26:49+00:00</updated>
<author>
<name>Susant Palai</name>
<email>spalai@redhat.com</email>
</author>
<published>2014-07-09T13:31:45+00:00</published>
<link rel='alternate' type='text/html' href='http://git.gluster.org/cgit/glusterfs.git/commit/?id=52da727e7564963a8a244fc5cb7028315e458529'/>
<id>52da727e7564963a8a244fc5cb7028315e458529</id>
<content type='text'>
In case a file is not found in its cached subvol we proceed with
dht_lookup_everywhere. But as we dont add the linkto xattr to the
dictionary, we fail to identify any linkto file encountered.The
implication being we end up thinking the linkto file as a regular file
and proceed with the fop.

Change-Id: Iab02dc60e84bb1aeab49182f680c0631c33947e2
BUG: 1117923
Signed-off-by: Susant Palai &lt;spalai@redhat.com&gt;
Reviewed-on: http://review.gluster.org/8277
Reviewed-by: Vijay Bellur &lt;vbellur@redhat.com&gt;
Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
In case a file is not found in its cached subvol we proceed with
dht_lookup_everywhere. But as we dont add the linkto xattr to the
dictionary, we fail to identify any linkto file encountered.The
implication being we end up thinking the linkto file as a regular file
and proceed with the fop.

Change-Id: Iab02dc60e84bb1aeab49182f680c0631c33947e2
BUG: 1117923
Signed-off-by: Susant Palai &lt;spalai@redhat.com&gt;
Reviewed-on: http://review.gluster.org/8277
Reviewed-by: Vijay Bellur &lt;vbellur@redhat.com&gt;
Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>dht: fix rename race</title>
<updated>2014-07-17T17:30:56+00:00</updated>
<author>
<name>Jeff Darcy</name>
<email>jdarcy@redhat.com</email>
</author>
<published>2014-07-09T01:56:04+00:00</published>
<link rel='alternate' type='text/html' href='http://git.gluster.org/cgit/glusterfs.git/commit/?id=950f9d8abe714708ca62b86f304e7417127e1132'/>
<id>950f9d8abe714708ca62b86f304e7417127e1132</id>
<content type='text'>
If two clients try to rename the same file at the same time, we
sometimes end up with *no file at all* in either the old or new
location.  That's kind of bad.  The culprit seems to be some overly
aggressive cleanup code.  AFAICT, based on today's study of the code,
the intent of the changed section is to remove any linkfile we might
have created before the actual rename.  However, what we're removing
might not be our extra link.  If we're racing with another client that's
also doing a rename, it might be the only remaining link to the user's
data.  The solution, which is good enough to pass this test but almost
certainly still not complete, is to be more selective about when we do
this unlink.  Now, we only do it if we know that, at some point, we did
in fact create the link without error (notably ENOENT on the source or
EEXIST on the destination) ourselves.

Change-Id: I8d8cce150b6f8b372c9fb813c90be58d69f8eb7b
BUG: 1117851
Signed-off-by: Jeff Darcy &lt;jdarcy@redhat.com&gt;
Reviewed-on: http://review.gluster.org/8269
Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
Reviewed-by: Vijay Bellur &lt;vbellur@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
If two clients try to rename the same file at the same time, we
sometimes end up with *no file at all* in either the old or new
location.  That's kind of bad.  The culprit seems to be some overly
aggressive cleanup code.  AFAICT, based on today's study of the code,
the intent of the changed section is to remove any linkfile we might
have created before the actual rename.  However, what we're removing
might not be our extra link.  If we're racing with another client that's
also doing a rename, it might be the only remaining link to the user's
data.  The solution, which is good enough to pass this test but almost
certainly still not complete, is to be more selective about when we do
this unlink.  Now, we only do it if we know that, at some point, we did
in fact create the link without error (notably ENOENT on the source or
EEXIST on the destination) ourselves.

Change-Id: I8d8cce150b6f8b372c9fb813c90be58d69f8eb7b
BUG: 1117851
Signed-off-by: Jeff Darcy &lt;jdarcy@redhat.com&gt;
Reviewed-on: http://review.gluster.org/8269
Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
Reviewed-by: Vijay Bellur &lt;vbellur@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>dht: support heterogeneous brick sizes</title>
<updated>2014-07-12T16:20:52+00:00</updated>
<author>
<name>Jeff Darcy</name>
<email>jdarcy@redhat.com</email>
</author>
<published>2014-06-17T13:42:45+00:00</published>
<link rel='alternate' type='text/html' href='http://git.gluster.org/cgit/glusterfs.git/commit/?id=99685f18f190a73f2a46478cac0b09f4c59834b1'/>
<id>99685f18f190a73f2a46478cac0b09f4c59834b1</id>
<content type='text'>
Calculation of layouts now considers the size of each brick, so that
smaller bricks don't get an "unfair" share of allocations and start
returning ENOSPC while the larger bricks still have plenty of space.

The observation has been made that some clients might get ENOTCONN when
trying to fetch disk-size information, and end up calculating layouts
differently.  The following meta-observations can be made.

(1) This scenario is extremely unlikely in configurations with AFR.

(2) The most likely consequence of this scenario is that some files will
be placed sub-optimally by the client with the obsolete (non-weighted)
layout.  They'll still be found anyway, so this isn't a show stopper.

(3) Without this patch it's *guaranteed* that some files will be placed
sub-optimally, because any layout that fails to account for brick sizes
is sub-optimal.

(4) We shouldn't be doing fix-layout from two nodes simultaneously
anyway.  That's inefficient at best.  Any instances of such behavior are
separate bugs, which should be fixed separately.

(5) In the most extreme edge case, two nodes doing weighted and
non-weighted layout fixes could race and end up creating an internally
inconsistent layout.  This condition is still transient; it will be
detected and repaired automatically the next time anyone fetches the
layout.  (If it's not that's also a preexisting bug that can show up in
other contexts.)

In conclusion, it's not the purpose of this patch to fix bugs elsewhere
in DHT.  Its purpose is to make life incrementally better for users who
add new hardware with larger disks etc. than the older equipment.  It's
only one part of an ongoing process to improve layout management and
repair, all the way up to support for multiple hash rings or tiering.

Change-Id: I05eb6f9eface9cdaf8622e0260c8c7f29020447f
BUG: 1114680
Signed-off-by: Jeff Darcy &lt;jdarcy@redhat.com&gt;
Reviewed-on: http://review.gluster.org/8093
Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
Reviewed-by: Raghavendra G &lt;rgowdapp@redhat.com&gt;
Reviewed-by: Shyamsundar Ranganathan &lt;srangana@redhat.com&gt;
Reviewed-by: Vijay Bellur &lt;vbellur@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Calculation of layouts now considers the size of each brick, so that
smaller bricks don't get an "unfair" share of allocations and start
returning ENOSPC while the larger bricks still have plenty of space.

The observation has been made that some clients might get ENOTCONN when
trying to fetch disk-size information, and end up calculating layouts
differently.  The following meta-observations can be made.

(1) This scenario is extremely unlikely in configurations with AFR.

(2) The most likely consequence of this scenario is that some files will
be placed sub-optimally by the client with the obsolete (non-weighted)
layout.  They'll still be found anyway, so this isn't a show stopper.

(3) Without this patch it's *guaranteed* that some files will be placed
sub-optimally, because any layout that fails to account for brick sizes
is sub-optimal.

(4) We shouldn't be doing fix-layout from two nodes simultaneously
anyway.  That's inefficient at best.  Any instances of such behavior are
separate bugs, which should be fixed separately.

(5) In the most extreme edge case, two nodes doing weighted and
non-weighted layout fixes could race and end up creating an internally
inconsistent layout.  This condition is still transient; it will be
detected and repaired automatically the next time anyone fetches the
layout.  (If it's not that's also a preexisting bug that can show up in
other contexts.)

In conclusion, it's not the purpose of this patch to fix bugs elsewhere
in DHT.  Its purpose is to make life incrementally better for users who
add new hardware with larger disks etc. than the older equipment.  It's
only one part of an ongoing process to improve layout management and
repair, all the way up to support for multiple hash rings or tiering.

Change-Id: I05eb6f9eface9cdaf8622e0260c8c7f29020447f
BUG: 1114680
Signed-off-by: Jeff Darcy &lt;jdarcy@redhat.com&gt;
Reviewed-on: http://review.gluster.org/8093
Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
Reviewed-by: Raghavendra G &lt;rgowdapp@redhat.com&gt;
Reviewed-by: Shyamsundar Ranganathan &lt;srangana@redhat.com&gt;
Reviewed-by: Vijay Bellur &lt;vbellur@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>DHT/Logging</title>
<updated>2014-07-12T16:16:54+00:00</updated>
<author>
<name>Nithya Balachandran</name>
<email>nbalacha@redhat.com</email>
</author>
<published>2014-07-07T10:47:05+00:00</published>
<link rel='alternate' type='text/html' href='http://git.gluster.org/cgit/glusterfs.git/commit/?id=d5ec66032ff96d7d417b5838a6bd1a047d52204c'/>
<id>d5ec66032ff96d7d417b5838a6bd1a047d52204c</id>
<content type='text'>
Changed the log level of a message from none to debug as none does
not print a log level in the log file.

Change-Id: I463d1095d69bbd0036958282da13cb8e0226f34f
BUG: 1116797
Signed-off-by: Nithya Balachandran &lt;nbalacha@redhat.com&gt;
Reviewed-on: http://review.gluster.org/8253
Reviewed-by: Krutika Dhananjay &lt;kdhananj@redhat.com&gt;
Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
Reviewed-by: Vijay Bellur &lt;vbellur@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Changed the log level of a message from none to debug as none does
not print a log level in the log file.

Change-Id: I463d1095d69bbd0036958282da13cb8e0226f34f
BUG: 1116797
Signed-off-by: Nithya Balachandran &lt;nbalacha@redhat.com&gt;
Reviewed-on: http://review.gluster.org/8253
Reviewed-by: Krutika Dhananjay &lt;kdhananj@redhat.com&gt;
Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
Reviewed-by: Vijay Bellur &lt;vbellur@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>cluster/dht: Added logging of new layout for dir-selfheal</title>
<updated>2014-07-03T16:22:37+00:00</updated>
<author>
<name>Venkatesh Somyajulu</name>
<email>vsomyaju@redhat.com</email>
</author>
<published>2014-07-03T14:16:59+00:00</published>
<link rel='alternate' type='text/html' href='http://git.gluster.org/cgit/glusterfs.git/commit/?id=dc46d5e84f88c5cc869b78ba9db32ed4035b9121'/>
<id>dc46d5e84f88c5cc869b78ba9db32ed4035b9121</id>
<content type='text'>
Added a log which logs the new layout which will be used
for the directory self healing

It prints:

a) Subvolume name
b) Error --&gt; Is needed because layout healing depends on
             the error and having it in log will help in
             debugging
c) Start     Starting of the layout range
d) Stop      Ending of the layout range

Change-Id: I48c9c697716a899165ed29b737362a75c62e09b3
BUG: 1113066
Signed-off-by: Venkatesh Somyajulu &lt;vsomyaju@redhat.com&gt;
Reviewed-on: http://review.gluster.org/8173
Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
Reviewed-by: Vijay Bellur &lt;vbellur@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Added a log which logs the new layout which will be used
for the directory self healing

It prints:

a) Subvolume name
b) Error --&gt; Is needed because layout healing depends on
             the error and having it in log will help in
             debugging
c) Start     Starting of the layout range
d) Stop      Ending of the layout range

Change-Id: I48c9c697716a899165ed29b737362a75c62e09b3
BUG: 1113066
Signed-off-by: Venkatesh Somyajulu &lt;vsomyaju@redhat.com&gt;
Reviewed-on: http://review.gluster.org/8173
Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
Reviewed-by: Vijay Bellur &lt;vbellur@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>porting: Port for FreeBSD rebased from Mike Ma's efforts</title>
<updated>2014-07-03T00:20:34+00:00</updated>
<author>
<name>Harshavardhana</name>
<email>harsha@harshavardhana.net</email>
</author>
<published>2014-06-21T09:00:23+00:00</published>
<link rel='alternate' type='text/html' href='http://git.gluster.org/cgit/glusterfs.git/commit/?id=1b74cf992986287a510fe3b28a8ee7554e8b0992'/>
<id>1b74cf992986287a510fe3b28a8ee7554e8b0992</id>
<content type='text'>
- Provides a working Gluster Management Daemon, CLI
- Provides a working GlusterFS server, GlusterNFS server
- Provides a working GlusterFS client
- execinfo port from FreeBSD is moved into ./contrib/libexecinfo
  for ease of portability on NetBSD. (FreeBSD 10 and OSX provide
  execinfo natively)
- More portability cleanups for Darwin, FreeBSD and NetBSD
- Provides a new rc script for FreeBSD

Change-Id: I8dff336f97479ca5a7f9b8c6b730051c0f8ac46f
BUG: 1111774
Original-Author: Mike Ma &lt;mikemandarine@gmail.com&gt;
Signed-off-by: Harshavardhana &lt;harsha@harshavardhana.net&gt;
Reviewed-on: http://review.gluster.org/8141
Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
Reviewed-by: Kaleb KEITHLEY &lt;kkeithle@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
- Provides a working Gluster Management Daemon, CLI
- Provides a working GlusterFS server, GlusterNFS server
- Provides a working GlusterFS client
- execinfo port from FreeBSD is moved into ./contrib/libexecinfo
  for ease of portability on NetBSD. (FreeBSD 10 and OSX provide
  execinfo natively)
- More portability cleanups for Darwin, FreeBSD and NetBSD
- Provides a new rc script for FreeBSD

Change-Id: I8dff336f97479ca5a7f9b8c6b730051c0f8ac46f
BUG: 1111774
Original-Author: Mike Ma &lt;mikemandarine@gmail.com&gt;
Signed-off-by: Harshavardhana &lt;harsha@harshavardhana.net&gt;
Reviewed-on: http://review.gluster.org/8141
Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
Reviewed-by: Kaleb KEITHLEY &lt;kkeithle@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>dht: pass xdata to xlators above.</title>
<updated>2014-06-30T03:50:40+00:00</updated>
<author>
<name>Krishnan Parthasarathi</name>
<email>kparthas@redhat.com</email>
</author>
<published>2014-05-26T11:48:17+00:00</published>
<link rel='alternate' type='text/html' href='http://git.gluster.org/cgit/glusterfs.git/commit/?id=187a7a926b6b1b57060046a030a5d9a44000fc4b'/>
<id>187a7a926b6b1b57060046a030a5d9a44000fc4b</id>
<content type='text'>
Change-Id: I96e9feb88443fcd7da40c33c0e8c4e2645b1fcf3
BUG: 1096047
Signed-off-by: Krishnan Parthasarathi &lt;kparthas@redhat.com&gt;
Reviewed-on: http://review.gluster.org/7872
Reviewed-by: Shyamsundar Ranganathan &lt;srangana@redhat.com&gt;
Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
Reviewed-by: Vijay Bellur &lt;vbellur@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Change-Id: I96e9feb88443fcd7da40c33c0e8c4e2645b1fcf3
BUG: 1096047
Signed-off-by: Krishnan Parthasarathi &lt;kparthas@redhat.com&gt;
Reviewed-on: http://review.gluster.org/7872
Reviewed-by: Shyamsundar Ranganathan &lt;srangana@redhat.com&gt;
Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
Reviewed-by: Vijay Bellur &lt;vbellur@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>cluster/dht: handle ESTALE appropriately in rmdir codepath.</title>
<updated>2014-06-23T12:55:30+00:00</updated>
<author>
<name>Raghavendra G</name>
<email>rgowdapp@redhat.com</email>
</author>
<published>2014-06-21T13:50:46+00:00</published>
<link rel='alternate' type='text/html' href='http://git.gluster.org/cgit/glusterfs.git/commit/?id=83fa1cfe185f05319a0048a63c8c163e4e632cf7'/>
<id>83fa1cfe185f05319a0048a63c8c163e4e632cf7</id>
<content type='text'>
Till we separated the scenario of a file/directory not existing from
parent not existing [1], we used to include a subvolume in the layout
of a directory even if it is not present on that subvolume. This was
done to allow a lookup racing with mkdir to create correct layout.
However, there are other scenarios as well where a directory is not
present. One such situation is trying to create a directory after an
add-brick. Since there is no guarantee that all the ancestors are
created after an add-brick (and hence directory cannot be created), the
newly added brick should not be part of the layout. However, we used to
consider newly added brick as part of layout (even before we do
fix-layout of all the ancestors) and this was the root cause of [2].
With [1], this issue got fixed and hence [2] got fixed too. However,
[1] is not complete in the sense we didn't modify rmdir codepath
appropriately. This patch fixes that gap.

[1] http://review.gluster.org/6322
[2] https://bugzilla.redhat.com/show_bug.cgi?id=1006809

Change-Id: I79ab96bb8abb6f3d90bb6e235a1c465e1be0fd19
BUG: 1032894
Signed-off-by: Raghavendra G &lt;rgowdapp@redhat.com&gt;
Reviewed-on: http://review.gluster.org/8142
Reviewed-by: Vijay Bellur &lt;vbellur@redhat.com&gt;
Tested-by: Vijay Bellur &lt;vbellur@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Till we separated the scenario of a file/directory not existing from
parent not existing [1], we used to include a subvolume in the layout
of a directory even if it is not present on that subvolume. This was
done to allow a lookup racing with mkdir to create correct layout.
However, there are other scenarios as well where a directory is not
present. One such situation is trying to create a directory after an
add-brick. Since there is no guarantee that all the ancestors are
created after an add-brick (and hence directory cannot be created), the
newly added brick should not be part of the layout. However, we used to
consider newly added brick as part of layout (even before we do
fix-layout of all the ancestors) and this was the root cause of [2].
With [1], this issue got fixed and hence [2] got fixed too. However,
[1] is not complete in the sense we didn't modify rmdir codepath
appropriately. This patch fixes that gap.

[1] http://review.gluster.org/6322
[2] https://bugzilla.redhat.com/show_bug.cgi?id=1006809

Change-Id: I79ab96bb8abb6f3d90bb6e235a1c465e1be0fd19
BUG: 1032894
Signed-off-by: Raghavendra G &lt;rgowdapp@redhat.com&gt;
Reviewed-on: http://review.gluster.org/8142
Reviewed-by: Vijay Bellur &lt;vbellur@redhat.com&gt;
Tested-by: Vijay Bellur &lt;vbellur@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Cluster/DHT : Logging changes</title>
<updated>2014-06-19T05:59:57+00:00</updated>
<author>
<name>Nithya Balachandran</name>
<email>nbalacha@redhat.com</email>
</author>
<published>2014-06-18T05:36:21+00:00</published>
<link rel='alternate' type='text/html' href='http://git.gluster.org/cgit/glusterfs.git/commit/?id=f844e5019de872e0c138daa6257d1f6cac5a4aff'/>
<id>f844e5019de872e0c138daa6257d1f6cac5a4aff</id>
<content type='text'>
Removed trailing spaces from the code

Change-Id: I427c9a01b514824f903e301863c2c29071db6483
BUG: 1075611
Signed-off-by: Nithya Balachandran &lt;nbalacha@redhat.com&gt;
Reviewed-on: http://review.gluster.org/8096
Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
Reviewed-by: Vijay Bellur &lt;vbellur@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Removed trailing spaces from the code

Change-Id: I427c9a01b514824f903e301863c2c29071db6483
BUG: 1075611
Signed-off-by: Nithya Balachandran &lt;nbalacha@redhat.com&gt;
Reviewed-on: http://review.gluster.org/8096
Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
Reviewed-by: Vijay Bellur &lt;vbellur@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>features/quota: Make dht_statfs_cbk more fool proof from quota_deem_statfs</title>
<updated>2014-06-18T16:50:32+00:00</updated>
<author>
<name>Varun Shastry</name>
<email>vshastry@redhat.com</email>
</author>
<published>2013-12-26T10:00:49+00:00</published>
<link rel='alternate' type='text/html' href='http://git.gluster.org/cgit/glusterfs.git/commit/?id=b54764ba860c3baba4b441ae7fcf043ab7eb46db'/>
<id>b54764ba860c3baba4b441ae7fcf043ab7eb46db</id>
<content type='text'>
Problem:
The function depends on the fact that if quota-deem-statfs option is enabled,
all of the subvolumes send their xdata with quota-deem-statfs flag ON. But,
this may not be true in case of errors in some of the subvolumes.

There is a decision/policy made which assumes quota-deem-statfs to be ON if at
least ONE of the subvolumes sends the flag ON. By this, df reports quota
modified statfs values if *at least ONE* of the bricks sends the
quota-deem-statfs flag ON. This can be visualized with the below "Transition
Diagram/State Machine".

        Event: Each Quota deem statfs status from the individual bricks
        Action: Decision taken on the calculation of the statvfs received
        State: Whether quota deem statfs is ON or OFF (0: OFF, 1: ON)
        Input: Event from individual bricks

              ___                  ___
             /   \   OFF*         /   \  (OFF|ON)*
            |     |              |     |
             \   /        ON      \   /
        -----&gt; 0  ----------------&gt; 1

The below Transition Function depicts the relation between the statfs
calculation based on the events received.

         State          Event          action
        -------------------------------------
          OFF            OFF            OFF
          OFF            ON            REPLACE
          ON             OFF           NEGLECT
          ON             ON            COMPARE

Change-Id: I0e8fb7d3945a3ca3dde0bb99de6cd397e27a3162
BUG: 1048786
Signed-off-by: Varun Shastry &lt;vshastry@redhat.com&gt;
Reviewed-on: http://review.gluster.org/6652
Reviewed-by: Krishnan Parthasarathi &lt;kparthas@redhat.com&gt;
Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
Reviewed-by: Raghavendra G &lt;rgowdapp@redhat.com&gt;
Tested-by: Raghavendra G &lt;rgowdapp@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Problem:
The function depends on the fact that if quota-deem-statfs option is enabled,
all of the subvolumes send their xdata with quota-deem-statfs flag ON. But,
this may not be true in case of errors in some of the subvolumes.

There is a decision/policy made which assumes quota-deem-statfs to be ON if at
least ONE of the subvolumes sends the flag ON. By this, df reports quota
modified statfs values if *at least ONE* of the bricks sends the
quota-deem-statfs flag ON. This can be visualized with the below "Transition
Diagram/State Machine".

        Event: Each Quota deem statfs status from the individual bricks
        Action: Decision taken on the calculation of the statvfs received
        State: Whether quota deem statfs is ON or OFF (0: OFF, 1: ON)
        Input: Event from individual bricks

              ___                  ___
             /   \   OFF*         /   \  (OFF|ON)*
            |     |              |     |
             \   /        ON      \   /
        -----&gt; 0  ----------------&gt; 1

The below Transition Function depicts the relation between the statfs
calculation based on the events received.

         State          Event          action
        -------------------------------------
          OFF            OFF            OFF
          OFF            ON            REPLACE
          ON             OFF           NEGLECT
          ON             ON            COMPARE

Change-Id: I0e8fb7d3945a3ca3dde0bb99de6cd397e27a3162
BUG: 1048786
Signed-off-by: Varun Shastry &lt;vshastry@redhat.com&gt;
Reviewed-on: http://review.gluster.org/6652
Reviewed-by: Krishnan Parthasarathi &lt;kparthas@redhat.com&gt;
Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
Reviewed-by: Raghavendra G &lt;rgowdapp@redhat.com&gt;
Tested-by: Raghavendra G &lt;rgowdapp@redhat.com&gt;
</pre>
</div>
</content>
</entry>
</feed>
