Commit Graph

38 Commits

Author SHA1 Message Date
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
lande1234
aba7d3b874 Test scenario
Signed-off-by: lande1234 <lan.de3@zte.com.cn>
2016-07-29 04:58:26 +00:00
Jason Dillaman
ab5ebdef32 Merge pull request #10123 from trociny/wip-16449
librbd: prevent creation of clone from non-primary mirrored image

Reviewed-by: Jason Dillaman <dillaman@redhat.com>
2016-07-24 11:12:57 -04:00
Jason Dillaman
2f4cb26d8b qa/workunits/rbd: exercise snapshot renames within rbd-mirror test
Snapshot rename operations utilize the (cluster) unique snapshot
sequence to prevent attempts at replays. When mirroring to a
different cluster, these sequences will not align.

Signed-off-by: Jason Dillaman <dillaman@redhat.com>
2016-07-19 09:27:32 -04:00
Mykola Golub
ba849e3b04 librbd: prevent creation of clone from non-primary mirrored image
Fixes: http://tracker.ceph.com/issues/16449
Signed-off-by: Mykola Golub <mgolub@mirantis.com>
2016-07-14 23:02:18 +03:00
Mykola Golub
9737a8d6cb qa/workunits/rbd: before removing image make sure it is not bootstrapped
If an image is being bootstrapped, it implies that the rbd-mirror
daemon currently has the image open. The removal API will prevent the
removal of any image that is opened by another client.

Works-around: http://tracker.ceph.com/issues/16555
Signed-off-by: Mykola Golub <mgolub@mirantis.com>
2016-07-06 12:59:25 +03:00
Ricardo Dias
8953825956
rbd-mirror: resync: Added unit tests
Signed-off-by: Ricardo Dias <rdias@suse.com>
2016-06-14 21:24:07 +01:00
Jason Dillaman
6a68b68e0d qa/workunits: ensure replay has started before checking position
Fixes: http://tracker.ceph.com/issues/16248
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
2016-06-13 00:19:37 -04:00
Mykola Golub
698242e743 qa/workunits/rbd: specify source path
otherwise it looks in $PATH for the script

Signed-off-by: Mykola Golub <mgolub@mirantis.com>
2016-06-11 20:30:32 +03:00
Jason Dillaman
db3e583a5f qa/workunits/rbd: additional rbd-mirror stress tests
Fixes: http://tracker.ceph.com/issues/16197
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
2016-06-10 09:40:34 -04:00
Jason Dillaman
de15b198cd qa/workunits/rbd: improve deletion propagation test case
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
2016-06-10 00:15:20 -04:00
Jason Dillaman
943ff82987 qa/workunits/rbd: basic cloned image test
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
2016-05-31 23:08:02 -04:00
Jason Dillaman
f4339ee8cb rbd-mirror: cluster-level asok commands need to support multiple pools
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
2016-05-28 13:36:10 -04:00
Jason Dillaman
839544ee64 qa/workunits/rbd: create secondary replicated pool
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
2016-05-26 13:37:37 -04:00
Ricardo Dias
d85e312ead rbd-mirror: test: added image-deleter test case when mirroring is disabled
Signed-off-by: Ricardo Dias <rdias@suse.com>
2016-05-22 16:13:21 -04:00
Jason Dillaman
8ef09c4d8d qa/workunits/rbd: fixed rbd_mirror teuthology runtime errors
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
2016-05-18 15:02:14 -04:00
Jason Dillaman
2c88ef8682 Merge pull request #8809 from trociny/wip-rbd-mirror-asok-restart
rbd-mirror: admin socket commands to start/stop/restart mirroring

Reviewed-by: Jason Dillaman <dillaman@redhat.com>
2016-05-03 14:13:46 -04:00
Mykola Golub
a22cf518f9 rbd-mirror: admin socket commands to start/stop/restart mirroring
Signed-off-by: Mykola Golub <mgolub@mirantis.com>
2016-05-02 22:52:02 +03:00
Mykola Golub
4c28fc2aa3 qa/workunits/rbd: fix rbd-mirror log file name
Signed-off-by: Mykola Golub <mgolub@mirantis.com>
2016-05-01 22:04:46 +03:00
Mykola Golub
21790484dc rbd-mirror: make image replayer asok commands available when not started
Initially the asok commands were registered only after the image
replayer start (and unregistered on stop) because their names were
built using remote pool and image names, which became known only after
start.

Now, the asok commands are registered on the image replayer construction
using the temporary name "remote_pool_name/global_image_id". They are
re-registered using "remote_pool_name/remote_image_name" when the
image replayer is started.  Also the commands are not unregistered on
the image replayer stop.

