<feed xmlns='http://www.w3.org/2005/Atom'>
<title>glusterfs.git/xlators/cluster/ec/src/ec-dir-read.c, branch v3.7.13</title>
<subtitle></subtitle>
<link rel='alternate' type='text/html' href='http://git.gluster.org/cgit/glusterfs.git/'/>
<entry>
<title>cluster/ec: Allow read fops to be processed in parallel</title>
<updated>2015-11-25T03:03:17+00:00</updated>
<author>
<name>Xavier Hernandez</name>
<email>xhernandez@datalab.es</email>
</author>
<published>2015-07-22T15:08:02+00:00</published>
<link rel='alternate' type='text/html' href='http://git.gluster.org/cgit/glusterfs.git/commit/?id=69e74432ee1ab29ba7caf483450997a95920b729'/>
<id>69e74432ee1ab29ba7caf483450997a95920b729</id>
<content type='text'>
Currently ec only sends a single read request at a time for a given
inode. Since reads do not interfere between them, this patch allows
multiple concurrent read requests to be sent in parallel.

This is a backport of these patches:

&gt; Change-Id: If853430482a71767823f39ea70ff89797019d46b
&gt; BUG: 1245689
&gt; Signed-off-by: Xavier Hernandez &lt;xhernandez@datalab.es&gt;
&gt; Reviewed-on: http://review.gluster.org/11742
&gt; Tested-by: NetBSD Build System &lt;jenkins@build.gluster.org&gt;
&gt; Reviewed-by: Pranith Kumar Karampuri &lt;pkarampu@redhat.com&gt;
&gt; Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
&gt;
&gt; Change-Id: I6042129f09082497b80782b5704a52c35c78f44d
&gt; BUG: 1276031
&gt; Signed-off-by: Xavier Hernandez &lt;xhernandez@datalab.es&gt;

Change-Id: I1b1146d1fd1828b12bfc566cd76e5ea110f8909b
BUG: 1251467
Signed-off-by: Xavier Hernandez &lt;xhernandez@datalab.es&gt;
Reviewed-on: http://review.gluster.org/12447
Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
Tested-by: NetBSD Build System &lt;jenkins@build.gluster.org&gt;
Reviewed-by: Pranith Kumar Karampuri &lt;pkarampu@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Currently ec only sends a single read request at a time for a given
inode. Since reads do not interfere between them, this patch allows
multiple concurrent read requests to be sent in parallel.

This is a backport of these patches:

&gt; Change-Id: If853430482a71767823f39ea70ff89797019d46b
&gt; BUG: 1245689
&gt; Signed-off-by: Xavier Hernandez &lt;xhernandez@datalab.es&gt;
&gt; Reviewed-on: http://review.gluster.org/11742
&gt; Tested-by: NetBSD Build System &lt;jenkins@build.gluster.org&gt;
&gt; Reviewed-by: Pranith Kumar Karampuri &lt;pkarampu@redhat.com&gt;
&gt; Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
&gt;
&gt; Change-Id: I6042129f09082497b80782b5704a52c35c78f44d
&gt; BUG: 1276031
&gt; Signed-off-by: Xavier Hernandez &lt;xhernandez@datalab.es&gt;

Change-Id: I1b1146d1fd1828b12bfc566cd76e5ea110f8909b
BUG: 1251467
Signed-off-by: Xavier Hernandez &lt;xhernandez@datalab.es&gt;
Reviewed-on: http://review.gluster.org/12447
Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
Tested-by: NetBSD Build System &lt;jenkins@build.gluster.org&gt;
Reviewed-by: Pranith Kumar Karampuri &lt;pkarampu@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>cluster/ec: Fix tracking of good bricks</title>
<updated>2015-08-14T09:02:21+00:00</updated>
<author>
<name>Xavier Hernandez</name>
<email>xhernandez@datalab.es</email>
</author>
<published>2015-08-05T21:42:41+00:00</published>
<link rel='alternate' type='text/html' href='http://git.gluster.org/cgit/glusterfs.git/commit/?id=cfac0a9c78ead389ec261010a1c094bc60ca2810'/>
<id>cfac0a9c78ead389ec261010a1c094bc60ca2810</id>
<content type='text'>
The bitmask of good and bad bricks was kept in the context of the
corresponding inode or fd. This was problematic when an external
process (another client or the self-heal process) did heal the
bricks but no one changed the bitmaks of other clients.

