Commit Graph

288 Commits

Author SHA1 Message Date
Ning Yao
5b486d9628 test: add test for rbd import,import-diff,copy with sparse-size option
Signed-off-by: Ning Yao <yaoning@unitedstack.com>
2017-04-04 03:18:52 +00:00
Kefu Chai
f903f2f3fd Merge pull request #13228 from trociny/wip-qa-rbd_mirror-opts
qa/workunits/rbd: tweak rbd-mirror config to spead up testing

Reviewed-by: Jason Dillaman <dillaman@redhat.com>
2017-03-06 12:07:23 +08:00
Dongsheng Yang
064b23df85 qa: rbd: rename the copy.sh to generic.sh
The copy.sh is not only testing the rbd copy, but also
others such as rbd ls, rbd remove. Then rename it to generic.sh

Signed-off-by: Dongsheng Yang <dongsheng.yang@easystack.cn>
2017-02-23 11:10:59 +08:00
Dongsheng Yang
4447340e8d qa: add a test for rbd rm NOT_EXIST
Signed-off-by: Dongsheng Yang <dongsheng.yang@easystack.cn>
2017-02-23 11:10:59 +08:00
Dongsheng Yang
3d26d932af librbd: remove header when id missing
Signed-off-by: Dongsheng Yang <dongsheng.yang@easystack.cn>
2017-02-21 19:17:26 +08:00
Dongsheng Yang
4ee764f9e1 qa/workunit/rbd: import_export.sh: add image priorities exporting and importing test cases.
Signed-off-by: Dongsheng Yang <dongsheng.yang@easystack.cn>
2017-02-19 20:42:03 +08:00
Dongsheng Yang
55edd81658 qa/workunit/rbd: add test case for --import/export-format in import_export.sh
Signed-off-by: Dongsheng Yang <dongsheng.yang@easystack.cn>
2017-02-19 20:42:03 +08:00
Ilya Dryomov
4db31d53d9 qa: add workunit to test krbd data-pool support
This is based on a script that I've been using for a while for basic
smoke testing.  The matrix has exploded with the addition of data-pool
and now it's primarily a data-pool test fixture that takes minutes to
run, so turning it into a workunit.

Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
2017-02-16 22:42:46 +01:00
Jason Dillaman
63eae97afc qa/workunits/rbd: resolve potential rbd-mirror race conditions
Fixes: http://tracker.ceph.com/issues/18935
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
2017-02-14 15:58:31 -05:00
Mykola Golub
596e5ea8a5 rbd-nbd: check /sys/block/nbdX/size to ensure kernel mapped correctly
Fixes: http://tracker.ceph.com/issues/18335
Signed-off-by: Mykola Golub <mgolub@mirantis.com>
2017-02-04 15:40:51 +01:00
Mykola Golub
58798be83a qa/workunits/rbd: tweak rbd-mirror config to spead up testing
Signed-off-by: Mykola Golub <mgolub@mirantis.com>
2017-02-02 08:45:19 +01:00
Mykola Golub
93f7b5ef3f Merge pull request #13158 from dillaman/wip-18594
qa: integrate OpenStack 'gate-tempest-dsvm-full-devstack-plugin-ceph'

Reviewed-by: Mykola Golub <mgolub@mirantis.com>
2017-02-02 08:27:49 +02:00
Jason Dillaman
a1b088a727 Merge pull request #13189 from gaurav36/bug-18326-image-rename-non-rbd-pool
rbd: destination pool should be source pool if it is not specified

Reviewed-by: Jason Dillaman <dillaman@redhat.com>
2017-02-01 12:47:01 -05:00
Mykola Golub
2bb480e8c3 qa/workunits/rbd: tweaks to use RBD_MIRROR_USE_EXISTING_CLUSTER locally
This var is mostly used when running rbd_mirror test scripts on
teuthology.  It can be used locally though to speedup re-running the
tests:

Set a test temp directory:

  export RBD_MIRROR_TEMDIR=/tmp/tmp.rbd_mirror

Run the tests the first time with NOCLEANUP flag (the cluster and
daemons are not stopped on finish):

  RBD_MIRROR_NOCLEANUP=1 ../qa/workunits/rbd/rbd_mirror.sh

Now, to re-run the test without restarting the cluster, run cleanup
with USE_EXISTING_CLUSTER flag:

  RBD_MIRROR_USE_EXISTING_CLUSTER=1 \
    ../qa/workunits/rbd/rbd_mirror_ha.sh cleanup

and then run the tests:

  RBD_MIRROR_USE_EXISTING_CLUSTER=1
    ../qa/workunits/rbd/rbd_mirror_ha.sh

Signed-off-by: Mykola Golub <mgolub@mirantis.com>
2017-02-01 10:55:03 +01:00
Mykola Golub
c802b9df0b qa/workunits/rbd: tests for rbd mirror HA
Signed-off-by: Mykola Golub <mgolub@mirantis.com>
2017-02-01 10:55:03 +01:00
Mykola Golub
7c21275f4f qa/workunits/rbd: allow to start several daemons for the same cluster
by optionally specifyning daemon instance after cluster name and
colon, like:

  start_mirror ${cluster}:${instance}

