From: Sage Weil Date: Wed, 30 Jan 2013 09:06:03 +0000 (-0800) Subject: qa: add test for rbd map and snapshots X-Git-Tag: v0.57~76 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=c782d2ac531cbb7650968e62f0b24e6136a64359;p=ceph.git qa: add test for rbd map and snapshots This tests for the behavior reported in #3964. It passes on the current code, but fails on 3.2 in squeeze (and 32-bit?). Signed-off-by: Sage Weil --- diff --git a/qa/workunits/rbd/map-snapshot-io.sh b/qa/workunits/rbd/map-snapshot-io.sh new file mode 100644 index 000000000000..6edcd4db723b --- /dev/null +++ b/qa/workunits/rbd/map-snapshot-io.sh @@ -0,0 +1,15 @@ +#!/bin/sh +set -e + +# http://tracker.ceph.com/issues/3964 + +rbd create image -s 100 +rbd map image +udevadm settle # note: newer versions of rbd do this for you. +dd if=/dev/zero of=/dev/rbd/rbd/image oflag=direct count=10 +rbd snap create image@s1 +dd if=/dev/zero of=/dev/rbd/rbd/image oflag=direct count=10 # used to fail +rbd snap rm image@s1 +dd if=/dev/zero of=/dev/rbd/rbd/image oflag=direct count=10 + +echo OK