From: Ilya Dryomov Date: Fri, 13 May 2016 13:05:53 +0000 (+0200) Subject: qa: rbd/concurrent.sh: suppress rbd map output X-Git-Tag: v11.0.0~561^2~1 X-Git-Url: http://git.apps.os.sepia.ceph.com/?a=commitdiff_plain;h=a7d4189587e343a581660f1a118f6667c26e5bd4;p=ceph-ci.git qa: rbd/concurrent.sh: suppress rbd map output rbd_map_image() echoes the id of the image and is used in command substitution: id=$(rbd_map_image "${image}") Output from rbd map isn't consumed and clobbers the return. Signed-off-by: Ilya Dryomov --- diff --git a/qa/workunits/rbd/concurrent.sh b/qa/workunits/rbd/concurrent.sh index f3373b5fff2..e2fb7974724 100755 --- a/qa/workunits/rbd/concurrent.sh +++ b/qa/workunits/rbd/concurrent.sh @@ -257,7 +257,8 @@ function rbd_map_image() { local image="$1" local id - sudo rbd map "${image}" --user "${CEPH_ID}" ${SECRET_ARGS} + sudo rbd map "${image}" --user "${CEPH_ID}" ${SECRET_ARGS} \ + > /dev/null 2>&1 id=$(rbd_image_id "${image}") echo "${id}" @@ -317,7 +318,7 @@ function rbd_unmap_image() { [ $# -eq 1 ] || exit 99 local id="$1" - sudo rbd unmap "/dev/rbd${id}" > /dev/null 2>&1 + sudo rbd unmap "/dev/rbd${id}" } function rbd_destroy_image() {