mirror of
https://github.com/ceph/ceph
synced 2025-01-20 10:01:45 +00:00
qa: move existing rbd-mirror functional test to journal-specific test
A new functional test for snapshot-based mirroring will be created and the other stress-tests should eventually be applied to both snapshot- and journal-based mirroring. Signed-off-by: Jason Dillaman <dillaman@redhat.com>
This commit is contained in:
parent
dc7a069ce8
commit
ffa791f540
@ -1,9 +1,9 @@
|
||||
meta:
|
||||
- desc: run the rbd_mirror.sh workunit to test the rbd-mirror daemon
|
||||
- desc: run the rbd_mirror_journal.sh workunit to test the rbd-mirror daemon
|
||||
tasks:
|
||||
- workunit:
|
||||
clients:
|
||||
cluster1.client.mirror: [rbd/rbd_mirror.sh]
|
||||
cluster1.client.mirror: [rbd/rbd_mirror_journal.sh]
|
||||
env:
|
||||
# override workunit setting of CEPH_ARGS='--cluster'
|
||||
CEPH_ARGS: ''
|
@ -1,5 +1,5 @@
|
||||
meta:
|
||||
- desc: run the rbd_mirror.sh workunit to test the rbd-mirror daemon
|
||||
- desc: run the rbd_mirror_stress.sh workunit to test the rbd-mirror daemon
|
||||
tasks:
|
||||
- workunit:
|
||||
clients:
|
||||
|
@ -1,9 +1,9 @@
|
||||
meta:
|
||||
- desc: run the rbd_mirror.sh workunit to test the rbd-mirror daemon
|
||||
- desc: run the rbd_mirror_journal.sh workunit to test the rbd-mirror daemon
|
||||
tasks:
|
||||
- workunit:
|
||||
clients:
|
||||
cluster1.client.mirror: [rbd/rbd_mirror.sh]
|
||||
cluster1.client.mirror: [rbd/rbd_mirror_journal.sh]
|
||||
env:
|
||||
# override workunit setting of CEPH_ARGS='--cluster'
|
||||
CEPH_ARGS: ''
|
||||
|
@ -1,9 +1,9 @@
|
||||
meta:
|
||||
- desc: run the rbd_mirror.sh workunit to test the rbd-mirror daemon
|
||||
- desc: run the rbd_mirror_journal.sh workunit to test the rbd-mirror daemon
|
||||
tasks:
|
||||
- workunit:
|
||||
clients:
|
||||
cluster1.client.mirror: [rbd/rbd_mirror.sh]
|
||||
cluster1.client.mirror: [rbd/rbd_mirror_journal.sh]
|
||||
env:
|
||||
# override workunit setting of CEPH_ARGS='--cluster'
|
||||
CEPH_ARGS: ''
|
||||
|
@ -1,5 +1,5 @@
|
||||
meta:
|
||||
- desc: run the rbd_mirror.sh workunit to test the rbd-mirror daemon
|
||||
- desc: run the rbd_mirror_journal.sh workunit to test the rbd-mirror daemon
|
||||
overrides:
|
||||
ceph:
|
||||
conf:
|
||||
@ -8,7 +8,7 @@ overrides:
|
||||
tasks:
|
||||
- workunit:
|
||||
clients:
|
||||
cluster1.client.mirror: [rbd/rbd_mirror.sh]
|
||||
cluster1.client.mirror: [rbd/rbd_mirror_journal.sh]
|
||||
env:
|
||||
# override workunit setting of CEPH_ARGS='--cluster'
|
||||
CEPH_ARGS: ''
|
||||
|
@ -1,5 +1,5 @@
|
||||
meta:
|
||||
- desc: run the rbd_mirror.sh workunit to test the rbd-mirror daemon
|
||||
- desc: run the rbd_mirror_journal.sh workunit to test the rbd-mirror daemon
|
||||
overrides:
|
||||
ceph:
|
||||
conf:
|
||||
@ -8,7 +8,7 @@ overrides:
|
||||
tasks:
|
||||
- workunit:
|
||||
clients:
|
||||
cluster1.client.mirror: [rbd/rbd_mirror.sh]
|
||||
cluster1.client.mirror: [rbd/rbd_mirror_journal.sh]
|
||||
env:
|
||||
# override workunit setting of CEPH_ARGS='--cluster'
|
||||
CEPH_ARGS: ''
|
||||
|
@ -24,7 +24,7 @@
|
||||
# The cleanup can be done as a separate step, running the script with
|
||||
# `cleanup ${RBD_MIRROR_TEMDIR}' arguments.
|
||||
#
|
||||
# Note, as other workunits tests, rbd_mirror.sh expects to find ceph binaries
|
||||
# Note, as other workunits tests, rbd_mirror_journal.sh expects to find ceph binaries
|
||||
# in PATH.
|
||||
#
|
||||
# Thus a typical troubleshooting session:
|
||||
@ -35,7 +35,7 @@
|
||||
# cd $CEPH_SRC_PATH
|
||||
# PATH=$CEPH_SRC_PATH:$PATH
|
||||
# RBD_MIRROR_NOCLEANUP=1 RBD_MIRROR_TEMDIR=/tmp/tmp.rbd_mirror \
|
||||
# ../qa/workunits/rbd/rbd_mirror.sh
|
||||
# ../qa/workunits/rbd/rbd_mirror_journal.sh
|
||||
#
|
||||
# After the test failure cd to TEMPDIR and check the current state:
|
||||
#
|
||||
@ -53,17 +53,17 @@
|
||||
#
|
||||
# cd $CEPH_SRC_PATH
|
||||
# export RBD_MIRROR_TEMDIR=/tmp/tmp.rbd_mirror
|
||||
# ../qa/workunits/rbd/rbd_mirror.sh status
|
||||
# ../qa/workunits/rbd/rbd_mirror.sh stop_mirror cluster1
|
||||
# ../qa/workunits/rbd/rbd_mirror.sh start_mirror cluster2
|
||||
# ../qa/workunits/rbd/rbd_mirror.sh flush cluster2
|
||||
# ../qa/workunits/rbd/rbd_mirror_journal.sh status
|
||||
# ../qa/workunits/rbd/rbd_mirror_journal.sh stop_mirror cluster1
|
||||
# ../qa/workunits/rbd/rbd_mirror_journal.sh start_mirror cluster2
|
||||
# ../qa/workunits/rbd/rbd_mirror_journal.sh flush cluster2
|
||||
# ...
|
||||
#
|
||||
# Eventually, run the cleanup:
|
||||
#
|
||||
# cd $CEPH_SRC_PATH
|
||||
# RBD_MIRROR_TEMDIR=/tmp/tmp.rbd_mirror \
|
||||
# ../qa/workunits/rbd/rbd_mirror.sh cleanup
|
||||
# ../qa/workunits/rbd/rbd_mirror_journal.sh cleanup
|
||||
#
|
||||
|
||||
if type xmlstarlet > /dev/null 2>&1; then
|
||||
@ -1132,8 +1132,9 @@ enable_mirror()
|
||||
local cluster=$1
|
||||
local pool=$2
|
||||
local image=$3
|
||||
local mode=${4:-journal}
|
||||
|
||||
rbd --cluster=${cluster} mirror image enable ${pool}/${image}
|
||||
rbd --cluster=${cluster} mirror image enable ${pool}/${image} ${mode}
|
||||
}
|
||||
|
||||
test_image_present()
|
||||
|
@ -1,6 +1,6 @@
|
||||
#!/bin/sh -ex
|
||||
#
|
||||
# rbd_mirror.sh - test rbd-mirror daemon
|
||||
# rbd_mirror_journal.sh - test rbd-mirror daemon in journal-based mirroring mode
|
||||
#
|
||||
# The scripts starts two ("local" and "remote") clusters using mstart.sh script,
|
||||
# creates a temporary directory, used for cluster configs, daemon logs, admin
|
||||
@ -230,7 +230,7 @@ clone_image=test_clone
|
||||
clone_image ${CLUSTER2} ${PARENT_POOL} ${parent_image} ${parent_snap} ${POOL} ${clone_image}
|
||||
write_image ${CLUSTER2} ${POOL} ${clone_image} 100
|
||||
|
||||
enable_mirror ${CLUSTER2} ${PARENT_POOL} ${parent_image}
|
||||
enable_mirror ${CLUSTER2} ${PARENT_POOL} ${parent_image} journal
|
||||
wait_for_image_replay_started ${CLUSTER1} ${PARENT_POOL} ${parent_image}
|
||||
wait_for_replay_complete ${CLUSTER1} ${CLUSTER2} ${PARENT_POOL} ${parent_image}
|
||||
wait_for_status_in_pool_dir ${CLUSTER1} ${PARENT_POOL} ${parent_image} 'up+replaying' 'master_position'
|
||||
@ -398,7 +398,7 @@ testlog "TEST: non-default namespace image mirroring"
|
||||
testlog " - replay"
|
||||
create_image ${CLUSTER2} ${POOL}/${NS1} ${image}
|
||||
create_image ${CLUSTER2} ${POOL}/${NS2} ${image}
|
||||
enable_mirror ${CLUSTER2} ${POOL}/${NS2} ${image}
|
||||
enable_mirror ${CLUSTER2} ${POOL}/${NS2} ${image} journal
|
||||
wait_for_image_replay_started ${CLUSTER1} ${POOL}/${NS1} ${image}
|
||||
wait_for_image_replay_started ${CLUSTER1} ${POOL}/${NS2} ${image}
|
||||
write_image ${CLUSTER2} ${POOL}/${NS1} ${image} 100
|
Loading…
Reference in New Issue
Block a user