Commit Graph

25 Commits

Author SHA1 Message Date
Xiubo Li 5c24d91327 qa/tasks/cephfs: add mount_wait() support to simplify the code
Mostly we should wait the mountpoint to get ready, especially for
the fuse mountpoint, sometimes it may take a few seconds to get
ready.

Fixes: https://tracker.ceph.com/issues/44044
Signed-off-by: Xiubo Li <xiubli@redhat.com>
2020-04-14 07:47:04 -04:00
Xiubo Li eb2fe8440b qa/tasks/cephfs/test_client_recovery: switch to netns suspend/resume
Fixes: https://tracker.ceph.com/issues/44044
Signed-off-by: Xiubo Li <xiubli@redhat.com>
2020-04-14 07:47:03 -04:00
Kefu Chai 2089bf04b9 qa/tasks: use "a // b" instead of "a / b"
for expressions where the value is expected to be integer. as in
python3, `a / b` returns a float.

Signed-off-by: Kefu Chai <kchai@redhat.com>
2020-04-07 20:33:47 +08:00
Yan, Zheng 107b91d528 qa/cephfs: test case for auto reconnect after blacklisted
Signed-off-by: "Yan, Zheng" <zyan@redhat.com>
Fixes: https://tracker.ceph.com/issues/42085
2020-03-30 10:24:47 +08:00
Yan, Zheng 261a456439 qa/cephfs: test case for auto reconnect after blacklisted
Signed-off-by: "Yan, Zheng" <zyan@redhat.com>
Fixes: https://tracker.ceph.com/issues/42085
2020-01-15 15:43:17 +08:00
Thomas Bechtold bdcc94a1d1 qa: Run flake8 on python2 and python3
To be able to catch problems with python2 *and* python3, run flake8
with both versions. From the flake8 homepage:

It is very important to install Flake8 on the correct version of
Python for your needs. If you want Flake8 to properly parse new
language features in Python 3.5 (for example), you need it to be
installed on 3.5 for Flake8 to understand those features. In many
ways, Flake8 is tied to the version of Python on which it runs.

Also fix the problems with python3 on the way.
Note: This requires now the six module for teuthology. But this is
already an install_require in teuthology itself.

Signed-off-by: Thomas Bechtold <tbechtold@suse.com>
2019-12-13 09:24:20 +01:00
Thomas Bechtold 0127cd1e88 qa: Enable flake8 tox and fix failures
There were a couple of problems found by flake8 in the qa/
directory (most of them fixed now). Enabling flake8 during the usual
check runs hopefully avoids adding new issues in the future.

Signed-off-by: Thomas Bechtold <tbechtold@suse.com>
2019-12-12 10:21:01 +01:00
Venky Shankar dcbdc726a6 qa: allow client mount to reset fully
... without this there is a sutle race where it takes a
bit of time after a hard reset of a client mount causing
further checks to fail as the (still up) client is still
connected to the MDS.

Fixes: http://tracker.ceph.com/issues/42213
Signed-off-by: Venky Shankar <vshankar@redhat.com>
2019-10-21 08:38:37 -04:00
Kyr Shatskyy 7e87f80a87 tests: use python3 compatible print
Fixes: https://tracker.ceph.com/issues/42210
Signed-off-by: Kyr Shatskyy <kyrylo.shatskyy@suse.com>
2019-10-11 19:02:04 +02:00
Patrick Donnelly 9e106f1422
Merge PR #29104 into master
* refs/pull/29104/head:
	qa/cephfs: test case for timeout config of individual session
	mds: add command that config individual client session

Reviewed-by: Patrick Donnelly <pdonnell@redhat.com>
2019-07-31 12:06:39 -07:00
Patrick Donnelly 602e5f6eb4
qa: sleep briefly after resetting kclient
Continuation of 6b83f43ba0.

