<feed xmlns='http://www.w3.org/2005/Atom'>
<title>glusto-tests.git/tests/functional/snapshot, branch master</title>
<subtitle>[no description]</subtitle>
<link rel='alternate' type='text/html' href='http://dev.gluster.org/cgit/glusto-tests.git/'/>
<entry>
<title>[Testfix] Fix I/O logic to use distinct file names</title>
<updated>2020-07-31T10:49:07+00:00</updated>
<author>
<name>kshithijiyer</name>
<email>kshithij.ki@gmail.com</email>
</author>
<published>2020-07-31T07:03:31+00:00</published>
<link rel='alternate' type='text/html' href='http://dev.gluster.org/cgit/glusto-tests.git/commit/?id=73468c9eebfe9d89cfaf554c1b945e2ecfed9cb8'/>
<id>73468c9eebfe9d89cfaf554c1b945e2ecfed9cb8</id>
<content type='text'>
Problem:
Testcases test_mount_snap_delete and test_restore_online_vol
were failing in the latest runs with the below traceback
```
Traceback (most recent call last):
  File "/usr/share/glustolibs/io/scripts/file_dir_ops.py", line 1246, in &lt;module&gt;
    rc = args.func(args)
  File "/usr/share/glustolibs/io/scripts/file_dir_ops.py", line 374, in create_files
    base_file_name, file_types)
  File "/usr/share/glustolibs/io/scripts/file_dir_ops.py", line 341, in _create_files
    ret = pool.map(lambda file_tuple: _create_file(*file_tuple), files)
  File "/usr/lib64/python3.6/multiprocessing/pool.py", line 266, in map
    return self._map_async(func, iterable, mapstar, chunksize).get()
  File "/usr/lib64/python3.6/multiprocessing/pool.py", line 644, in get
    raise self._value
  File "/usr/lib64/python3.6/multiprocessing/pool.py", line 119, in worker
    result = (True, func(*args, **kwds))
  File "/usr/lib64/python3.6/multiprocessing/pool.py", line 44, in mapstar
    return list(map(*args))
  File "/usr/share/glustolibs/io/scripts/file_dir_ops.py", line 341, in &lt;lambda&gt;
    ret = pool.map(lambda file_tuple: _create_file(*file_tuple), files)
  File "/usr/share/glustolibs/io/scripts/file_dir_ops.py", line 270, in _create_file
    with open(file_abs_path, "w+") as new_file:
FileExistsError: [Errno 17] File exists: '/mnt/testvol_distributed_glusterfs/file1.txt'
```
This was because I/O logic was trying to create 2 files with the same
name from 2 clients.

Fix:
Modify logic to use counters to create files with different names.

Change-Id: I2896736d28f6bd17435f941088fd634347e3f4fd
Signed-off-by: kshithijiyer &lt;kshithij.ki@gmail.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Problem:
Testcases test_mount_snap_delete and test_restore_online_vol
were failing in the latest runs with the below traceback
```
Traceback (most recent call last):
  File "/usr/share/glustolibs/io/scripts/file_dir_ops.py", line 1246, in &lt;module&gt;
    rc = args.func(args)
  File "/usr/share/glustolibs/io/scripts/file_dir_ops.py", line 374, in create_files
    base_file_name, file_types)
  File "/usr/share/glustolibs/io/scripts/file_dir_ops.py", line 341, in _create_files
    ret = pool.map(lambda file_tuple: _create_file(*file_tuple), files)
  File "/usr/lib64/python3.6/multiprocessing/pool.py", line 266, in map
    return self._map_async(func, iterable, mapstar, chunksize).get()
  File "/usr/lib64/python3.6/multiprocessing/pool.py", line 644, in get
    raise self._value
  File "/usr/lib64/python3.6/multiprocessing/pool.py", line 119, in worker
    result = (True, func(*args, **kwds))
  File "/usr/lib64/python3.6/multiprocessing/pool.py", line 44, in mapstar
    return list(map(*args))
  File "/usr/share/glustolibs/io/scripts/file_dir_ops.py", line 341, in &lt;lambda&gt;
    ret = pool.map(lambda file_tuple: _create_file(*file_tuple), files)
  File "/usr/share/glustolibs/io/scripts/file_dir_ops.py", line 270, in _create_file
    with open(file_abs_path, "w+") as new_file:
FileExistsError: [Errno 17] File exists: '/mnt/testvol_distributed_glusterfs/file1.txt'
```
This was because I/O logic was trying to create 2 files with the same
name from 2 clients.

