When nodemap is activated in sanity-sec test_27ab, we need to make
sure the default nodemap grants root access, so that clients and
servers can be stopped and restarted.
Also fix an incorrect call to 'lctl nodemap_add_idmap'.
Test-Parameters: trivial
Fixes:
e3051ad0f1 ("LU-18109 utils: adding nodemap offset capability")
Signed-off-by: Sebastien Buisson <sbuisson@ddn.com>
Change-Id: I0adafae67c7637c616c687590bd01ff12f4d6bf2
Reviewed-on: https://review.whamcloud.com/c/fs/lustre-release/+/58187
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Jian Yu <yujian@whamcloud.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
activedefault=$(do_facet mgs $LCTL get_param -n nodemap.active)
if ((activedefault != 1)); then
+ do_facet mgs $LCTL nodemap_modify --name default \
+ --property trusted --value 1
+ do_facet mgs $LCTL nodemap_modify --name default \
+ --property admin --value 1
do_facet mgs $LCTL nodemap_activate 1
wait_nm_sync active
stack_trap cleanup_active EXIT
error "cannot delete idmap range 500-509:0"
#expected error, invalid secondary range supplied
- do_facet mgs $LCTL nodemap_add --name $nm1 \
+ do_facet mgs $LCTL nodemap_add_idmap --name $nm1 \
--idtype uid --idmap 500-509:200000-200010 &&
error "Invalid range 200000-200010 was supplied"