Signed-off-by: Mykola Golub <mgolub@mirantis.com>
2017-02-01 10:55:03 +01:00
Gaurav Kumar Garg
01f23aa99f rbd: destination pool should be source pool if it is not specified
Currently if user perform image rename operation and user give pool
name as a optional parameter (--pool=<pool_name>) then currently
its taking this optional pool name for source pool and making
destination pool name default pool name.
With this fix if user provide pool name as a optional pool name
parameter then it  will consider both soruce and destination pool
name as optional parameter pool name.

Fixes: http://tracker.ceph.com/issues/18326

Reported-by: МАРК КОРЕНБЕРГ <socketpair@gmail.com>
Signed-off-by: Gaurav Kumar Garg <garg.gaurav52@gmail.com>
2017-02-01 10:20:39 +01:00
Jason Dillaman
deaaba8fcf qa/suites/rbd: OpenStack devstack tempest full suite
This mimics the OpenStack tempest gate tests that OpenStack
Zuul executes as a gate test.

Fixes: http://tracker.ceph.com/issues/18594
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
2017-01-27 14:22:48 -05:00
Mykola Golub
72158bd9a3 qa/workunits/rbd: allow to tweak rbd-mirror test setup
Signed-off-by: Mykola Golub <mgolub@mirantis.com>
2017-01-12 18:09:02 +01:00
Nathan Cutler
4f4f35e37c tests: drop rbd_cli_tests.pl and RbdLib.pm
The rbd_cli_tests Perl script is not maintained and currently serves no
purpose. The RbdLib.pm module was only used by rbd_functional_tests.pl (which
was dropped by 276ffb4631) and rbd_cli_tests.pl
so drop it as well.

Fixes: http://tracker.ceph.com/issues/14825
Signed-off-by: Nathan Cutler <ncutler@suse.com>
2017-01-08 16:17:08 +01:00
Jason Dillaman
a159f3d1c0 Merge pull request #12549 from trociny/wip-16555
librbd: permit removal of image being bootstrapped by rbd-mirror

Reviewed-by: Jason Dillaman <dillaman@redhat.com>
2017-01-06 17:57:53 -05:00
Nathan Cutler
91231de16d tests: rbd/test_lock_fence.sh: fix rbdrw.py relative path
This commit fixes a regression introduced by
cf294777ea

Fixes: http://tracker.ceph.com/issues/18388
Signed-off-by: Nathan Cutler <ncutler@suse.com>
2017-01-02 22:53:13 +01:00
Mykola Golub
11d6caf367 librbd: permit removal of image being bootstrapped by rbd-mirror
Fixes: http://tracker.ceph.com/issues/16555
Signed-off-by: Mykola Golub <mgolub@mirantis.com>
2016-12-20 20:07:51 +02:00
Sage Weil
5666fd61d6 qa/workunits: include extension for nose tests
When you have a relative path you have to include the extension.
Weird.

Signed-off-by: Sage Weil <sage@redhat.com>
2016-12-19 14:08:11 -05:00
Sage Weil
cf294777ea qa/workunits: use relative path instead of wget from git
Signed-off-by: Sage Weil <sage@redhat.com>
2016-12-15 15:10:28 -05:00
Jason Dillaman
4314cb945a qa/workunits/rbd: use more recent qemu-iotests that support Xenial
Fixes: http://tracker.ceph.com/issues/18149
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
2016-12-10 20:42:52 -05:00
Jason Dillaman
2c70df978d qa/workunits/rbd: removed qemu-iotest case 077
The test case is not stable due to racing console output. This
results in spurious failures.

Fixes: http://tracker.ceph.com/issues/10773
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
2016-12-07 09:59:39 -05:00
Mykola Golub
6cb1ed485f rbd-mirror: make 'rbd mirror image resync' work after split-brain
Fixes: http://tracker.ceph.com/issues/18051
Signed-off-by: Mykola Golub <mgolub@mirantis.com>
2016-12-03 19:50:27 +02:00
Mykola Golub
cccca67d5f rbd-mirror: split-brain issues should be clearly visible in mirror status
Fixed: http://tracker.ceph.com/issues/16991
Signed-off-by: Mykola Golub <mgolub@mirantis.com>
2016-12-03 19:37:10 +02:00
Mykola Golub
7c078eda0f qa/workunits/rbd: test_status_in_pool_dir: explicitly check grep return value
Otherwise, it does not work as supposed to work in statements like below:

 set -e
 test_status_in_pool_dir ... && ...

(e.g. in wait_for_status_in_pool_dir)

Signed-off-by: Mykola Golub <mgolub@mirantis.com>
2016-12-03 19:37:10 +02:00
Mykola Golub
c23f56b983 qa/workunits/rbd: use image id when probing for image presence
This fixes a race in resync tests leading to false negative results.