Fixes: https://tracker.ceph.com/issues/40999
Signed-off-by: Patrick Donnelly <pdonnell@redhat.com>
2019-07-29 14:08:17 -07:00
Yan, Zheng 4b28a4a756 qa/cephfs: test case for timeout config of individual session
Signed-off-by: "Yan, Zheng" <zyan@redhat.com>
2019-07-29 14:42:41 +08:00
Patrick Donnelly 6b83f43ba0
qa: wait for kernel client death
After sending the reboot command, we need to wait briefly for it to be
rebooted so that the kernel client doesn't voluntarily give up its Fb
cap.

Signed-off-by: Patrick Donnelly <pdonnell@redhat.com>
2019-07-26 15:34:17 -07:00
Rishabh Dave 80152465b5 qa/tests: test if unresponsive MDS client with no caps is evicted directly
Test if an unresponsive MDS client session holding no caps is evicted
directly at session_autoclose without being marked as stale at
session_timeout.

Signed-off-by: Rishabh Dave <ridave@redhat.com>
2019-07-20 09:04:50 +05:30
Yan, Zheng 1c8be588e3 qa/cephfs: update tests for stale session handling
Signed-off-by: "Yan, Zheng" <zyan@redhat.com>
2019-06-08 21:15:14 +08:00
Patrick Donnelly 1071f73c76
qa: use skipTest method instead of exception
This is the recommended method to skip a test according to [1]. It also lets us
avoid an unnecessary import.

[1] https://docs.python.org/2/library/unittest.html#unittest.TestCase.skipTest

Signed-off-by: Patrick Donnelly <pdonnell@redhat.com>
2019-04-24 09:38:52 -07:00
Yan, Zheng eb51786beb qa/tasks/cephfs: add test for ceph_abort_conn()
Signed-off-by: "Yan, Zheng" <zyan@redhat.com>
2018-06-28 16:16:50 +08:00
Yan, Zheng 5688476513 qa/tasks/cephfs: add test for renewing stale session
Signed-off-by: "Yan, Zheng" <zyan@redhat.com>
2018-05-03 10:50:28 +08:00
Rishabh Dave b14302d1fe qa/cephfs: test if evicted client unmounts without hanging
Signed-off-by: Rishabh Dave <ridave@redhat.com>
2018-04-30 12:02:56 +00:00
Patrick Donnelly 67ca6cd229
mds: obsolete MDSMap option configs
These configs were used for initialization but it is more appropriate to
require setting these file system attributes via `ceph fs set`. This is similar
to what was already done with max_mds. There are new variables added for `fs
set` where missing.

Signed-off-by: Patrick Donnelly <pdonnell@redhat.com>
2017-12-13 18:30:52 -08:00
Yan, Zheng 98d86a0752 qa/cephfs: kill mount if it gets evicted by mds
otherwise, teardown() hange at umount

Fixes: http://tracker.ceph.com/issues/21275
Signed-off-by: "Yan, Zheng" <zyan@redhat.com>
2017-09-13 21:30:51 +08:00
John Spray f80e0973f5 Merge pull request #15062 from ukernel/wip-19912
qa/tasks/cephfs: use getattr to guarantee inode is in client cache

Reviewed-by: John Spray <john.spray@redhat.com>
2017-05-25 18:44:54 +01:00
John Spray 47a9c9ba67 qa: add test_filelock_eviction
To check that eviction is releasing flocks.

Signed-off-by: John Spray <john.spray@redhat.com>
2017-05-23 05:22:17 -04:00
Yan, Zheng 1a48359f34 qa/tasks/cephfs: use getattr to guarantee inode is in client cache
When selinux is enabled, kernel client may releases inodes (without
uptodate xattr) in readdir reply immediately after processing the reply.
The reason is that linking the inode to dentry causes deadlock if xattr
is not uptodate.

We can use stat(2) syscall to guarantee that kernel client caches an
inode.

Fixes: http://tracker.ceph.com/issues/19912
Signed-off-by: "Yan, Zheng" <zyan@redhat.com>
2017-05-12 16:42:25 +08:00
Sage Weil c01f2ee0e2 move ceph-qa-suite dirs into qa/ 2016-12-14 11:29:55 -06:00