This patch removes the bitmask stored in the context and calculates
which bricks are healthy after locking them and doing the initial
xattrop. After that, it's updated using the result of each fop.

&gt; Change-Id: I225e31cd219a12af4ca58871d8a4bb6f742b223c
&gt; BUG: 1236065
&gt; Signed-off-by: Xavier Hernandez &lt;xhernandez@datalab.es&gt;
&gt; Reviewed-on: http://review.gluster.org/11844
&gt; Tested-by: NetBSD Build System &lt;jenkins@build.gluster.org&gt;
&gt; Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
&gt; Reviewed-by: Pranith Kumar Karampuri &lt;pkarampu@redhat.com&gt;

Change-Id: Idbe68b28b865c4b28366703ad1e96ae16ba44b66
BUG: 1235964
Signed-off-by: Xavier Hernandez &lt;xhernandez@datalab.es&gt;
Reviewed-on: http://review.gluster.org/11867
Tested-by: NetBSD Build System &lt;jenkins@build.gluster.org&gt;
Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
Reviewed-by: Pranith Kumar Karampuri &lt;pkarampu@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The bitmask of good and bad bricks was kept in the context of the
corresponding inode or fd. This was problematic when an external
process (another client or the self-heal process) did heal the
bricks but no one changed the bitmaks of other clients.

This patch removes the bitmask stored in the context and calculates
which bricks are healthy after locking them and doing the initial
xattrop. After that, it's updated using the result of each fop.

&gt; Change-Id: I225e31cd219a12af4ca58871d8a4bb6f742b223c
&gt; BUG: 1236065
&gt; Signed-off-by: Xavier Hernandez &lt;xhernandez@datalab.es&gt;
&gt; Reviewed-on: http://review.gluster.org/11844
&gt; Tested-by: NetBSD Build System &lt;jenkins@build.gluster.org&gt;
&gt; Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
&gt; Reviewed-by: Pranith Kumar Karampuri &lt;pkarampu@redhat.com&gt;

Change-Id: Idbe68b28b865c4b28366703ad1e96ae16ba44b66
BUG: 1235964
Signed-off-by: Xavier Hernandez &lt;xhernandez@datalab.es&gt;
Reviewed-on: http://review.gluster.org/11867
Tested-by: NetBSD Build System &lt;jenkins@build.gluster.org&gt;
Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
Reviewed-by: Pranith Kumar Karampuri &lt;pkarampu@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>cluster/ec: Minimize usage of EIO error</title>
<updated>2015-08-08T15:36:57+00:00</updated>
<author>
<name>Xavier Hernandez</name>
<email>xhernandez@datalab.es</email>
</author>
<published>2015-07-21T16:05:06+00:00</published>
<link rel='alternate' type='text/html' href='http://git.gluster.org/cgit/glusterfs.git/commit/?id=0e0c3ec84c73bc5fcda16ed743f9d3dc0a582c03'/>
<id>0e0c3ec84c73bc5fcda16ed743f9d3dc0a582c03</id>
<content type='text'>
&gt;Change-Id: I82e245615419c2006a2d1b5e94ff0908d2f5e891
&gt;BUG: 1245276
&gt;Signed-off-by: Xavier Hernandez &lt;xhernandez@datalab.es&gt;
&gt;Reviewed-on: http://review.gluster.org/11741
&gt;Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
&gt;Reviewed-by: Pranith Kumar Karampuri &lt;pkarampu@redhat.com&gt;
&gt;Tested-by: NetBSD Build System &lt;jenkins@build.gluster.org&gt;