Fix:
Modify logic to use counters to create files with different names.

Change-Id: I2896736d28f6bd17435f941088fd634347e3f4fd
Signed-off-by: kshithijiyer &lt;kshithij.ki@gmail.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>[Test] Start/Stop of snapd deamon on the cloned volume</title>
<updated>2020-06-24T11:54:33+00:00</updated>
<author>
<name>srivickynesh</name>
<email>sselvan@redhat.com</email>
</author>
<published>2018-06-07T11:13:43+00:00</published>
<link rel='alternate' type='text/html' href='http://dev.gluster.org/cgit/glusto-tests.git/commit/?id=32db5f9e2dad354f56418feeb15808f2739612f8'/>
<id>32db5f9e2dad354f56418feeb15808f2739612f8</id>
<content type='text'>
Test Cases in this module tests the
USS functionality of snapshots snapd
on cloned volume and validated snapshots
are present inside .snaps directory by
terminating snapd on one by one nodes
and validating .snaps directory is still accessible.

Change-Id: I98d48268e7c5c5952a7f0f544960203d8634b7ac
Signed-off-by: Sri Vignesh &lt;sselvan@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Test Cases in this module tests the
USS functionality of snapshots snapd
on cloned volume and validated snapshots
are present inside .snaps directory by
terminating snapd on one by one nodes
and validating .snaps directory is still accessible.

Change-Id: I98d48268e7c5c5952a7f0f544960203d8634b7ac
Signed-off-by: Sri Vignesh &lt;sselvan@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>[TestFix] Remove hot and cold bricks list on regular volumes</title>
<updated>2020-06-24T09:00:20+00:00</updated>
<author>
<name>Bala Konda Reddy M</name>
<email>bala12352@gmail.com</email>
</author>
<published>2020-06-18T15:10:48+00:00</published>
<link rel='alternate' type='text/html' href='http://dev.gluster.org/cgit/glusto-tests.git/commit/?id=3f5e3553cebceb95e8d051e27f18a26f9c8f725d'/>
<id>3f5e3553cebceb95e8d051e27f18a26f9c8f725d</id>
<content type='text'>
For the non-tiered volume types, In few test cases while bringing
bricks offline, collecting both hot_tier_bricks and cold_tier_bricks
and it is not needed to collect hot and cold tier bricks.

Removing the hot and cold tiered bricks and collecting only bricks
of the particular volume as mentioned below.

Removing below section
```
bricks_to_bring_offline_dict = (select_bricks_to_bring_offline(
                self.mnode, self.volname))
bricks_to_bring_offline = list(filter(None, (
bricks_to_bring_offline_dict['hot_tier_bricks'] +
bricks_to_bring_offline_dict['cold_tier_bricks'] +
bricks_to_bring_offline_dict['volume_bricks'])))
```

Modifying as below for bringing bricks offline.
```
bricks_to_bring_offline = bricks_to_bring_offline_dict['volume_bricks']
```

Change-Id: Icb1dc4a79cf311b686d839f2c9390371e42142f7
Signed-off-by: Bala Konda Reddy M &lt;bala12352@gmail.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
For the non-tiered volume types, In few test cases while bringing
bricks offline, collecting both hot_tier_bricks and cold_tier_bricks
and it is not needed to collect hot and cold tier bricks.

Removing the hot and cold tiered bricks and collecting only bricks
of the particular volume as mentioned below.

Removing below section
```
bricks_to_bring_offline_dict = (select_bricks_to_bring_offline(
                self.mnode, self.volname))
bricks_to_bring_offline = list(filter(None, (
bricks_to_bring_offline_dict['hot_tier_bricks'] +
bricks_to_bring_offline_dict['cold_tier_bricks'] +
bricks_to_bring_offline_dict['volume_bricks'])))
```

