From a52445e3c8ba80fa211c603a3871ca44b3a63516 Mon Sep 17 00:00:00 2001 From: Kefu Chai Date: Wed, 7 Jun 2017 09:32:19 +0800 Subject: [PATCH] qa/workunits/ceph-helpers.sh: use syntax understood by jq 1.3 trusty still ships jq 1.3 which does not offer "first". see https://stedolan.github.io/jq/manual/v1.3/ . Signed-off-by: Kefu Chai --- qa/workunits/ceph-helpers.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/qa/workunits/ceph-helpers.sh b/qa/workunits/ceph-helpers.sh index d8f69604145d..62d0f810e470 100755 --- a/qa/workunits/ceph-helpers.sh +++ b/qa/workunits/ceph-helpers.sh @@ -967,7 +967,7 @@ function get_not_primary() { local primary=$(get_primary $poolname $objectname) ceph --format json osd map $poolname $objectname 2>/dev/null | \ - jq ".acting | map(select (. != $primary)) | first" + jq ".acting | map(select (. != $primary)) | .[0]" } function test_get_not_primary() { -- 2.47.3