<feed xmlns='http://www.w3.org/2005/Atom'>
<title>glusterfs.git/xlators, branch master</title>
<subtitle>GlusterFS is a distributed file-system capable of scaling to several petabytes. It aggregates various storage bricks over Infiniband RDMA or TCP/IP interconnect into one large parallel network file system.</subtitle>
<link rel='alternate' type='text/html' href='https://fedorapeople.org/cgit/anoopcs/public_git/glusterfs.git/'/>
<entry>
<title>DHT - Removing commit hash and 'magical' return value from rebalance</title>
<updated>2020-10-07T04:38:50+00:00</updated>
<author>
<name>Barak Sason Rofman</name>
<email>bsasonro@redhat.com</email>
</author>
<published>2020-09-21T08:51:07+00:00</published>
<link rel='alternate' type='text/html' href='https://fedorapeople.org/cgit/anoopcs/public_git/glusterfs.git/commit/?id=c271c36ac9dbf47b365cc4e9de0e097fbbcc7945'/>
<id>c271c36ac9dbf47b365cc4e9de0e097fbbcc7945</id>
<content type='text'>
The order of operation in rebalance is as follows:
gf_defrag_fix_layout - &gt; gf_defrag_process_dir - &gt; gf_defrag_get_entry

gf_defrag_process_dir is passing to gf_defrag_get_entry a pointer to a
variable 'gf_defrag_get_entry', however this value is ignored (remains
unchanged in the method).
Based on the return value from gf_defrag_get_entry,
gf_defrag_process_dir may change it's return value to the 'magical'
number 2, however since the value of 'should_commit_hash' never changes,
this never happnes.
All of this is propagated back to gf_defrag_fix_layout and is now
removed from there as well.

Change-Id: Ibff297650cf84139bd26c830bfa44f81119b60d4
updates: #1002
Signed-off-by: Barak Sason Rofman &lt;bsasonro@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The order of operation in rebalance is as follows:
gf_defrag_fix_layout - &gt; gf_defrag_process_dir - &gt; gf_defrag_get_entry

gf_defrag_process_dir is passing to gf_defrag_get_entry a pointer to a
variable 'gf_defrag_get_entry', however this value is ignored (remains
unchanged in the method).
Based on the return value from gf_defrag_get_entry,
gf_defrag_process_dir may change it's return value to the 'magical'
number 2, however since the value of 'should_commit_hash' never changes,
this never happnes.
All of this is propagated back to gf_defrag_fix_layout and is now
removed from there as well.

Change-Id: Ibff297650cf84139bd26c830bfa44f81119b60d4
updates: #1002
Signed-off-by: Barak Sason Rofman &lt;bsasonro@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>mount/fuse: Fix graph-switch when reader-thread-count is set</title>
<updated>2020-10-05T11:27:28+00:00</updated>
<author>
<name>Pranith Kumar K</name>
<email>pranith.karampuri@phonepe.com</email>
</author>
<published>2020-10-05T07:45:07+00:00</published>
<link rel='alternate' type='text/html' href='https://fedorapeople.org/cgit/anoopcs/public_git/glusterfs.git/commit/?id=48a23965493e570827e51ec5018136ebe7897f3c'/>
<id>48a23965493e570827e51ec5018136ebe7897f3c</id>
<content type='text'>
Problem:
The current graph-switch code sets priv-&gt;handle_graph_switch to false even
when graph-switch is in progress which leads to crashes in some cases

Fix:
priv-&gt;handle_graph_switch should be set to false only when graph-switch
completes.

fixes: #1539
Change-Id: I5b04f7220a0a6e65c5f5afa3e28d1afe9efcdc31
Signed-off-by: Pranith Kumar K &lt;pranith.karampuri@phonepe.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Problem:
The current graph-switch code sets priv-&gt;handle_graph_switch to false even
when graph-switch is in progress which leads to crashes in some cases

Fix:
priv-&gt;handle_graph_switch should be set to false only when graph-switch
completes.

fixes: #1539
Change-Id: I5b04f7220a0a6e65c5f5afa3e28d1afe9efcdc31
Signed-off-by: Pranith Kumar K &lt;pranith.karampuri@phonepe.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>dht - Remove "tier" code (part 2)</title>
<updated>2020-10-01T14:50:15+00:00</updated>
<author>
<name>Barak Sason Rofman</name>
<email>bsasonro@redhat.com</email>
</author>
<published>2020-09-16T10:22:57+00:00</published>
<link rel='alternate' type='text/html' href='https://fedorapeople.org/cgit/anoopcs/public_git/glusterfs.git/commit/?id=d63b97c93a1d7d123f55e3652389af289ddd3096'/>
<id>d63b97c93a1d7d123f55e3652389af289ddd3096</id>
<content type='text'>
Part 1 of this patch https://review.gluster.org/#/c/glusterfs/+/24328/