Modifying as below for bringing bricks offline.
```
bricks_to_bring_offline = bricks_to_bring_offline_dict['volume_bricks']
```

Change-Id: Icb1dc4a79cf311b686d839f2c9390371e42142f7
Signed-off-by: Bala Konda Reddy M &lt;bala12352@gmail.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>[Testfix] Fix I/O of test_snap_delete_multiple</title>
<updated>2020-06-22T14:46:41+00:00</updated>
<author>
<name>kshithijiyer</name>
<email>kshithij.ki@gmail.com</email>
</author>
<published>2020-06-22T14:39:23+00:00</published>
<link rel='alternate' type='text/html' href='http://dev.gluster.org/cgit/glusto-tests.git/commit/?id=17bda60f4df608f93963a4e8e984cfe9a09851a2'/>
<id>17bda60f4df608f93963a4e8e984cfe9a09851a2</id>
<content type='text'>
Problem:
test_snap_delete_multiple fails on I/O validation across all automation
runs constantly with the below trace back:
Traceback (most recent call last):
  File "/usr/share/glustolibs/io/scripts/file_dir_ops.py", line 1246, in &lt;module&gt;
    rc = args.func(args)
  File "/usr/share/glustolibs/io/scripts/file_dir_ops.py", line 374, in create_files
    base_file_name, file_types)
  File "/usr/share/glustolibs/io/scripts/file_dir_ops.py", line 341, in _create_files
    ret = pool.map(lambda file_tuple: _create_file(*file_tuple), files)
  File "/usr/lib64/python2.7/multiprocessing/pool.py", line 250, in map
    return self.map_async(func, iterable, chunksize).get()
  File "/usr/lib64/python2.7/multiprocessing/pool.py", line 554, in get
    raise self._value
IOError: [Errno 17] File exists: '/mnt/testvol_distributed_glusterfs/testfile42.txt'

Fix:
Change the I/O to use --base-file-name parameter when running the I/O
scripts.

Change-Id: Ic5a8222f4fafeac4ac9aadc9c4d23327711ed9f0
Signed-off-by: kshithijiyer &lt;kshithij.ki@gmail.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Problem:
test_snap_delete_multiple fails on I/O validation across all automation
runs constantly with the below trace back:
Traceback (most recent call last):
  File "/usr/share/glustolibs/io/scripts/file_dir_ops.py", line 1246, in &lt;module&gt;
    rc = args.func(args)
  File "/usr/share/glustolibs/io/scripts/file_dir_ops.py", line 374, in create_files
    base_file_name, file_types)
  File "/usr/share/glustolibs/io/scripts/file_dir_ops.py", line 341, in _create_files
    ret = pool.map(lambda file_tuple: _create_file(*file_tuple), files)
  File "/usr/lib64/python2.7/multiprocessing/pool.py", line 250, in map
    return self.map_async(func, iterable, chunksize).get()
  File "/usr/lib64/python2.7/multiprocessing/pool.py", line 554, in get
    raise self._value
IOError: [Errno 17] File exists: '/mnt/testvol_distributed_glusterfs/testfile42.txt'

Fix:
Change the I/O to use --base-file-name parameter when running the I/O
scripts.

Change-Id: Ic5a8222f4fafeac4ac9aadc9c4d23327711ed9f0
Signed-off-by: kshithijiyer &lt;kshithij.ki@gmail.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>[Test] Validate USS after snapshot restore</title>
<updated>2020-05-18T12:22:49+00:00</updated>
<author>
<name>Vinayak Papnoi</name>
<email>vpapnoi@redhat.com</email>
</author>
<published>2018-06-22T09:48:50+00:00</published>
<link rel='alternate' type='text/html' href='http://dev.gluster.org/cgit/glusto-tests.git/commit/?id=f0b1fb7d37843550ad3ab464ebbf20e762227cb1'/>
<id>f0b1fb7d37843550ad3ab464ebbf20e762227cb1</id>
<content type='text'>
When a snapshot is restored, that snapshot gets removed.

