t32_check() {
[ "$CLIENTONLY" ] && skip "Client-only testing"
+ check_versions || skip "do not upgrade with mismatched client/server"
+
local node=$(facet_active_host $SINGLEMDS)
local r="do_node $node"
fi
$r $MOUNT_CMD -o $mopts $mdt_dev $tmp/mnt/mdt
$r $LCTL replace_nids $fsname-OST0000 $ostnid || {
+ $r $LCTL dl
error_noexit "replace_nids $fsname-OST0000 $ostnid failed"
return 1
}
if $ost2_is_available; then
$r $LCTL replace_nids $fsname-OST0001 $ostnid || {
+ $r $LCTL dl
error_noexit "replace_nids $fsname-OST0001 $ostnid failed"
return 1
}
fi
$r $LCTL replace_nids $fsname-MDT0000 $nid || {
+ $r $LCTL dl
error_noexit "replace_nids $fsname-MDT0000 $nid failed"
return 1
}
if $mdt2_is_available; then
$r $LCTL replace_nids $fsname-MDT0001 $nid || {
+ $r $LCTL dl
error_noexit "replace_nids $fsname-MDT0001 $nid failed"
return 1
}
}
check_versions () {
- [ "$(lustre_version_code client)" = "$(lustre_version_code $SINGLEMDS)" -a \
- "$(lustre_version_code client)" = "$(lustre_version_code ost1)" ]
+ # this should already have been called, but just in case
+ [[ -n "$CLIENT_VERSION" && -n "$MDS1_VERSION" && -n "$OST1_VERSION" ]]||
+ get_lustre_env
+
+ echo "client=$CLIENT_VERSION MDS=$MDS1_VERSION OSS=$OST1_VERSION"
+
+ [[ -n "$CLIENT_VERSION" && -n "$MDS1_VERSION" && -n "$OST1_VERSION" ]]||
+ error "unable to determine node versions"
+
+ (( "$CLIENT_VERSION" == "$MDS1_VERSION" &&
+ "$CLIENT_VERSION" == "$OST1_VERSION"))
}
get_node_count() {