Commit Graph

2322 Commits

Author SHA1 Message Date
Rishabh Dave
aad0cfcb49 qa/cephfs: set omit_sudo to False for wait_until_mounted() in...
fuse_mount.py. This isn't critical at all to vstart_runner.py runs but
this patch must dramatically reduce the time it takes in case the
command fails with "permission denied" due to lack of superuser
privileges since in this case the command is re-run 9 more times, each
separated by a sleep for 5 seconds.

Signed-off-by: Rishabh Dave <ridave@redhat.com>
2020-07-07 09:45:28 +05:30
Patrick Donnelly
bba0cb878a
Merge PR #35420 into master
* refs/pull/35420/head:
	mgr/volumes: Fix pool removal on volume deletion

Reviewed-by: Ramana Raja <rraja@redhat.com>
Reviewed-by: Patrick Donnelly <pdonnell@redhat.com>
Reviewed-by: Jos Collin <jcollin@redhat.com>
2020-06-25 14:33:12 -07:00
Patrick Donnelly
4636a1bda8
Merge PR #35664 into master
* refs/pull/35664/head:
	qa: add omit_sudo=False for commands ran with sudo

Reviewed-by: Patrick Donnelly <pdonnell@redhat.com>
Reviewed-by: Xiubo Li <xiubli@redhat.com>
2020-06-25 14:31:33 -07:00
Sebastian Wagner
1650257015 qa/cephadm: Add test for --format=yaml
Signed-off-by: Sebastian Wagner <sebastian.wagner@suse.com>
2020-06-25 12:33:19 +02:00
Patrick Donnelly
683153c56e
qa: fix flake8 warnings
Signed-off-by: Patrick Donnelly <pdonnell@redhat.com>
2020-06-24 15:43:33 -07:00
Patrick Donnelly
982041e89d
pybind/mgr/volumes: wire up pinning subvolumes/subvolumegroups
Fixes: https://tracker.ceph.com/issues/41541
Signed-off-by: Patrick Donnelly <pdonnell@redhat.com>
2020-06-24 15:43:32 -07:00
Patrick Donnelly
69e3f556a7
qa: adapt tests for empty pinned dir export
Previously, empty pinned directories were not migrated.

Signed-off-by: Patrick Donnelly <pdonnell@redhat.com>
2020-06-24 15:43:32 -07:00
Patrick Donnelly
091e8ffd9d
qa: break export pin tests into discrete tests
Signed-off-by: Patrick Donnelly <pdonnell@redhat.com>
2020-06-24 15:43:32 -07:00
Patrick Donnelly
aef549e49e
qa: add more ephemeral pin tests
Signed-off-by: Patrick Donnelly <pdonnell@redhat.com>
2020-06-24 15:43:32 -07:00
Sidharth Anupkrishnan
aa99c8546b
qa: add tests for ephemeral pinning
Signed-off-by: Sidharth Anupkrishnan <sanupkri@redhat.com>
2020-06-24 15:43:32 -07:00
Patrick Donnelly
5eea6761cc
mds: trim pinned and empty subtrees
Before export (and ephemeral) pinned subtrees are stuck in cache
forever.

Add qa test for checking export pinned directories can be trimmed.

Signed-off-by: Patrick Donnelly <pdonnell@redhat.com>
2020-06-24 15:43:31 -07:00
Patrick Donnelly
c050623065
qa: refactor _wait_subtree and _get_subtree
Signed-off-by: Patrick Donnelly <pdonnell@redhat.com>
2020-06-24 15:43:30 -07:00
Patrick Donnelly
ddb18091a6
qa: use status from wait_for_daemons
Avoid an extra `fs dump` call.

Signed-off-by: Patrick Donnelly <pdonnell@redhat.com>
2020-06-24 15:43:30 -07:00
Patrick Donnelly
f451c43aca
qa: quietly print json output from asok commands
Pretty print output once. Use --format=json so the stdout on teuthology
is not pretty printed, taking hundreds of lines.

Signed-off-by: Patrick Donnelly <pdonnell@redhat.com>
2020-06-24 15:43:29 -07:00
Patrick Donnelly
b107163146
qa: fix flake8 error
./tasks/vstart_runner.py:33:1: F401 'io.BytesIO' imported but unused