Signed-off-by: Mykola Golub <mgolub@mirantis.com>
2016-05-01 18:33:54 +03:00
Josh Durgin
dcd11a1f26 qa/workunits/rbd: add env vars to adapt rbd_mirror.sh to teuthology
With these set, this script can work in teuthology, where we want to
control the how daemons run and their log locations, valgrind
settings, etc. The workunit task always sets CEPH_ID, and allows
other env vars to be configured optionally.

The RBD_MIRROR_USE_EXISTING_CLUSTER option can also speed up local testing.

Signed-off-by: Josh Durgin <jdurgin@redhat.com>
2016-04-29 10:01:51 -07:00
Josh Durgin
5fe64fa806 qa: rbd_mirror.sh: change parameters to cluster rather than daemon name
Daemon name is only useful to differentiate asok and pid filenames, so
just inline its use there. Everywhere else replace the 'daemon'
parameter with cluster or local_cluster as appropriate.

Remove the CLUSTER{1,2}_DAEMON vars as well, since they are no longer
used.

Signed-off-by: Josh Durgin <jdurgin@redhat.com>
2016-04-29 10:01:29 -07:00
Mykola Golub
f15cd51a1d qa/workunits/rbd: test mirror status in pool directory
Signed-off-by: Mykola Golub <mgolub@mirantis.com>
2016-04-29 11:47:49 +03:00
Mykola Golub
4e1e81a2a7 qa/workunits/rbd: use cluster1/2 instead local/remote as cluster names
After adding tests that start daemons in both clusters, local/remote
names look confusing.

Signed-off-by: Mykola Golub <mgolub@mirantis.com>
2016-03-31 14:17:58 +03:00
Mykola Golub
2226019037 qa/workunits/rbd: add helper to determine rbd-mirror local cluster
Signed-off-by: Mykola Golub <mgolub@mirantis.com>
2016-03-31 14:16:21 +03:00
Mykola Golub
70b1303a08 qa/workunits/rbd: improvements for manual testing
Signed-off-by: Mykola Golub <mgolub@mirantis.com>
2016-03-31 11:42:13 +03:00
Jason Dillaman
ded7a77931 qa/workunits/rbd: add basic failover/fallback test case
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
2016-03-29 15:19:26 -04:00
Jason Dillaman
f65cc6fc31 Merge pull request #8172 from trociny/fix-test-rbd-mirror-position
test: rbd-mirror: compare positions using all fields

Reviewed-by: Jason Dillaman <dillaman@redhat.com>
2016-03-19 16:33:36 -04:00
Josh Durgin
62771e4a92 Merge pull request #8182 from trociny/wip-rbd-mirror-args
rbd-mirror: make remote context respect env and argv config params

Conflicts:
	qa/workunits/rbd/rbd_mirror.sh (asok command format changed)

Reviewed-by: Josh Durgin <jdurgin@redhat.com>
Reviewed-by: Jason Dillaman <dillaman@redhat.com>
2016-03-18 15:03:33 -07:00
Mykola Golub
13c7ba4c67 test: rbd-mirror: different log and asok location for local/remote contexts
Signed-off-by: Mykola Golub <mgolub@mirantis.com>
2016-03-17 14:46:21 +02:00
Mykola Golub
b15ff2f419 test: rbd-mirror: compare positions using all fields
Comparing by only entry_tid may give false positives.

Signed-off-by: Mykola Golub <mgolub@mirantis.com>
2016-03-16 23:07:07 +02:00
Mykola Golub
e348a7e4e8 rbd-mirror: use pool/image names in asok commands
Now the commands look similar to rbd cache asok commands.

Signed-off-by: Mykola Golub <mgolub@mirantis.com>
2016-03-16 22:55:00 +02:00
Jason Dillaman
50b53eaf4b qa/workunits/rbd: rbd_mirror was extracting the incorrect image id
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
2016-03-16 10:01:38 -04:00
Jason Dillaman
f2e39888d0 qa/workunits/rbd: use unique logs for each rbd-mirror daemon
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
2016-03-16 10:01:38 -04:00
Mykola Golub
8e41220d34 test: fixup and improvements for rbd-mirror test
Signed-off-by: Mykola Golub <mgolub@mirantis.com>
2016-03-15 10:18:33 +02:00
Mykola Golub
3295253d64 test: add rbd-mirror test script
Signed-off-by: Mykola Golub <mgolub@mirantis.com>
2016-03-11 16:12:00 +02:00