mirror of
https://github.com/ceph/ceph
synced 2025-02-24 03:27:10 +00:00
test: selftest for cephfs-top
utility
Signed-off-by: Venky Shankar <vshankar@redhat.com>
This commit is contained in:
parent
d5062c60f6
commit
0329d9b884
@ -6,9 +6,11 @@ tasks:
|
||||
extra_packages:
|
||||
rpm:
|
||||
- python3-cephfs
|
||||
- cephfs-top
|
||||
deb:
|
||||
- python3-cephfs
|
||||
- cephfs-shell
|
||||
- cephfs-top
|
||||
# For kernel_untar_build workunit
|
||||
extra_system_packages:
|
||||
deb:
|
||||
|
0
qa/suites/fs/top/%
Normal file
0
qa/suites/fs/top/%
Normal file
1
qa/suites/fs/top/.qa
Symbolic link
1
qa/suites/fs/top/.qa
Symbolic link
@ -0,0 +1 @@
|
||||
../.qa
|
1
qa/suites/fs/top/begin.yaml
Symbolic link
1
qa/suites/fs/top/begin.yaml
Symbolic link
@ -0,0 +1 @@
|
||||
.qa/cephfs/begin.yaml
|
0
qa/suites/fs/top/cluster/+
Normal file
0
qa/suites/fs/top/cluster/+
Normal file
10
qa/suites/fs/top/cluster/1-node.yaml
Normal file
10
qa/suites/fs/top/cluster/1-node.yaml
Normal file
@ -0,0 +1,10 @@
|
||||
meta:
|
||||
- desc: 1 ceph cluster with 1 mon, 1 mgr, 3 osds, 1 mds
|
||||
roles:
|
||||
- - mon.a
|
||||
- mgr.x
|
||||
- mds.a
|
||||
- osd.0
|
||||
- osd.1
|
||||
- osd.2
|
||||
- client.0
|
1
qa/suites/fs/top/mount/.qa
Symbolic link
1
qa/suites/fs/top/mount/.qa
Symbolic link
@ -0,0 +1 @@
|
||||
../.qa
|
1
qa/suites/fs/top/mount/fuse.yaml
Symbolic link
1
qa/suites/fs/top/mount/fuse.yaml
Symbolic link
@ -0,0 +1 @@
|
||||
.qa/cephfs/mount/fuse.yaml
|
1
qa/suites/fs/top/objectstore/.qa
Symbolic link
1
qa/suites/fs/top/objectstore/.qa
Symbolic link
@ -0,0 +1 @@
|
||||
../.qa
|
1
qa/suites/fs/top/objectstore/bluestore-bitmap.yaml
Symbolic link
1
qa/suites/fs/top/objectstore/bluestore-bitmap.yaml
Symbolic link
@ -0,0 +1 @@
|
||||
.qa/objectstore/bluestore-bitmap.yaml
|
1
qa/suites/fs/top/overrides/.qa
Symbolic link
1
qa/suites/fs/top/overrides/.qa
Symbolic link
@ -0,0 +1 @@
|
||||
../.qa
|
1
qa/suites/fs/top/overrides/whitelist_health.yaml
Symbolic link
1
qa/suites/fs/top/overrides/whitelist_health.yaml
Symbolic link
@ -0,0 +1 @@
|
||||
./.qa/cephfs/overrides/whitelist_health.yaml
|
1
qa/suites/fs/top/supported-random-distros$
Symbolic link
1
qa/suites/fs/top/supported-random-distros$
Symbolic link
@ -0,0 +1 @@
|
||||
.qa/distros/supported-random-distro$
|
1
qa/suites/fs/top/tasks/.qa
Symbolic link
1
qa/suites/fs/top/tasks/.qa
Symbolic link
@ -0,0 +1 @@
|
||||
../.qa
|
4
qa/suites/fs/top/tasks/fstop.yaml
Normal file
4
qa/suites/fs/top/tasks/fstop.yaml
Normal file
@ -0,0 +1,4 @@
|
||||
tasks:
|
||||
- cephfs_test_runner:
|
||||
modules:
|
||||
- tasks.cephfs.test_fstop
|
27
qa/tasks/cephfs/test_fstop.py
Normal file
27
qa/tasks/cephfs/test_fstop.py
Normal file
@ -0,0 +1,27 @@
|
||||
import logging
|
||||
|
||||
from tasks.cephfs.cephfs_test_case import CephFSTestCase
|
||||
from teuthology.exceptions import CommandFailedError
|
||||
|
||||
log = logging.getLogger(__name__)
|
||||
|
||||
class TestFSTop(CephFSTestCase):
|
||||
def test_fstop_non_existent_cluster(self):
|
||||
self.mgr_cluster.mon_manager.raw_cluster_cmd("mgr", "module", "enable", "stats")
|
||||
try:
|
||||
self.mount_a.run_shell(['cephfs-top',
|
||||
'--cluster=hpec',
|
||||
'--id=admin',
|
||||
'--selftest'])
|
||||
except CommandFailedError:
|
||||
pass
|
||||
else:
|
||||
raise RuntimeError('expected cephfs-top command to fail.')
|
||||
self.mgr_cluster.mon_manager.raw_cluster_cmd("mgr", "module", "disable", "stats")
|
||||
|
||||
def test_fstop(self):
|
||||
self.mgr_cluster.mon_manager.raw_cluster_cmd("mgr", "module", "enable", "stats")
|
||||
self.mount_a.run_shell(['cephfs-top',
|
||||
'--id=admin',
|
||||
'--selftest'])
|
||||
self.mgr_cluster.mon_manager.raw_cluster_cmd("mgr", "module", "disable", "stats")
|
Loading…
Reference in New Issue
Block a user