Signed-off-by: Patrick Donnelly <pdonnell@redhat.com>
2020-06-24 12:20:33 -07:00
Patrick Donnelly
9436a18686
Merge PR #35665 into master
* refs/pull/35665/head:
	vstart_runner.py: improve a conditional in _do_run

Reviewed-by: Patrick Donnelly <pdonnell@redhat.com>
2020-06-24 11:42:29 -07:00
Patrick Donnelly
af4d4ee6f1
Merge PR #35522 into master
* refs/pull/35522/head:
	vstart_runner: set default values of stdout and stderr to None

Reviewed-by: Xiubo Li <xiubli@redhat.com>
Reviewed-by: Patrick Donnelly <pdonnell@redhat.com>
2020-06-24 11:34:04 -07:00
Patrick Donnelly
e21f6bee65
Merge PR #35540 into master
* refs/pull/35540/head:
	qa/cephfs: don't pass cmd args from run_as_user as str
	qa/cephfs: refactor run_as_root() to user run_as_user()

Reviewed-by: Jeff Layton <jlayton@redhat.com>
Reviewed-by: Patrick Donnelly <pdonnell@redhat.com>
2020-06-24 11:31:29 -07:00
Kefu Chai
21ad5bf2eb qa/tasks/cephfs: flake8 fixes
Signed-off-by: Kefu Chai <kchai@redhat.com>
2020-06-24 10:12:11 +08:00
Kotresh HR
d07ea8db47 mgr/volumes: Fix pool removal on volume deletion
While volume deletion, the associated pools are not always
removed. The pools are removed only if the volume is created
using mgr plugin and not if created with custom osd pools.
This is because mgr plugin generates pool names with specific
pattern. Both create and delete volume relies on it. This
patch fixes the issue by identifying the pools of the volume
without relying on the pattern.

Fixes: https://tracker.ceph.com/issues/45910
Signed-off-by: Kotresh HR <khiremat@redhat.com>
2020-06-23 23:04:28 +05:30
Kefu Chai
981a7cc923 qa/tasks/cephfs/test_nfs.py: flake8 fixes
Signed-off-by: Kefu Chai <kchai@redhat.com>
2020-06-23 23:01:27 +08:00
Kefu Chai
663d64bd3b qa/tasks/vstart_runner: flake8 fixes
Signed-off-by: Kefu Chai <kchai@redhat.com>
2020-06-23 23:01:27 +08:00
Kefu Chai
fe6c9b5487 qa/tasks/ragweed: flake8 fixes
Signed-off-by: Kefu Chai <kchai@redhat.com>
2020-06-23 23:01:27 +08:00
Kefu Chai
2c2b5e0c63 qa/tasks/mgr/test_orchestrator_cli: flake8 fixes
Signed-off-by: Kefu Chai <kchai@redhat.com>
2020-06-23 23:01:27 +08:00
Kefu Chai
04290960f4 tasks/mgr/dashboard: flake8 fixes
Signed-off-by: Kefu Chai <kchai@redhat.com>
2020-06-23 23:01:27 +08:00
Kefu Chai
2fa726b88c qa/tasks: flake8 fixes
Signed-off-by: Kefu Chai <kchai@redhat.com>
2020-06-23 23:00:56 +08:00
Patrick Donnelly
0e1dc163db
Merge PR #35646 into master
* refs/pull/35646/head:
	qa/tasks/cephfs/nfs: Poll for max 60 seconds to ensure removal of ganesha services
	pybind/mgr/volumes/nfs: Remove unused cephfs module
	mgr/volumes/nfs: Ignore if ganesha disconnects

Reviewed-by: Patrick Donnelly <pdonnell@redhat.com>
Reviewed-by: Jeff Layton <jlayton@redhat.com>
Reviewed-by: Ramana Raja <rraja@redhat.com>
2020-06-23 06:44:08 -07:00
Varsha Rao
0caa54bae8 qa/tasks/cephfs/nfs: Poll for max 60 seconds to ensure removal of ganesha services
Fixes: https://tracker.ceph.com/issues/46104
Signed-off-by: Varsha Rao <varao@redhat.com>
2020-06-22 12:13:11 +05:30
Rishabh Dave
90727ee474 qa: add omit_sudo=False for commands ran with sudo
Commands that cleanup FUSE and kernel mount and that setup and
teardown/cleanup network namespaces are that ones that use sudo. Set
omit_sudo to False while running these commands.