Following part 1, this patch complety removes all traces of
"tier" feature in dht.

This is based in the work done in
https://review.gluster.org/#/c/glusterfs/+/23935/

Change-Id: I7fba1ab7249719301ca578b4a6f4acac748da145
updates: #1097
Signed-off-by: Barak Sason Rofman &lt;bsasonro@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Part 1 of this patch https://review.gluster.org/#/c/glusterfs/+/24328/

Following part 1, this patch complety removes all traces of
"tier" feature in dht.

This is based in the work done in
https://review.gluster.org/#/c/glusterfs/+/23935/

Change-Id: I7fba1ab7249719301ca578b4a6f4acac748da145
updates: #1097
Signed-off-by: Barak Sason Rofman &lt;bsasonro@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>fixed AFR_READ_POLICY_GFID_PID_HASH policy bug</title>
<updated>2020-10-01T13:52:12+00:00</updated>
<author>
<name>perrynzhou</name>
<email>perrynzhou@gmail.com</email>
</author>
<published>2020-09-29T09:22:42+00:00</published>
<link rel='alternate' type='text/html' href='https://fedorapeople.org/cgit/anoopcs/public_git/glusterfs.git/commit/?id=268faabed00995537394c04ac168c018167fbe27'/>
<id>268faabed00995537394c04ac168c018167fbe27</id>
<content type='text'>
Change-Id: Ib927a770a486c95e4b157e76ba96e9904d1a9716
Fixes: #1499
Signed-off-by: perrynzhou &lt;perrynzhou@gmail.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Change-Id: Ib927a770a486c95e4b157e76ba96e9904d1a9716
Fixes: #1499
Signed-off-by: perrynzhou &lt;perrynzhou@gmail.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>cluster/afr: Heal directory rename without rmdir/mkdir</title>
<updated>2020-10-01T12:03:25+00:00</updated>
<author>
<name>Pranith Kumar K</name>
<email>pkarampu@redhat.com</email>
</author>
<published>2020-04-13T14:01:51+00:00</published>
<link rel='alternate' type='text/html' href='https://fedorapeople.org/cgit/anoopcs/public_git/glusterfs.git/commit/?id=9ecbd69127d373ac000e9e1be00c1829e49e64a4'/>
<id>9ecbd69127d373ac000e9e1be00c1829e49e64a4</id>
<content type='text'>
Problem1:
When a directory is renamed while a brick
is down entry-heal always did an rm -rf on that directory on
the sink on old location and did mkdir and created the directory
hierarchy again in the new location. This is inefficient.

Problem2:
Renamedir heal order may lead to a scenario where directory in
the new location could be created before deleting it from old
location leading to 2 directories with same gfid in posix.

Fix:
As part of heal, if oldlocation is healed first and is not present in
source-brick always rename it into a hidden directory inside the
sink-brick so that when heal is triggered in new-location shd can
rename it from this hidden directory to the new-location.

If new-location heal is triggered first and it detects that the
directory already exists in the brick, then it should skip healing the
directory until it appears in the hidden directory.

Credits: Ravi for rename-data-loss.t script

Fixes: #1211
Change-Id: I0cba2006f35cd03d314d18211ce0bd530e254843
Signed-off-by: Pranith Kumar K &lt;pkarampu@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Problem1:
When a directory is renamed while a brick
is down entry-heal always did an rm -rf on that directory on
the sink on old location and did mkdir and created the directory
hierarchy again in the new location. This is inefficient.

Problem2:
Renamedir heal order may lead to a scenario where directory in
the new location could be created before deleting it from old
location leading to 2 directories with same gfid in posix.

Fix:
As part of heal, if oldlocation is healed first and is not present in
source-brick always rename it into a hidden directory inside the
sink-brick so that when heal is triggered in new-location shd can
rename it from this hidden directory to the new-location.

If new-location heal is triggered first and it detects that the
directory already exists in the brick, then it should skip healing the
directory until it appears in the hidden directory.

Credits: Ravi for rename-data-loss.t script

Fixes: #1211
Change-Id: I0cba2006f35cd03d314d18211ce0bd530e254843
Signed-off-by: Pranith Kumar K &lt;pkarampu@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>DHT - Fixing memory allocation crash</title>
<updated>2020-10-01T04:01:35+00:00</updated>
<author>
<name>Barak Sason Rofman</name>
<email>bsasonro@redhat.com</email>
</author>
<published>2020-09-24T13:46:46+00:00</published>
<link rel='alternate' type='text/html' href='https://fedorapeople.org/cgit/anoopcs/public_git/glusterfs.git/commit/?id=66deb99e745c47abf527bde41164fd4034e97035'/>
<id>66deb99e745c47abf527bde41164fd4034e97035</id>
<content type='text'>
The allocation
dir_dfmeta = GF_CALLOC(1, sizeof(*dir_dfmeta), gf_common_mt_pointer);
seems to cause a crash.
From the logs:
[2020-09-24 13:10:13.225935 +0000] I [dht-rebalance.c:3273:gf_defrag_process_dir]
 0-dist-dht: migrate data called on /dir1
