<feed xmlns='http://www.w3.org/2005/Atom'>
<title>glusterfs.git/tests/bugs/quota/bug-1235182.t, branch v3.7.18</title>
<subtitle></subtitle>
<link rel='alternate' type='text/html' href='http://dev.gluster.org/cgit/glusterfs.git/'/>
<entry>
<title>tests: Backport all changes to tests dir</title>
<updated>2016-05-04T18:47:11+00:00</updated>
<author>
<name>Raghavendra Talur</name>
<email>rtalur@redhat.com</email>
</author>
<published>2016-03-10T12:31:33+00:00</published>
<link rel='alternate' type='text/html' href='http://dev.gluster.org/cgit/glusterfs.git/commit/?id=f02e03374f43ee541a711ff79fd5a4815e55eea5'/>
<id>f02e03374f43ee541a711ff79fd5a4815e55eea5</id>
<content type='text'>
Test framework should be the same on all the branches. This is a copy
of all the files under tests dir from master branch. New tests in
master have not been backported, but changes to existing tests have
been.

Change-Id: I75747c525aabbd9247473dd29b3a0e7a7d93c827
BUG: 1316533
Signed-off-by: Raghavendra Talur &lt;rtalur@redhat.com&gt;
Reviewed-on: http://review.gluster.org/13683
Smoke: Gluster Build System &lt;jenkins@build.gluster.com&gt;
NetBSD-regression: NetBSD Build System &lt;jenkins@build.gluster.org&gt;
CentOS-regression: Gluster Build System &lt;jenkins@build.gluster.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Test framework should be the same on all the branches. This is a copy
of all the files under tests dir from master branch. New tests in
master have not been backported, but changes to existing tests have
been.

