In test_27 of sanity-sec, only set fileset on nodemap with
'set_param -P' command. This command will install the fileset info
into all servers including MGS. But we need to wait into
wait_nm_sync() for it to be set.
Test-Parameters: trivial testlist=sanity-sec,sanity-sec,sanity-sec,sanity-sec,sanity-sec,sanity-sec,sanity-sec,sanity-sec,sanity-sec,sanity-sec
Test-Parameters: trivial testlist=sanity-sec,sanity-sec,sanity-sec,sanity-sec,sanity-sec,sanity-sec,sanity-sec,sanity-sec,sanity-sec,sanity-sec
Test-Parameters: trivial testlist=sanity-sec,sanity-sec,sanity-sec,sanity-sec,sanity-sec,sanity-sec,sanity-sec,sanity-sec,sanity-sec,sanity-sec
Signed-off-by: Sebastien Buisson <sbuisson@ddn.com>
Change-Id: I811ca29f5f58385dd5f76a069556865850065e3e
Reviewed-on: https://review.whamcloud.com/23936
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Kit Westneat <kit.westneat@gmail.com>
Reviewed-by: Jian Yu <jian.yu@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
wait_nm_sync() {
local nodemap_name=$1
local key=$2
wait_nm_sync() {
local nodemap_name=$1
local key=$2
local proc_param="${nodemap_name}.${key}"
[ "$nodemap_name" == "active" ] && proc_param="active"
local proc_param="${nodemap_name}.${key}"
[ "$nodemap_name" == "active" ] && proc_param="active"
local mgs_ip=$(host_nids_address $mgs_HOST $NETTYPE | cut -d' ' -f1)
local i
local mgs_ip=$(host_nids_address $mgs_HOST $NETTYPE | cut -d' ' -f1)
local i
- out1=$(do_facet mgs $LCTL get_param nodemap.${proc_param})
- echo "On MGS ${mgs_ip}, ${proc_param} = $out1"
+ if [ -z "$value" ]; then
+ out1=$(do_facet mgs $LCTL get_param nodemap.${proc_param})
+ echo "On MGS ${mgs_ip}, ${proc_param} = $out1"
+ else
+ out1=$value;
+ fi
# wait up to 10 seconds for other servers to sync with mgs
for i in $(seq 1 10); do
# wait up to 10 seconds for other servers to sync with mgs
for i in $(seq 1 10); do
cut -d' ' -f1)
is_sync=true
cut -d' ' -f1)
is_sync=true
- [ $node_ip == $mgs_ip ] && continue
+ if [ -z "$value" ]; then
+ [ $node_ip == $mgs_ip ] && continue
+ fi
out2=$(do_node $node_ip $LCTL get_param \
nodemap.$proc_param 2>/dev/null)
out2=$(do_node $node_ip $LCTL get_param \
nodemap.$proc_param 2>/dev/null)
fileset_test_setup
# add fileset info to nodemap
fileset_test_setup
# add fileset info to nodemap
- do_facet mgs $LCTL set_param nodemap.c0.fileset=/$subdir ||
- error "unable to set fileset info on nodemap c0"
do_facet mgs $LCTL set_param -P nodemap.c0.fileset=/$subdir ||
error "unable to add fileset info to nodemap c0"
do_facet mgs $LCTL set_param -P nodemap.c0.fileset=/$subdir ||
error "unable to add fileset info to nodemap c0"
- wait_nm_sync c0 fileset
+ wait_nm_sync c0 fileset "nodemap.c0.fileset=/$subdir"
# re-mount client
zconf_umount_clients ${clients_arr[0]} $MOUNT ||
# re-mount client
zconf_umount_clients ${clients_arr[0]} $MOUNT ||