Change-Id: Ifd3d63f88a686a2963c5ba2e62110249f84f338d
BUG: 1250864
Signed-off-by: Xavier Hernandez &lt;xhernandez@datalab.es&gt;
Reviewed-on: http://review.gluster.org/11852
Reviewed-by: Pranith Kumar Karampuri &lt;pkarampu@redhat.com&gt;
Tested-by: NetBSD Build System &lt;jenkins@build.gluster.org&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>
&gt;Change-Id: I82e245615419c2006a2d1b5e94ff0908d2f5e891
&gt;BUG: 1245276
&gt;Signed-off-by: Xavier Hernandez &lt;xhernandez@datalab.es&gt;
&gt;Reviewed-on: http://review.gluster.org/11741
&gt;Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
&gt;Reviewed-by: Pranith Kumar Karampuri &lt;pkarampu@redhat.com&gt;
&gt;Tested-by: NetBSD Build System &lt;jenkins@build.gluster.org&gt;

Change-Id: Ifd3d63f88a686a2963c5ba2e62110249f84f338d
BUG: 1250864
Signed-off-by: Xavier Hernandez &lt;xhernandez@datalab.es&gt;
Reviewed-on: http://review.gluster.org/11852
Reviewed-by: Pranith Kumar Karampuri &lt;pkarampu@redhat.com&gt;
Tested-by: NetBSD Build System &lt;jenkins@build.gluster.org&gt;
Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>cluster/ec: wind readlink on good subvol(s)</title>
<updated>2015-07-22T06:27:12+00:00</updated>
<author>
<name>Pranith Kumar K</name>
<email>pkarampu@redhat.com</email>
</author>
<published>2015-07-01T08:55:07+00:00</published>
<link rel='alternate' type='text/html' href='http://git.gluster.org/cgit/glusterfs.git/commit/?id=69e15a1d7ff40188872f87af8e8c80f4e891746a'/>
<id>69e15a1d7ff40188872f87af8e8c80f4e891746a</id>
<content type='text'>
 &gt;BUG: 1232172
 &gt;Change-Id: I3a56e487840d86147dd85bf5fbe79b165eae289f
 &gt;Signed-off-by: Pranith Kumar K &lt;pkarampu@redhat.com&gt;
 &gt;Reviewed-on: http://review.gluster.org/11589
 &gt;Tested-by: NetBSD Build System &lt;jenkins@build.gluster.org&gt;
 &gt;Reviewed-by: Xavier Hernandez &lt;xhernandez@datalab.es&gt;
 &gt;Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;

BUG: 1234679
Change-Id: I08560eee095a3921e9c24f16dc2a242a76018a42
Signed-off-by: Pranith Kumar K &lt;pkarampu@redhat.com&gt;
Reviewed-on: http://review.gluster.org/11687
Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
Reviewed-by: Xavier Hernandez &lt;xhernandez@datalab.es&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
 &gt;BUG: 1232172
 &gt;Change-Id: I3a56e487840d86147dd85bf5fbe79b165eae289f
 &gt;Signed-off-by: Pranith Kumar K &lt;pkarampu@redhat.com&gt;
 &gt;Reviewed-on: http://review.gluster.org/11589
 &gt;Tested-by: NetBSD Build System &lt;jenkins@build.gluster.org&gt;
 &gt;Reviewed-by: Xavier Hernandez &lt;xhernandez@datalab.es&gt;
 &gt;Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;

BUG: 1234679
Change-Id: I08560eee095a3921e9c24f16dc2a242a76018a42
Signed-off-by: Pranith Kumar K &lt;pkarampu@redhat.com&gt;
Reviewed-on: http://review.gluster.org/11687
Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
Reviewed-by: Xavier Hernandez &lt;xhernandez@datalab.es&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>cluster/ec: Remove locks in opendir</title>
<updated>2015-07-21T21:43:40+00:00</updated>
<author>
<name>Pranith Kumar K</name>
<email>pkarampu@redhat.com</email>
</author>
<published>2015-07-02T03:56:44+00:00</published>
<link rel='alternate' type='text/html' href='http://git.gluster.org/cgit/glusterfs.git/commit/?id=53aa618c55a6a8e3e6eff78bea6399f079da35a6'/>
<id>53aa618c55a6a8e3e6eff78bea6399f079da35a6</id>
<content type='text'>
With readdir[p] taking locks to figure out which bricks are
good/bad, no need to take any locks on opendir.

 &gt;BUG: 1232172
 &gt;Change-Id: I4d924aeeaecab23af08c4598548a20d2a44cd849
 &gt;Signed-off-by: Pranith Kumar K &lt;pkarampu@redhat.com&gt;
 &gt;Reviewed-on: http://review.gluster.org/11506
 &gt;Reviewed-by: Xavier Hernandez &lt;xhernandez@datalab.es&gt;
 &gt;Tested-by: NetBSD Build System &lt;jenkins@build.gluster.org&gt;
 &gt;Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;