[2020-09-24 13:10:13.226587 +0000] E [mem-pool.c:61:gf_mem_set_acct_info]
(--&gt;/usr/local/lib/glusterfs/9dev/xlator/cluster/distribute.so(+0x18e60)
[0x7f4b1f71ee60] --&gt;/usr/local/lib/glusterfs/9dev/xlator/cluster/distribute.so(+0x173ab)
[0x7f4b1f71d3ab] --&gt;/usr/local/lib/libglusterfs.so.0(+0x4d8e5) [0x7f4b357668e5] )
0-: Assertion failed: type &lt;= mem_acct-&gt;num_types
[2020-09-24 13:10:13.226623 +0000] E [mem-pool.c:61:gf_mem_set_acct_info]
(--&gt;/usr/local/lib/glusterfs/9dev/xlator/cluster/distribute.so(+0x18e60)
[0x7f4b1f71ee60] --&gt;/usr/local/lib/glusterfs/9dev/xlator/cluster/distribute.so(+0x173d3)
[0x7f4b1f71d3d3] --&gt;/usr/local/lib/libglusterfs.so.0(+0x4d8e5) [0x7f4b357668e5] )
0-: Assertion failed: type &lt;= mem_acct-&gt;num_types

The following change fixes that crash.

fixes: #1511
Change-Id: Ibf605648981f7108e863c91a80370cf077ad7c4a
Signed-off-by: Barak Sason Rofman &lt;bsasonro@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The allocation
dir_dfmeta = GF_CALLOC(1, sizeof(*dir_dfmeta), gf_common_mt_pointer);
seems to cause a crash.
From the logs:
[2020-09-24 13:10:13.225935 +0000] I [dht-rebalance.c:3273:gf_defrag_process_dir]
 0-dist-dht: migrate data called on /dir1
[2020-09-24 13:10:13.226587 +0000] E [mem-pool.c:61:gf_mem_set_acct_info]
(--&gt;/usr/local/lib/glusterfs/9dev/xlator/cluster/distribute.so(+0x18e60)
[0x7f4b1f71ee60] --&gt;/usr/local/lib/glusterfs/9dev/xlator/cluster/distribute.so(+0x173ab)
[0x7f4b1f71d3ab] --&gt;/usr/local/lib/libglusterfs.so.0(+0x4d8e5) [0x7f4b357668e5] )
0-: Assertion failed: type &lt;= mem_acct-&gt;num_types
[2020-09-24 13:10:13.226623 +0000] E [mem-pool.c:61:gf_mem_set_acct_info]
(--&gt;/usr/local/lib/glusterfs/9dev/xlator/cluster/distribute.so(+0x18e60)
[0x7f4b1f71ee60] --&gt;/usr/local/lib/glusterfs/9dev/xlator/cluster/distribute.so(+0x173d3)
[0x7f4b1f71d3d3] --&gt;/usr/local/lib/libglusterfs.so.0(+0x4d8e5) [0x7f4b357668e5] )
0-: Assertion failed: type &lt;= mem_acct-&gt;num_types

The following change fixes that crash.

fixes: #1511
Change-Id: Ibf605648981f7108e863c91a80370cf077ad7c4a
Signed-off-by: Barak Sason Rofman &lt;bsasonro@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>bitrot/stub: Fix memory leak gf_br_stub_mt_version_t</title>
<updated>2020-09-30T17:04:03+00:00</updated>
<author>
<name>Mohammed Rafi KC</name>
<email>rafi.kavungal@iternity.com</email>
</author>
<published>2020-08-31T19:19:26+00:00</published>
<link rel='alternate' type='text/html' href='https://fedorapeople.org/cgit/anoopcs/public_git/glusterfs.git/commit/?id=8489d42bde51455da0fedc531a5fe1df8a24a858'/>
<id>8489d42bde51455da0fedc531a5fe1df8a24a858</id>
<content type='text'>
The data type gf_br_stub_mt_version_t is leaking because the
data type has been added to the dict as static type and the memory
is not free'd from anywhere else