Fixes: https://tracker.ceph.com/issues/46101
Signed-off-by: Rishabh Dave <ridave@redhat.com>
2020-06-19 14:21:04 +05:30
Rishabh Dave
1ff990c2a1 vstart_runner.py: improve a conditional in _do_run
Before checking for "/" in args[0], check if it's an instance of Raw.
Since Raw instances aren't iterable, the execution would crash here.

Fixes: https://tracker.ceph.com/issues/46100
Signed-off-by: Rishabh Dave <ridave@redhat.com>
2020-06-19 12:13:57 +05:30
Patrick Donnelly
62777f653d
qa: fix type error in stderr processing
Fixes: 422d736568
Signed-off-by: Patrick Donnelly <pdonnell@redhat.com>
2020-06-18 07:12:08 -07:00
Rishabh Dave
23f279d7a9 qa/cephfs: don't pass cmd args from run_as_user as str
Passing command arguments from run_as_user() to run_shell() as string
can be problematic since command argument to be passed to -c option of
sudo should be a single argument (i.e. 'ls dir' instead of
['ls', 'dir']).

Fixes: https://tracker.ceph.com/issues/46057
Signed-off-by: Rishabh Dave <ridave@redhat.com>
2020-06-17 23:13:05 +05:30
Rishabh Dave
4c9811aae3 qa/cephfs: refactor run_as_root() to user run_as_user()
Signed-off-by: Rishabh Dave <ridave@redhat.com>
2020-06-17 23:12:59 +05:30
Patrick Donnelly
f1174475e3
Merge PR #32111 into master
* refs/pull/32111/head:
	test_cephfs_shell: run cephfs-shell with conf file

Reviewed-by: Patrick Donnelly <pdonnell@redhat.com>
Reviewed-by: Varsha Rao <varao@redhat.com>
2020-06-17 09:42:21 -07:00
Patrick Donnelly
af98e6afbe
Merge PR #35539 into master
* refs/pull/35539/head:
	vstart_runner: set omit_sudo to True by default

Reviewed-by: Patrick Donnelly <pdonnell@redhat.com>
2020-06-17 09:38:36 -07:00
Rishabh Dave
58c7c7e8f4 test_cephfs_shell: run cephfs-shell with conf file
And set colors to False and debug to True in this conf file.

stdout captured by Python code in this testsuite can contain the colour
codes along with the expected string output. Setting colors to False in
cephfs-shell.conf should fix this.

Setting debug to False should help with analyzing test failures since
it enables printing messages that helps debugging (stacktrace for
cephfs-shell code, for example).

Signed-off-by: Rishabh Dave <ridave@redhat.com>
2020-06-17 17:21:31 +05:30
Kefu Chai
48ee2b8441
Merge pull request #35395 from kshtsk/wip-registry-conf
qa/tasks/cephadm: setup site based container registry

Reviewed-by: Kefu Chai <kchai@redhat.com>
2020-06-17 19:49:20 +08:00
Rishabh Dave
cc8f15818a vstart_runner: set default values of stdout and stderr to None
Not doing so leads to tests run successfully with vstart_runner.py but
crash when triggered with teuthology since the default values of these
variables there is None.

Fixes: https://tracker.ceph.com/issues/45815
Signed-off-by: Rishabh Dave <ridave@redhat.com>
2020-06-17 14:42:53 +05:30
Patrick Donnelly
0e74b92258
Merge PR #32288 into master
* refs/pull/32288/head:
	test_cephfs_shell: remove test_every_shell_cmd_at_invocation
	test_cephfs_shell: catch specific exception instead of catching all
	cephfs-shell: set return value before exiting
	test_cephfs_shell: re-arrange TestCephFSShell's methods
	cephfs-shell: re-arrange code under __main__
	test_cephfs_shell: add new test for shell cmd at invocation
	cephfs-shell: launch shell only if there are no args following