BUG: 1234679
Change-Id: Ibada9c196fb44a38400ef027f0a3a142d32797a6
Signed-off-by: Pranith Kumar K &lt;pkarampu@redhat.com&gt;
Reviewed-on: http://review.gluster.org/11684
Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
Reviewed-by: Xavier Hernandez &lt;xhernandez@datalab.es&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
With readdir[p] taking locks to figure out which bricks are
good/bad, no need to take any locks on opendir.

 &gt;BUG: 1232172
 &gt;Change-Id: I4d924aeeaecab23af08c4598548a20d2a44cd849
 &gt;Signed-off-by: Pranith Kumar K &lt;pkarampu@redhat.com&gt;
 &gt;Reviewed-on: http://review.gluster.org/11506
 &gt;Reviewed-by: Xavier Hernandez &lt;xhernandez@datalab.es&gt;
 &gt;Tested-by: NetBSD Build System &lt;jenkins@build.gluster.org&gt;
 &gt;Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;

BUG: 1234679
Change-Id: Ibada9c196fb44a38400ef027f0a3a142d32797a6
Signed-off-by: Pranith Kumar K &lt;pkarampu@redhat.com&gt;
Reviewed-on: http://review.gluster.org/11684
Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
Reviewed-by: Xavier Hernandez &lt;xhernandez@datalab.es&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>cluster/ec: wind fops on good subvols for access/readdir[p]</title>
<updated>2015-07-02T06:42:17+00:00</updated>
<author>
<name>Pranith Kumar K</name>
<email>pkarampu@redhat.com</email>
</author>
<published>2015-06-15T11:02:06+00:00</published>
<link rel='alternate' type='text/html' href='http://git.gluster.org/cgit/glusterfs.git/commit/?id=ab74e66f1724d5ca8cfe15bd4d91a3b7da1c62bd'/>
<id>ab74e66f1724d5ca8cfe15bd4d91a3b7da1c62bd</id>
<content type='text'>
        Backport of http://review.gluster.com/11246

BUG: 1234679
Change-Id: I2d774f62740c82e922efab50fc78fa74050ede93
Signed-off-by: Pranith Kumar K &lt;pkarampu@redhat.com&gt;
Reviewed-on: http://review.gluster.org/11357
Tested-by: NetBSD Build System &lt;jenkins@build.gluster.org&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>
        Backport of http://review.gluster.com/11246

BUG: 1234679
Change-Id: I2d774f62740c82e922efab50fc78fa74050ede93
Signed-off-by: Pranith Kumar K &lt;pkarampu@redhat.com&gt;
Reviewed-on: http://review.gluster.org/11357
Tested-by: NetBSD Build System &lt;jenkins@build.gluster.org&gt;
Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>ec: Porting messages to new logging framework</title>
<updated>2015-06-27T09:19:38+00:00</updated>
<author>
<name>Nandaja Varma</name>
<email>nandaja.varma@gmail.com</email>
</author>
<published>2015-04-30T08:58:10+00:00</published>
<link rel='alternate' type='text/html' href='http://git.gluster.org/cgit/glusterfs.git/commit/?id=cb578de65bd7e03882dd4f48fe65b29935a426e0'/>
<id>cb578de65bd7e03882dd4f48fe65b29935a426e0</id>
<content type='text'>
This is a backport of http://review.gluster.org/#/c/10465/