Fixes: http://tracker.ceph.com/issues/18048
Signed-off-by: Mykola Golub <mgolub@mirantis.com>
2016-11-29 10:04:37 +02:00
Venky Shankar
3a91d7bd2e qa / workunits: make rbd import/export work with image data pool
Signed-off-by: Venky Shankar <vshankar@redhat.com>
2016-11-20 21:21:50 +05:30
Mykola Golub
a3df091595 qa/workunits/rbd: simplify running nbd test under build env
Previously running the script as unprivileged user was not very useful
due to difficulty to change path sudo was looking for a command to
execute.

Signed-off-by: Mykola Golub <mgolub@mirantis.com>
2016-11-04 16:22:51 +02:00
Mykola Golub
2012b4dfc6 rbd-nbd: disallow mapping images >2TB in size
Fixes: http://tracker.ceph.com/issues/17219
Signed-off-by: Mykola Golub <mgolub@mirantis.com>
2016-11-03 14:50:47 +02:00
Mykola Golub
300a2810ac rbd-nbd: support disabling auto-exclusive lock transition logic
Fixes: http://tracker.ceph.com/issues/17488
Signed-off-by: Mykola Golub <mgolub@mirantis.com>
2016-10-12 21:00:25 +03:00
Jason Dillaman
a6dd6b50d6 qa/workunits: reduce amount of client IO for rbd-mirror stress
Journal IO is faster now, resulting in OSDs quickly filling up
under the stress test case.

Signed-off-by: Jason Dillaman <dillaman@redhat.com>
2016-10-04 21:31:54 -04:00
Jason Dillaman
3e4a59d81b Merge pull request #11291 from trociny/wip-qa-mirror-asok
qa/workunits/rbd: check status also in pool dir after asok commands

Reviewed-by: Jason Dillaman <dillaman@redhat.com>
2016-10-04 11:22:53 -04:00
Mykola Golub
eb4097b8ef qa/workunits/rbd: set image-meta on primary image and wait it is replicated
After recently added image metadata replication it is not possible any
more to update it on non-primary image.

Signed-off-by: Mykola Golub <mgolub@mirantis.com>
2016-10-03 17:02:59 +03:00
Mykola Golub
2882f8c01a qa/workunits/rbd: check status also in pool dir after asok commands
wait_for_image_replay_stopped returns not when the state is stopped,
but when the state is not replaying. So a race was possible when an
asok command was running when the previos stop command was still in
progress, leading to unexpected results.

Signed-off-by: Mykola Golub <mgolub@mirantis.com>
2016-10-03 10:10:33 +03:00
Ricardo Dias
5c737038dd
rbd-mirror: test: Fixed timeout problem in rbd_mirror_stress.sh
Signed-off-by: Ricardo Dias <rdias@suse.com>
2016-09-26 14:25:25 +01:00
Jason Dillaman
a0f65b968b qa/workunits/rbd: fix remove mirrored image race conditions
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
2016-09-23 09:01:52 -04:00
Jason Dillaman
a43268a4a3 qa/workunits/rbd: new mirroring forced promotion test
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
2016-09-23 09:01:52 -04:00
Mykola Golub
77fd6a1c20 rbd-mirror: option to automatically resync after journal client disconnect
Signed-off-by: Mykola Golub <mgolub@mirantis.com>
2016-09-05 12:48:47 +03:00
Mykola Golub
330dba00ba rbd-mirror: stop replay when client is disconnected
Signed-off-by: Mykola Golub <mgolub@mirantis.com>
2016-09-05 12:48:47 +03:00
Jason Dillaman
e6aa18ea0d qa/workunits/rbd: demote/promote image on same cluster
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
2016-08-16 09:09:52 -04:00
Jason Dillaman
efa5f730cc Merge pull request #10488 from lande1234/wip-lan-testing
rbd-mirror: add additional test scenarios

Reviewed-by: Jason Dillaman <dillaman@redhat.com>
2016-08-05 09:20:37 -04:00
Mykola Golub
a5f63f7261 qa/workunits/rbd: wait for image deleted before checking health
This is a fixup to the previous commit.

Signed-off-by: Mykola Golub <mgolub@mirantis.com>
2016-08-02 20:06:17 +03:00
Mykola Golub
df2aa585c4 Merge pull request #10341 from dillaman/wip-16223
rbd-mirror: reduce memory footprint during journal replay

Reviewed-by: Mykola Golub <mgolub@mirantis.com>
2016-07-30 19:28:02 +03:00
lande1234
aba7d3b874 Test scenario
Signed-off-by: lande1234 <lan.de3@zte.com.cn>
2016-07-29 04:58:26 +00:00
Mykola Golub
8dbe42d345 qa/workunits/rbd: wait for image deleted before checking health
When a primiry image is being deleted, the mirrored image might
temporary be reported in error state, before deletion is propagated.

Signed-off-by: Mykola Golub <mgolub@mirantis.com>
2016-07-28 14:55:42 +03:00