Reviewed-by: Patrick Donnelly <pdonnell@redhat.com>
Reviewed-by: Varsha Rao <varao@redhat.com>
2020-06-16 19:28:48 -07:00
Patrick Donnelly
4b54ab690b
Merge PR #34716 into master
* refs/pull/34716/head:
	mgr/volumes: Add snapshot info command

Reviewed-by: Patrick Donnelly <pdonnell@redhat.com>
Reviewed-by: Jos Collin <jcollin@redhat.com>
2020-06-12 14:10:14 -07:00
Patrick Donnelly
7952dc58b2
Merge PR #35261 into master
* refs/pull/35261/head:
	qa/vstart_runner.py: ignores when source and destination are same

Reviewed-by: Patrick Donnelly <pdonnell@redhat.com>
Reviewed-by: Varsha Rao <varao@redhat.com>
2020-06-12 14:08:13 -07:00
Neha Ojha
04553e8822
Merge pull request #35544 from neha-ojha/wip-reduce-noise
qa/tasks/ceph_manager.py: dump more useful info before failing

Reviewed-by: Josh Durgin <jdurgin@redhat.com>
2020-06-11 15:40:46 -07:00
Neha Ojha
4deba4e8bd qa/tasks/ceph_manager.py: dump more useful info before failing
Add helpers that dump information only about PGs that haven't reached
the desired state when we fail. Previously we dumped the output of
"ceph pg dump" before failing, which prints a lot of unnecessary information
about PGs that are not responsible for the failure, making debugging harder.

Also, try to make the failure messages distinct.

Signed-off-by: Neha Ojha <nojha@redhat.com>
2020-06-11 15:22:04 +00:00
Rishabh Dave
e68736961f vstart_runner: set omit_sudo to True by default
Let's set omit_sudo to True by default since we don't to run
commands with sudo on developer's machine as far as possible.

Signed-off-by: Rishabh Dave <ridave@redhat.com>
2020-06-11 17:05:40 +05:30
Kefu Chai
b010a137c7
Merge pull request #35521 from sebastian-philipp/dashboard-mgr-module-option-default-value-none-for-it-or-float
mgr/dashboard: fix None value for ints and floats

Reviewed-by: Volker Theile <vtheile@suse.com>
Reviewed-by: Neha Ojha <nojha@redhat.com>
2020-06-11 14:17:15 +08:00
Kefu Chai
4fb37f881f
Merge pull request #35486 from jdurgin/wip-radosbench-qa
qa/tasks/radosbench: use long form of option for compatibility

Reviewed-by: Yuri Weinstein <yweinste@redhat.com>
Reviewed-by: Brad Hubbard <bhubbard@redhat.com>
2020-06-11 09:28:11 +08:00
Kyr Shatskyy
d8edde0c53 qa/tasks/cephadm: setup site based container registry
Add containers registry mirror for 'docker.io' to the config
file /etc/containers/registries.conf

Since we need site based config, so each teuthology instance
could have own containers' mirror, store corresponding data
in /etc/teuthology.yaml under 'overrides/cephadm' task specific
section.

Signed-off-by: Kyr Shatskyy <kyrylo.shatskyy@suse.com>
2020-06-10 17:03:58 +02:00
Sebastian Wagner
f6f9b3fb99 mgr/dashboard: fix None value for ints and floats
Fixes: https://tracker.ceph.com/issues/45963

Signed-off-by: Sebastian Wagner <sebastian.wagner@suse.com>
2020-06-10 15:43:54 +02:00
Lenz Grimmer
11ddc9c8de
Merge pull request #35007 from rhcs-dashboard/fix-36354-master
mgr/dashboard: work with v1 RBD images

Reviewed-by: Jason Dillaman <dillaman@redhat.com>
Reviewed-by: Kiefer Chang <kiefer.chang@suse.com>
Reviewed-by: Laura Paduano <lpaduano@suse.com>
Reviewed-by: Mykola Golub <mgolub@suse.com>
Reviewed-by: Stephan Müller <smueller@suse.com>
2020-06-10 13:32:37 +02:00
Josh Durgin
9673d37f1b qa/tasks/radosbench: use long form of option for compatibility
Since the short version of --object-size changed from -o to -O, it
does not work with upgrade tests.

Signed-off-by: Josh Durgin <jdurgin@redhat.com>
2020-06-09 13:13:55 -07:00