cherry-picked from commit b0b9eaea9dbb4e9a535f5e969defc4556a9e2204
&gt;Change-Id: Ia05ae750a245a37d48978e5f37b52f4fb0507a8c
&gt;BUG: 1194640
&gt;Signed-off-by: Nandaja Varma &lt;nandaja.varma@gmail.com&gt;

Change-Id: Ia05ae750a245a37d48978e5f37b52f4fb0507a8c
BUG: 1217722
Signed-off-by: Nandaja Varma &lt;nandaja.varma@gmail.com&gt;
Reviewed-on: http://review.gluster.org/11429
Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
Tested-by: NetBSD Build System &lt;jenkins@build.gluster.org&gt;
Reviewed-by: Pranith Kumar Karampuri &lt;pkarampu@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This is a backport of http://review.gluster.org/#/c/10465/

cherry-picked from commit b0b9eaea9dbb4e9a535f5e969defc4556a9e2204
&gt;Change-Id: Ia05ae750a245a37d48978e5f37b52f4fb0507a8c
&gt;BUG: 1194640
&gt;Signed-off-by: Nandaja Varma &lt;nandaja.varma@gmail.com&gt;

Change-Id: Ia05ae750a245a37d48978e5f37b52f4fb0507a8c
BUG: 1217722
Signed-off-by: Nandaja Varma &lt;nandaja.varma@gmail.com&gt;
Reviewed-on: http://review.gluster.org/11429
Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
Tested-by: NetBSD Build System &lt;jenkins@build.gluster.org&gt;
Reviewed-by: Pranith Kumar Karampuri &lt;pkarampu@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>cluster/ec: Prevent double unwind</title>
<updated>2015-06-18T12:47:15+00:00</updated>
<author>
<name>Pranith Kumar K</name>
<email>pkarampu@redhat.com</email>
</author>
<published>2015-06-07T04:54:08+00:00</published>
<link rel='alternate' type='text/html' href='http://git.gluster.org/cgit/glusterfs.git/commit/?id=56becf03ffd0ddfae4fda4d064a1c91cf1eb57a6'/>
<id>56becf03ffd0ddfae4fda4d064a1c91cf1eb57a6</id>
<content type='text'>
        Backport of http://review.gluster.com/11111

Problem:
1) ec_access/ec_readlink_/ec_readdir[p] _cbks are trying to recover only from
ENOTCONN.
2) When the fop succeeds it unwinds right away. But when its
ec_fop_manager resumes, if the number of bricks that are up is less than
ec-&gt;fragments, the the state machine will resume with -EC_STATE_REPORT which
unwinds again. This will lead to crashes.

Fix:
- If fop fails retry on other subvols, as ESTALE/ENOENT/EBADFD etc are also
recoverable.
- unwind success/failure in _cbks

BUG: 1229331
Change-Id: I7510984a237761efba65e872313a8ede8b7543e5
Signed-off-by: Pranith Kumar K &lt;pkarampu@redhat.com&gt;
Reviewed-on: http://review.gluster.org/11128
Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
Tested-by: NetBSD Build System &lt;jenkins@build.gluster.org&gt;
Reviewed-by: Xavier Hernandez &lt;xhernandez@datalab.es&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
        Backport of http://review.gluster.com/11111

Problem:
1) ec_access/ec_readlink_/ec_readdir[p] _cbks are trying to recover only from
ENOTCONN.
2) When the fop succeeds it unwinds right away. But when its
ec_fop_manager resumes, if the number of bricks that are up is less than
ec-&gt;fragments, the the state machine will resume with -EC_STATE_REPORT which
unwinds again. This will lead to crashes.

Fix:
- If fop fails retry on other subvols, as ESTALE/ENOENT/EBADFD etc are also
recoverable.
- unwind success/failure in _cbks