USS makes use of a '.snaps' directory in the mount point
where all the activated snapshots can be listed.
So the restored snapshot should not be listed under the
'.snaps' directory regardless of it being activated or
deactivated.

Steps:
* Perform I/O on mounts
* Enable USS on volume
* Validate USS is enabled
* Create a snapshot
* Activate the snapshot
* Perform some more I/O
* Create another snapshot
* Activate the second
* Restore volume to the second snapshot
* From mount point validate under .snaps
  - first snapshot should be listed
  - second snapshot should not be listed

Change-Id: I5630d8aad6b4758d49e8d4f53497073c78a00a6b
Co-authored-by: Sunny Kumar &lt;sunkumar@redhat.com&gt;
Signed-off-by: Sunny Kumar &lt;sunkumar@redhat.com&gt;
Signed-off-by: Vinayak Papnoi &lt;vpapnoi@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
When a snapshot is restored, that snapshot gets removed.

USS makes use of a '.snaps' directory in the mount point
where all the activated snapshots can be listed.
So the restored snapshot should not be listed under the
'.snaps' directory regardless of it being activated or
deactivated.

Steps:
* Perform I/O on mounts
* Enable USS on volume
* Validate USS is enabled
* Create a snapshot
* Activate the snapshot
* Perform some more I/O
* Create another snapshot
* Activate the second
* Restore volume to the second snapshot
* From mount point validate under .snaps
  - first snapshot should be listed
  - second snapshot should not be listed

Change-Id: I5630d8aad6b4758d49e8d4f53497073c78a00a6b
Co-authored-by: Sunny Kumar &lt;sunkumar@redhat.com&gt;
Signed-off-by: Sunny Kumar &lt;sunkumar@redhat.com&gt;
Signed-off-by: Vinayak Papnoi &lt;vpapnoi@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>[Testfix] Move test from teardown class to teardown</title>
<updated>2020-05-15T13:47:51+00:00</updated>
<author>
<name>Sri Vignesh</name>
<email>sselvan@redhat.com</email>
</author>
<published>2020-05-12T07:28:26+00:00</published>
<link rel='alternate' type='text/html' href='http://dev.gluster.org/cgit/glusto-tests.git/commit/?id=736e31c5d1dc1106fa0cced36ea5f43b691c7689'/>
<id>736e31c5d1dc1106fa0cced36ea5f43b691c7689</id>
<content type='text'>
Move cases from teardown class to teardown in snapshot

Change-Id: I7b33fa2728665fad000a5ad881f6690d40913f22
Signed-off-by: Sri Vignesh &lt;sselvan@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Move cases from teardown class to teardown in snapshot

Change-Id: I7b33fa2728665fad000a5ad881f6690d40913f22
Signed-off-by: Sri Vignesh &lt;sselvan@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>[testfix] Add sleep in snapshot failures</title>
<updated>2020-03-12T10:14:02+00:00</updated>
<author>
<name>Sri Vignesh</name>
<email>sselvan@redhat.com</email>
</author>
<published>2020-03-05T06:04:44+00:00</published>
<link rel='alternate' type='text/html' href='http://dev.gluster.org/cgit/glusto-tests.git/commit/?id=730413b377895b04704048d1c03c3baccfb22fd2'/>
<id>730413b377895b04704048d1c03c3baccfb22fd2</id>
<content type='text'>
Add sleep in test_snap_delete_original_volume.py
after cloning a volume added sleep and then starting
the volume. Changed io to write in one mount point
otherwise seeing issues with validate io.
removed baseclass cleanup because original volume is
already cleaned up in testcase.

Change-Id: I7bf9686384e238e1afe8491013a3058865343eee
Signed-off-by: Sri Vignesh &lt;sselvan@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Add sleep in test_snap_delete_original_volume.py
after cloning a volume added sleep and then starting
the volume. Changed io to write in one mount point
otherwise seeing issues with validate io.
removed baseclass cleanup because original volume is
already cleaned up in testcase.