Change-Id: I75747c525aabbd9247473dd29b3a0e7a7d93c827
BUG: 1316533
Signed-off-by: Raghavendra Talur &lt;rtalur@redhat.com&gt;
Reviewed-on: http://review.gluster.org/13683
Smoke: Gluster Build System &lt;jenkins@build.gluster.com&gt;
NetBSD-regression: NetBSD Build System &lt;jenkins@build.gluster.org&gt;
CentOS-regression: Gluster Build System &lt;jenkins@build.gluster.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>tests/quota : improving tests for quota</title>
<updated>2016-03-15T09:48:10+00:00</updated>
<author>
<name>Manikandan Selvaganesh</name>
<email>mselvaga@redhat.com</email>
</author>
<published>2016-01-12T11:28:57+00:00</published>
<link rel='alternate' type='text/html' href='http://dev.gluster.org/cgit/glusterfs.git/commit/?id=16a535753c4e5ef8b579d3758a5f709c19fb9592'/>
<id>16a535753c4e5ef8b579d3758a5f709c19fb9592</id>
<content type='text'>
tests/basic/quota.t includes all the basic test that
needs to be tested for quota. In most of the other
tests specific to bugs(tests/bugs/quota/*), tests
such as creating and starting volume, enabling quota,
setting limit, writing data, doing list have been done
which is essential to write a individual quota test
file, but, if the specific bug just needs to test
*few* particular cases, I have moved those tests
under tests/basic itself to speedup the regressions.

Basics of inode-quota and it's enforcing, renaming
with quota are basic tests and is hence moved under
tests/basic folder.

In other files, I have removed tests which are not
needed, such as 'pidof glusterd' or checking for
'gluster volume info' or if there are any test which
is already being tested under tests/basic and is being
written again.

        Backport of http://review.gluster.org/#/c/13216/

&gt; Change-Id: Iefd6d9529246d59829cc5bf02687a1861d8462a8
&gt; BUG: 1294826
&gt; Signed-off-by: Manikandan Selvaganesh &lt;mselvaga@redhat.com&gt;
&gt; Reviewed-on: http://review.gluster.org/13216
&gt; Smoke: Gluster Build System &lt;jenkins@build.gluster.com&gt;
&gt; NetBSD-regression: NetBSD Build System &lt;jenkins@build.gluster.org&gt;
&gt; CentOS-regression: Gluster Build System &lt;jenkins@build.gluster.com&gt;
&gt; Reviewed-by: Vijaikumar Mallikarjuna &lt;vmallika@redhat.com&gt;
&gt; Reviewed-by: Jeff Darcy &lt;jdarcy@redhat.com&gt;

Change-Id: Iefd6d9529246d59829cc5bf02687a1861d8462a8
BUG: 1314680
Signed-off-by: Manikandan Selvaganesh &lt;mselvaga@redhat.com&gt;
Reviewed-on: http://review.gluster.org/13606
Smoke: Gluster Build System &lt;jenkins@build.gluster.com&gt;
CentOS-regression: Gluster Build System &lt;jenkins@build.gluster.com&gt;
NetBSD-regression: NetBSD Build System &lt;jenkins@build.gluster.org&gt;
Reviewed-by: Vijaikumar Mallikarjuna &lt;vmallika@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
tests/basic/quota.t includes all the basic test that
needs to be tested for quota. In most of the other
tests specific to bugs(tests/bugs/quota/*), tests
such as creating and starting volume, enabling quota,
setting limit, writing data, doing list have been done
which is essential to write a individual quota test
file, but, if the specific bug just needs to test
*few* particular cases, I have moved those tests
under tests/basic itself to speedup the regressions.

Basics of inode-quota and it's enforcing, renaming
with quota are basic tests and is hence moved under
tests/basic folder.

In other files, I have removed tests which are not
needed, such as 'pidof glusterd' or checking for
'gluster volume info' or if there are any test which
is already being tested under tests/basic and is being
written again.

        Backport of http://review.gluster.org/#/c/13216/

&gt; Change-Id: Iefd6d9529246d59829cc5bf02687a1861d8462a8
&gt; BUG: 1294826
&gt; Signed-off-by: Manikandan Selvaganesh &lt;mselvaga@redhat.com&gt;
&gt; Reviewed-on: http://review.gluster.org/13216
&gt; Smoke: Gluster Build System &lt;jenkins@build.gluster.com&gt;
&gt; NetBSD-regression: NetBSD Build System &lt;jenkins@build.gluster.org&gt;
&gt; CentOS-regression: Gluster Build System &lt;jenkins@build.gluster.com&gt;
&gt; Reviewed-by: Vijaikumar Mallikarjuna &lt;vmallika@redhat.com&gt;
&gt; Reviewed-by: Jeff Darcy &lt;jdarcy@redhat.com&gt;

Change-Id: Iefd6d9529246d59829cc5bf02687a1861d8462a8
BUG: 1314680
Signed-off-by: Manikandan Selvaganesh &lt;mselvaga@redhat.com&gt;
Reviewed-on: http://review.gluster.org/13606
Smoke: Gluster Build System &lt;jenkins@build.gluster.com&gt;
CentOS-regression: Gluster Build System &lt;jenkins@build.gluster.com&gt;
NetBSD-regression: NetBSD Build System &lt;jenkins@build.gluster.org&gt;
Reviewed-by: Vijaikumar Mallikarjuna &lt;vmallika@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>quota/marker: fix inode quota with rename</title>
<updated>2015-08-21T05:45:35+00:00</updated>
<author>
<name>vmallika</name>
<email>vmallika@redhat.com</email>
</author>
<published>2015-07-12T03:19:49+00:00</published>
<link rel='alternate' type='text/html' href='http://dev.gluster.org/cgit/glusterfs.git/commit/?id=d6569f7bd93f4f7a27ce0a89281c63c0591b7871'/>
<id>d6569f7bd93f4f7a27ce0a89281c63c0591b7871</id>
<content type='text'>
This is a backport of http://review.gluster.org/11578

There are three problems with marker-rename which
is fixed in this patch

Problem 1)
1) mq_reduce_parent_size is not handling inode-quota contribution
2) When dest files exists and IO is happening
   Now renaming will overwrite existing file
   mq_reduce_parent_size called on dest file
   with saved contribution, this can be
   a problem is IO is still happening
   contribution might have changed

Problem 2)
There is a small race between rename and in-progress write
Consider below scenario
1) rename FOP invoked on file 'x'
2) write is still in progress for file 'x'
3) rename takes a lock on old-parent
4) write-update txn blocked on old-parent to acquire lock
5) in rename_cbk, contri xattrs are removed and contribution is deleted and
   lock is released
6) now write-update txn gets the lock and updates the wrong parent
   as it was holding lock on old parent
   so validate parent once the lock is acquired

Problem 3)
when a rename operation is performed, a lock is
held on old parent. This lock is release before
unwinding the rename operation.
This can be a problem if there are in-progress
writes happening during rename, where update txn
can take a lock and update the old parent
as inode table is not updated with new parent

&gt; Change-Id: Ic3316097c001c33533f98592e8fcf234b1ee2aa2
&gt; BUG: 1240991
&gt; Signed-off-by: vmallika &lt;vmallika@redhat.com&gt;
&gt; Reviewed-on: http://review.gluster.org/11578
&gt; Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
&gt; Tested-by: NetBSD Build System &lt;jenkins@build.gluster.org&gt;
&gt; Reviewed-by: Raghavendra G &lt;rgowdapp@redhat.com&gt;

Change-Id: Ie8e43c711a0e3dbe8494f0d64ab10c7b7a55e0d1
BUG: 1255244
Signed-off-by: vmallika &lt;vmallika@redhat.com&gt;
Reviewed-on: http://review.gluster.org/11961
Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
Tested-by: NetBSD Build System &lt;jenkins@build.gluster.org&gt;
Reviewed-by: Raghavendra G &lt;rgowdapp@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/11578

There are three problems with marker-rename which
is fixed in this patch

Problem 1)
1) mq_reduce_parent_size is not handling inode-quota contribution
2) When dest files exists and IO is happening
   Now renaming will overwrite existing file
   mq_reduce_parent_size called on dest file
   with saved contribution, this can be
   a problem is IO is still happening
   contribution might have changed

Problem 2)
There is a small race between rename and in-progress write
Consider below scenario
1) rename FOP invoked on file 'x'
2) write is still in progress for file 'x'
3) rename takes a lock on old-parent
4) write-update txn blocked on old-parent to acquire lock
5) in rename_cbk, contri xattrs are removed and contribution is deleted and
   lock is released
6) now write-update txn gets the lock and updates the wrong parent
   as it was holding lock on old parent
   so validate parent once the lock is acquired

Problem 3)
when a rename operation is performed, a lock is
held on old parent. This lock is release before
unwinding the rename operation.
This can be a problem if there are in-progress
writes happening during rename, where update txn
can take a lock and update the old parent
as inode table is not updated with new parent

&gt; Change-Id: Ic3316097c001c33533f98592e8fcf234b1ee2aa2
&gt; BUG: 1240991
&gt; Signed-off-by: vmallika &lt;vmallika@redhat.com&gt;
&gt; Reviewed-on: http://review.gluster.org/11578
&gt; Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
&gt; Tested-by: NetBSD Build System &lt;jenkins@build.gluster.org&gt;
&gt; Reviewed-by: Raghavendra G &lt;rgowdapp@redhat.com&gt;

Change-Id: Ie8e43c711a0e3dbe8494f0d64ab10c7b7a55e0d1
BUG: 1255244
Signed-off-by: vmallika &lt;vmallika@redhat.com&gt;
Reviewed-on: http://review.gluster.org/11961
Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
Tested-by: NetBSD Build System &lt;jenkins@build.gluster.org&gt;
Reviewed-by: Raghavendra G &lt;rgowdapp@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>quota: Fix crash in quota enforcer</title>
<updated>2015-07-21T10:20:18+00:00</updated>
<author>
<name>vmallika</name>
<email>vmallika@redhat.com</email>
</author>
<published>2015-07-07T11:26:12+00:00</published>
<link rel='alternate' type='text/html' href='http://dev.gluster.org/cgit/glusterfs.git/commit/?id=cb8f419fd8e36b6eb5a48db5694e475cb79553c9'/>
<id>cb8f419fd8e36b6eb5a48db5694e475cb79553c9</id>
<content type='text'>
This is a backport of http://review.gluster.org/11510

With multiple hardlinks check_quota_limit is invoked for each parent
each of this check_limit can invoke validation
this can cause frame-&gt;local to get corrupted during validation.

Testcase tests/bugs/quota/bug-1235182.t fails spuriously with
this problem

&gt; Change-Id: I53adc54b431fb5f43e67a94248102ddaf0d7978f
&gt; BUG: 1238747
&gt; Signed-off-by: vmallika &lt;vmallika@redhat.com&gt;
&gt; Reviewed-on: http://review.gluster.org/11510
&gt; Tested-by: NetBSD Build System &lt;jenkins@build.gluster.org&gt;
&gt; Reviewed-by: Raghavendra G &lt;rgowdapp@redhat.com&gt;

Change-Id: Ia7f57276db034e0fc6cd84dbf618ce0d4fae4321
BUG: 1242898
Signed-off-by: vmallika &lt;vmallika@redhat.com&gt;
Reviewed-on: http://review.gluster.org/11662
Tested-by: NetBSD Build System &lt;jenkins@build.gluster.org&gt;
Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
Reviewed-by: Raghavendra G &lt;rgowdapp@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/11510

With multiple hardlinks check_quota_limit is invoked for each parent
each of this check_limit can invoke validation
this can cause frame-&gt;local to get corrupted during validation.

Testcase tests/bugs/quota/bug-1235182.t fails spuriously with
this problem

&gt; Change-Id: I53adc54b431fb5f43e67a94248102ddaf0d7978f
&gt; BUG: 1238747
&gt; Signed-off-by: vmallika &lt;vmallika@redhat.com&gt;
&gt; Reviewed-on: http://review.gluster.org/11510
&gt; Tested-by: NetBSD Build System &lt;jenkins@build.gluster.org&gt;
&gt; Reviewed-by: Raghavendra G &lt;rgowdapp@redhat.com&gt;

Change-Id: Ia7f57276db034e0fc6cd84dbf618ce0d4fae4321
BUG: 1242898
Signed-off-by: vmallika &lt;vmallika@redhat.com&gt;
Reviewed-on: http://review.gluster.org/11662
Tested-by: NetBSD Build System &lt;jenkins@build.gluster.org&gt;
Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
Reviewed-by: Raghavendra G &lt;rgowdapp@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>features/quota : Fix spurious failure</title>
<updated>2015-07-14T04:02:21+00:00</updated>
<author>
<name>vmallika</name>
<email>vmallika@redhat.com</email>
</author>
<published>2015-07-13T08:25:26+00:00</published>
<link rel='alternate' type='text/html' href='http://dev.gluster.org/cgit/glusterfs.git/commit/?id=756c729593dfd2ef68102a732596d083278a11fa'/>
<id>756c729593dfd2ef68102a732596d083278a11fa</id>
<content type='text'>
This is a backport of http://review.gluster.org/#/c/11125/

Problem : Basically, in this test case a file is created
which exceeds the quota limit. Once the limit is reached
that file will be deleted. At the same moment we are
testing inode-quota. It can so happen that before the
marker updates the information related to deletion of
file, a new file creation operation comes and sees that
quota limit is still exceeded.

Solution : Inducing a check to see if marker updation
completed successfully.

Updated all the test case which has the similar
machanism and also moved the "usage" function
to a common place "volume.rc"

&gt; Change-Id: I36ddbc5ebbf1b74c9d326a0d1d5f3b32f20a906a
&gt; BUG: 1229297
&gt; Signed-off-by: Sachin Pandit &lt;spandit@redhat.com&gt;
&gt; Signed-off-by: vmallika &lt;vmallika@redhat.com&gt;
&gt; Reviewed-on: http://review.gluster.org/11125
&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: Krishnan Parthasarathi &lt;kparthas@redhat.com&gt;

Change-Id: Iccc36de2b3a1e1a068d1a8d5e98d413c3afa1bc7
BUG: 1242329
Signed-off-by: vmallika &lt;vmallika@redhat.com&gt;
Reviewed-on: http://review.gluster.org/11642
Tested-by: NetBSD Build System &lt;jenkins@build.gluster.org&gt;
Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
Reviewed-by: Krishnan Parthasarathi &lt;kparthas@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/11125/

Problem : Basically, in this test case a file is created
which exceeds the quota limit. Once the limit is reached
that file will be deleted. At the same moment we are
testing inode-quota. It can so happen that before the
marker updates the information related to deletion of
file, a new file creation operation comes and sees that
quota limit is still exceeded.

Solution : Inducing a check to see if marker updation
completed successfully.

Updated all the test case which has the similar
machanism and also moved the "usage" function
to a common place "volume.rc"

&gt; Change-Id: I36ddbc5ebbf1b74c9d326a0d1d5f3b32f20a906a
&gt; BUG: 1229297
&gt; Signed-off-by: Sachin Pandit &lt;spandit@redhat.com&gt;
&gt; Signed-off-by: vmallika &lt;vmallika@redhat.com&gt;
&gt; Reviewed-on: http://review.gluster.org/11125
&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: Krishnan Parthasarathi &lt;kparthas@redhat.com&gt;

Change-Id: Iccc36de2b3a1e1a068d1a8d5e98d413c3afa1bc7
BUG: 1242329
Signed-off-by: vmallika &lt;vmallika@redhat.com&gt;
Reviewed-on: http://review.gluster.org/11642
Tested-by: NetBSD Build System &lt;jenkins@build.gluster.org&gt;
Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
Reviewed-by: Krishnan Parthasarathi &lt;kparthas@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>quota: marker accounting goes bad with rename while writing a file</title>
<updated>2015-07-02T11:26:44+00:00</updated>
<author>
<name>vmallika</name>
<email>vmallika@redhat.com</email>
</author>
<published>2015-06-25T09:28:50+00:00</published>
<link rel='alternate' type='text/html' href='http://dev.gluster.org/cgit/glusterfs.git/commit/?id=2bf6e683e88517c1b2c6c8b13ab681bfdb0acacc'/>
<id>2bf6e683e88517c1b2c6c8b13ab681bfdb0acacc</id>
<content type='text'>
This is a backport of http://review.gluster.org/#/c/11403/

&gt; With below test-case, marker accounting becomes bad:
&gt; 1) Create a volume with 1 brick
&gt; 2) fuse mount
&gt; 3) on one terminal write some data
&gt;    dd if=/dev/zero of=f1 bs=1M count=500 oflag=sync
&gt; 4) on another terminal execute below rename operation while the write is
&gt; still in progress
&gt;     for i in {1..50}; do
&gt;         ii=`expr $i + 1`;
&gt;         mv f$i f$ii;
&gt;     done
&gt;
&gt; remove-xattr is already on while doing rename operation,
&gt; we should not be doing again in background when reducing the
&gt; parent size.
&gt;
&gt; Change-Id: I969a64bb559e2341315928b55b99203e9ddee3f2
&gt; BUG: 1235195
&gt; Signed-off-by: vmallika &lt;vmallika@redhat.com&gt;
&gt; Reviewed-on: http://review.gluster.org/11403
&gt; Tested-by: NetBSD Build System &lt;jenkins@build.gluster.org&gt;
&gt; Reviewed-by: Raghavendra G &lt;rgowdapp@redhat.com&gt;
&gt; Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
&gt; Tested-by: Raghavendra G &lt;rgowdapp@redhat.com&gt;

Change-Id: Ic37c7f7bd74093ee7e155b305834dbc1fdd24b10
BUG: 1235990
Signed-off-by: vmallika &lt;vmallika@redhat.com&gt;
Reviewed-on: http://review.gluster.org/11425
Tested-by: NetBSD Build System &lt;jenkins@build.gluster.org&gt;
Reviewed-by: Raghavendra G &lt;rgowdapp@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/11403/

&gt; With below test-case, marker accounting becomes bad:
&gt; 1) Create a volume with 1 brick
&gt; 2) fuse mount
&gt; 3) on one terminal write some data
&gt;    dd if=/dev/zero of=f1 bs=1M count=500 oflag=sync
&gt; 4) on another terminal execute below rename operation while the write is
&gt; still in progress
&gt;     for i in {1..50}; do
&gt;         ii=`expr $i + 1`;
&gt;         mv f$i f$ii;
&gt;     done
&gt;
&gt; remove-xattr is already on while doing rename operation,
&gt; we should not be doing again in background when reducing the
&gt; parent size.
&gt;
&gt; Change-Id: I969a64bb559e2341315928b55b99203e9ddee3f2
&gt; BUG: 1235195
&gt; Signed-off-by: vmallika &lt;vmallika@redhat.com&gt;
&gt; Reviewed-on: http://review.gluster.org/11403
&gt; Tested-by: NetBSD Build System &lt;jenkins@build.gluster.org&gt;
&gt; Reviewed-by: Raghavendra G &lt;rgowdapp@redhat.com&gt;
&gt; Tested-by: Gluster Build System &lt;jenkins@build.gluster.com&gt;
&gt; Tested-by: Raghavendra G &lt;rgowdapp@redhat.com&gt;

Change-Id: Ic37c7f7bd74093ee7e155b305834dbc1fdd24b10
BUG: 1235990
Signed-off-by: vmallika &lt;vmallika@redhat.com&gt;
Reviewed-on: http://review.gluster.org/11425
Tested-by: NetBSD Build System &lt;jenkins@build.gluster.org&gt;
Reviewed-by: Raghavendra G &lt;rgowdapp@redhat.com&gt;
</pre>
</div>
</content>
</entry>
</feed>