BUG: 1229331
Change-Id: I7510984a237761efba65e872313a8ede8b7543e5
Signed-off-by: Pranith Kumar K &lt;pkarampu@redhat.com&gt;
Reviewed-on: http://review.gluster.org/11128
Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
Tested-by: NetBSD Build System &lt;jenkins@build.gluster.org&gt;
Reviewed-by: Xavier Hernandez &lt;xhernandez@datalab.es&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>cluster/ec: Fix all EIO errors in EC</title>
<updated>2015-05-28T11:12:06+00:00</updated>
<author>
<name>Pranith Kumar K</name>
<email>pkarampu@redhat.com</email>
</author>
<published>2015-05-13T11:27:49+00:00</published>
<link rel='alternate' type='text/html' href='http://git.gluster.org/cgit/glusterfs.git/commit/?id=3a57ca8ee29ea8e3d3c5bbf28a56a821bfa99d99'/>
<id>3a57ca8ee29ea8e3d3c5bbf28a56a821bfa99d99</id>
<content type='text'>
        Backport of http://review.gluster.org/10770
        Backport of http://review.gluster.org/10806
        Backport of http://review.gluster.org/10787
        Backport of http://review.gluster.org/10868
        Backport of http://review.gluster.com/10852

 - When a blocking lock is requested, lock request is succeeded even when
ec-&gt;fragment number of locks are acquired successfully in non-blocking locking
phase. This will lead to fop succeeding only on the bricks where the locks are
acquired, leading to the necessity of self-heals. To prevent these un-necessary
self-heals, if the remaining locks fail with EAGAIN in non-blocking lock phase
try blocking locking phase instead.

 -  Handle lookup failures while op in progress

 - cluster/ec: Correctly cleanup delayed locks
When a delayed lock is pending, a graph switch doesn't correctly
terminate it. This means that the update of version and size xattrs
is lost, causing EIO errors. This patch handles GF_EVENT_PARENT_DOWN
event to correctly finish pending udpdates before completing the
graph switch.

 - Fix use after free crash
ec_heal creates ec_fop_data but doesn't run ec_manager. ec_fop_data_allocate
adds this fop to ec-&gt;pending_fops, because ec_manager is not run on this heal
fop it is never removed from ec-&gt;pending_fops. When it is accessed after free
it leads to crash. It is better to not to add HEAL fops to ec-&gt;pending_fops
because we don't want graph switch to hang the mount because of a BIG
file/directory heal.

- Forced unlock when lock contention is detected
EC uses an eager lock mechanism to optimize multiple read/write
requests on the same entry or inode. This increases performance
but can have adverse results when other clients try to access the
same entry/inode. To solve this, this patch adds a functionality
to detect when this happens and force an earlier release to not
block other clients.

The method consists on requesting GF_GLUSTERFS_INODELK_COUNT and
GF_GLUSTERFS_ENTRYLK_COUNT for all fops that take a lock. When this
count is greater than one, the lock is marked to be released. All
fops already waiting for this lock will be executed normally before
releasing the lock, but new requests that also require it will be
blocked and restarted after the lock has been released and reacquired
again.

Another problem was that some operations did correctly lock the
parent of an entry when needed, but got the size and version xattrs
from the entry instead of the parent.

This patch solves this problem by binding all queries of size and
version to each lock and replacing all entrylk calls by inodelk ones
to remove concurrent updates on directory metadata.  This also allows
rename to correctly update source and destination directories.

BUG: 1225279
Change-Id: I02a6084b138dd38e018a462347cd9ce38610c7ef
Reviewed-on: http://review.gluster.org/10926
Tested-by: NetBSD Build System
Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
Reviewed-by: Pranith Kumar Karampuri &lt;pkarampu@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
        Backport of http://review.gluster.org/10770
        Backport of http://review.gluster.org/10806
        Backport of http://review.gluster.org/10787
        Backport of http://review.gluster.org/10868
        Backport of http://review.gluster.com/10852

 - When a blocking lock is requested, lock request is succeeded even when
ec-&gt;fragment number of locks are acquired successfully in non-blocking locking
phase. This will lead to fop succeeding only on the bricks where the locks are
acquired, leading to the necessity of self-heals. To prevent these un-necessary
self-heals, if the remaining locks fail with EAGAIN in non-blocking lock phase
try blocking locking phase instead.

 -  Handle lookup failures while op in progress

 - cluster/ec: Correctly cleanup delayed locks