Change-Id: I7bf9686384e238e1afe8491013a3058865343eee
Signed-off-by: Sri Vignesh &lt;sselvan@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>[Testfix] Remove python version dependency(Part 5)</title>
<updated>2020-03-09T08:19:07+00:00</updated>
<author>
<name>kshithijiyer</name>
<email>kshithij.ki@gmail.com</email>
</author>
<published>2020-03-06T13:21:49+00:00</published>
<link rel='alternate' type='text/html' href='http://dev.gluster.org/cgit/glusto-tests.git/commit/?id=fea99a7f768b58edea4a6ce3198ce3899e4c2eea'/>
<id>fea99a7f768b58edea4a6ce3198ce3899e4c2eea</id>
<content type='text'>
Please refer to commit message of patch [1].

[1] https://review.gluster.org/#/c/glusto-tests/+/24140/

Change-Id: I5319ce497ca3359e0e7dbd9ece481bada1ee2205
Signed-off-by: kshithijiyer &lt;kshithij.ki@gmail.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Please refer to commit message of patch [1].

[1] https://review.gluster.org/#/c/glusto-tests/+/24140/

Change-Id: I5319ce497ca3359e0e7dbd9ece481bada1ee2205
Signed-off-by: kshithijiyer &lt;kshithij.ki@gmail.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>[testfix] Add steps to stabilize contents in snapshot - part2</title>
<updated>2020-02-18T05:47:13+00:00</updated>
<author>
<name>Sri Vignesh</name>
<email>sselvan@redhat.com</email>
</author>
<published>2020-01-30T14:29:18+00:00</published>
<link rel='alternate' type='text/html' href='http://dev.gluster.org/cgit/glusto-tests.git/commit/?id=458ae92da119b3b8d378bb6021190891b265368f'/>
<id>458ae92da119b3b8d378bb6021190891b265368f</id>
<content type='text'>
used library functions to wait for glusterd to start
and wait for peer to connect and made modifications in teardown part
to rectified statements to correct values

Change-Id: I40b4362ae1491acf75681c7623c16c53213bb1b9
Signed-off-by: Sri Vignesh &lt;sselvan@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
used library functions to wait for glusterd to start
and wait for peer to connect and made modifications in teardown part
to rectified statements to correct values

Change-Id: I40b4362ae1491acf75681c7623c16c53213bb1b9
Signed-off-by: Sri Vignesh &lt;sselvan@redhat.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>[testfix] Fix name used for snapshot creation</title>
<updated>2020-01-29T12:33:44+00:00</updated>
<author>
<name>Vinayak Papnoi</name>
<email>vpapnoi@redhat.com</email>
</author>
<published>2019-08-11T14:39:40+00:00</published>
<link rel='alternate' type='text/html' href='http://dev.gluster.org/cgit/glusto-tests.git/commit/?id=38d22aa6f80528db07d0d07c75883f3be3ee0007'/>
<id>38d22aa6f80528db07d0d07c75883f3be3ee0007</id>
<content type='text'>
There can be a case where due to a failed tearDown of a previous
test case, the snapshot creation might fail because of redundant
snapshot of the same name present.

This fix includes the changed snapshot names along with tearDown
for deleting the snapshots created in the test case
"test_snap_info_glusterd_restart.py".

Changing the names of the test case function to something
relevant to the test case.
Making use of the method "wait_for_glusterd_to_start" in places
where glusterd is restarted.

Change-Id: I6cb50dc84d306194b6bd363daf7ae0ebd6bb12ee
Signed-off-by: Vinayak Papnoi &lt;vpapnoi@redhat.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
There can be a case where due to a failed tearDown of a previous
test case, the snapshot creation might fail because of redundant
snapshot of the same name present.

This fix includes the changed snapshot names along with tearDown
for deleting the snapshots created in the test case
"test_snap_info_glusterd_restart.py".

Changing the names of the test case function to something
relevant to the test case.
Making use of the method "wait_for_glusterd_to_start" in places
where glusterd is restarted.

Change-Id: I6cb50dc84d306194b6bd363daf7ae0ebd6bb12ee
Signed-off-by: Vinayak Papnoi &lt;vpapnoi@redhat.com&gt;
</pre>
</div>
</content>
</entry>
</feed>
