sanity-sec test_15 should not inherit trusted and admin properties for
newly created nodemaps from the default nodemap. Instead, it must
explicitly set both to 0, as the whole point is to exercise id
mappings.
Test-Parameters: trivial testlist=sanity-sec
Test-Parameters: clientdistro=ubuntu2004 testlist=sanity-sec
Change-Id: Ie80a10528268024d59cd079949620ebd1a836395
Signed-off-by: Sebastien Buisson <sbuisson@ddn.com>
Reviewed-on: https://review.whamcloud.com/45100
Tested-by: jenkins <devops@whamcloud.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
rc=$?
[[ $rc != 0 ]] && error "nodemap_add failed with $rc" && return 1
+ for (( i = 0; i < NODEMAP_COUNT; i++ )); do
+ local csum=${HOSTNAME_CHECKSUM}_${i}
+
+ if ! do_facet mgs $LCTL nodemap_modify --name $csum \
+ --property admin --value 0; then
+ rc=$((rc + 1))
+ fi
+ if ! do_facet mgs $LCTL nodemap_modify --name $csum \
+ --property trusted --value 0; then
+ rc=$((rc + 1))
+ fi
+ done
+ [[ $rc != 0 ]] && error "nodemap_modify failed with $rc" && return 1
+
rc=0
for ((i = 0; i < NODEMAP_COUNT; i++)); do
if ! add_range ${HOSTNAME_CHECKSUM}_${i} $i; then
}
rc = nodemap_cmd(LCFG_NODEMAP_TEST_ID, &rawbuf, sizeof(rawbuf),
- argv[0], nidstr, typestr, idstr);
+ argv[0], nidstr, typestr, idstr, NULL);
if (rc == 0)
printf("%s\n", (char *)rawbuf);