When a delayed lock is pending, a graph switch doesn't correctly
terminate it. This means that the update of version and size xattrs
is lost, causing EIO errors. This patch handles GF_EVENT_PARENT_DOWN
event to correctly finish pending udpdates before completing the
graph switch.

 - Fix use after free crash
ec_heal creates ec_fop_data but doesn't run ec_manager. ec_fop_data_allocate
adds this fop to ec-&gt;pending_fops, because ec_manager is not run on this heal
fop it is never removed from ec-&gt;pending_fops. When it is accessed after free
it leads to crash. It is better to not to add HEAL fops to ec-&gt;pending_fops
because we don't want graph switch to hang the mount because of a BIG
file/directory heal.

- Forced unlock when lock contention is detected
EC uses an eager lock mechanism to optimize multiple read/write
requests on the same entry or inode. This increases performance
but can have adverse results when other clients try to access the
same entry/inode. To solve this, this patch adds a functionality
to detect when this happens and force an earlier release to not
block other clients.

The method consists on requesting GF_GLUSTERFS_INODELK_COUNT and
GF_GLUSTERFS_ENTRYLK_COUNT for all fops that take a lock. When this
count is greater than one, the lock is marked to be released. All
fops already waiting for this lock will be executed normally before
releasing the lock, but new requests that also require it will be
blocked and restarted after the lock has been released and reacquired
again.

Another problem was that some operations did correctly lock the
parent of an entry when needed, but got the size and version xattrs
from the entry instead of the parent.

This patch solves this problem by binding all queries of size and
version to each lock and replacing all entrylk calls by inodelk ones
to remove concurrent updates on directory metadata.  This also allows
rename to correctly update source and destination directories.

BUG: 1225279
Change-Id: I02a6084b138dd38e018a462347cd9ce38610c7ef
Reviewed-on: http://review.gluster.org/10926
Tested-by: NetBSD Build System
Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
Reviewed-by: Pranith Kumar Karampuri &lt;pkarampu@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>cluster/ec: Fix readdir de-itransform</title>
<updated>2015-04-11T09:11:15+00:00</updated>
<author>
<name>Pranith Kumar K</name>
<email>pkarampu@redhat.com</email>
</author>
<published>2015-04-08T16:12:49+00:00</published>
<link rel='alternate' type='text/html' href='http://git.gluster.org/cgit/glusterfs.git/commit/?id=4797cb1c9dbf3910952f9d28d8272ff83cd25e7b'/>
<id>4797cb1c9dbf3910952f9d28d8272ff83cd25e7b</id>
<content type='text'>
Problem:
gf_deitransform returns the glbal client-id in the complete graph. So except
for the first disperse subvolume under dht, all the other disperse subvolumes
will return a client-id greater than ec-&gt;nodes, so readdir will always error
out in those subvolumes.

Fix:
Get the client subvolume whose client-id matches the client-id returned by
gf_deitransform of offset.

Change-Id: I26aa17504352d48d7ff14b390b62f49d7ab2d699
BUG: 1209113
Signed-off-by: Pranith Kumar K &lt;pkarampu@redhat.com&gt;
Reviewed-on: http://review.gluster.org/10165
Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
Reviewed-by: Xavier Hernandez &lt;xhernandez@datalab.es&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Problem:
gf_deitransform returns the glbal client-id in the complete graph. So except
for the first disperse subvolume under dht, all the other disperse subvolumes
will return a client-id greater than ec-&gt;nodes, so readdir will always error
out in those subvolumes.

Fix:
Get the client subvolume whose client-id matches the client-id returned by
gf_deitransform of offset.

Change-Id: I26aa17504352d48d7ff14b390b62f49d7ab2d699
BUG: 1209113
Signed-off-by: Pranith Kumar K &lt;pkarampu@redhat.com&gt;
Reviewed-on: http://review.gluster.org/10165
Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
Reviewed-by: Xavier Hernandez &lt;xhernandez@datalab.es&gt;
</pre>
</div>
</content>
</entry>
</feed>