Change-Id: Ib10134f41f45a39be849af1708b1960c77fb62fd
Fixes: #1427
Signed-off-by: Mohammed Rafi KC &lt;rafi.kavungal@iternity.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The data type gf_br_stub_mt_version_t is leaking because the
data type has been added to the dict as static type and the memory
is not free'd from anywhere else

Change-Id: Ib10134f41f45a39be849af1708b1960c77fb62fd
Fixes: #1427
Signed-off-by: Mohammed Rafi KC &lt;rafi.kavungal@iternity.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>dht: explicit null dereference</title>
<updated>2020-09-29T14:32:09+00:00</updated>
<author>
<name>nik-redhat</name>
<email>nladha@redhat.com</email>
</author>
<published>2020-09-25T13:09:51+00:00</published>
<link rel='alternate' type='text/html' href='https://fedorapeople.org/cgit/anoopcs/public_git/glusterfs.git/commit/?id=773aaddc656a57b23bfae60808f099439329602c'/>
<id>773aaddc656a57b23bfae60808f099439329602c</id>
<content type='text'>
Added a null check for uuid_list_copy, to avoid
null dereference in strtok_r() in case of strdup()
failure.

CID: 1325612
CID: 1274223

Updates: #1060

Change-Id: I641a5068cd76d7b2ed92eccf39e7f97d6f7b2480
Signed-off-by: nik-redhat &lt;nladha@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Added a null check for uuid_list_copy, to avoid
null dereference in strtok_r() in case of strdup()
failure.

CID: 1325612
CID: 1274223

Updates: #1060

Change-Id: I641a5068cd76d7b2ed92eccf39e7f97d6f7b2480
Signed-off-by: nik-redhat &lt;nladha@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>locks: null dereference</title>
<updated>2020-09-29T14:04:11+00:00</updated>
<author>
<name>nik-redhat</name>
<email>nladha@redhat.com</email>
</author>
<published>2020-09-25T12:49:39+00:00</published>
<link rel='alternate' type='text/html' href='https://fedorapeople.org/cgit/anoopcs/public_git/glusterfs.git/commit/?id=748d7fe9cb7d20192b4b7d826509127fa04f43fb'/>
<id>748d7fe9cb7d20192b4b7d826509127fa04f43fb</id>
<content type='text'>
Added a null check before executing the strtok_r()
to avoid null dereference in case of strdup() failure.

CID: 1407938
Updates: #1060

Change-Id: Iec6e72ae8cb54f6d0a287615c43756325b2026ec
Signed-off-by: nik-redhat &lt;nladha@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Added a null check before executing the strtok_r()
to avoid null dereference in case of strdup() failure.

CID: 1407938
Updates: #1060

Change-Id: Iec6e72ae8cb54f6d0a287615c43756325b2026ec
Signed-off-by: nik-redhat &lt;nladha@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>glusterd: start the brick on a different port</title>
<updated>2020-09-29T13:15:21+00:00</updated>
<author>
<name>Sanju Rakonde</name>
<email>srakonde@redhat.com</email>
</author>
<published>2020-08-26T14:35:35+00:00</published>
<link rel='alternate' type='text/html' href='https://fedorapeople.org/cgit/anoopcs/public_git/glusterfs.git/commit/?id=a0effc34aff418d6ecd4760c77587f5da25ca8cf'/>
<id>a0effc34aff418d6ecd4760c77587f5da25ca8cf</id>
<content type='text'>
Problem: brick fails to start when the port provided by
glusterd is in use by any other process

Solution: glusterd should check errno set by runner_run()
and if it is set to EADDRINUSE, it should allocate a new
port to the brick and try to start it again.

Previously ret value is checked instead of errno, so the
retry part never executed. Now, we initialize errno to 0
before calling runner framework. and afterwards store the
errno into ret to avoid modification of errno in subsequent
function calls.

fixes: #1101

Change-Id: I1aa048a77c5f8b035dece36976d60602d9753b1a
Signed-off-by: Sanju Rakonde &lt;srakonde@redhat.com&gt;
Signed-off-by: nik-redhat &lt;nladha@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Problem: brick fails to start when the port provided by
glusterd is in use by any other process

Solution: glusterd should check errno set by runner_run()
and if it is set to EADDRINUSE, it should allocate a new
port to the brick and try to start it again.

Previously ret value is checked instead of errno, so the
retry part never executed. Now, we initialize errno to 0
before calling runner framework. and afterwards store the
errno into ret to avoid modification of errno in subsequent
function calls.

fixes: #1101

Change-Id: I1aa048a77c5f8b035dece36976d60602d9753b1a
Signed-off-by: Sanju Rakonde &lt;srakonde@redhat.com&gt;
Signed-off-by: nik-redhat &lt;nladha@redhat.com&gt;
</pre>
</div>
</content>
</entry>
</feed>
