export GSS_KRB5=false
export GSS_PIPEFS=false
export IDENTITY_UPCALL=default
+
#export PDSH="pdsh -S -Rssh -w"
# eg, assert_env LUSTRE MDSNODES OSTNODES CLIENTS
load_module ../libcfs/libcfs/libcfs
[ "$PTLDEBUG" ] && lctl set_param debug=$PTLDEBUG
[ "$SUBSYSTEM" ] && lctl set_param subsystem_debug=${SUBSYSTEM# }
+ local MODPROBECONF=
[ -f /etc/modprobe.conf ] && MODPROBECONF=/etc/modprobe.conf
- [ -f /etc/modprobe.d/Lustre ] && MODPROBECONF=/etc/modprobe.d/Lustre
- [ -z "$LNETOPTS" -a -n "$MODPROBECONF" ] && \
+ [ ! "$MODPROBECONF" -a -d /etc/modprobe.d ] && MODPROBECONF=/etc/modprobe.d/Lustre
+ [ -z "$LNETOPTS" -a "$MODPROBECONF" ] && \
LNETOPTS=$(awk '/^options lnet/ { print $0}' $MODPROBECONF | sed 's/^options lnet //g')
echo $LNETOPTS | grep -q "accept=all" || LNETOPTS="$LNETOPTS accept=all";
echo "lnet options: '$LNETOPTS'"
echo "$LEAK_LUSTRE" 1>&2
echo "$LEAK_PORTALS" 1>&2
mv $TMP/debug $TMP/debug-leak.`date +%s` || true
- log "Memory leaks detected"
+ echo "Memory leaks detected"
[ -n "$IGNORE_LEAK" ] && { echo "ignoring leaks" && return 0; } || true
return 1
fi
}
formatall() {
+ if [ "$IAMDIR" == "yes" ]; then
+ MDS_MKFS_OPTS="$MDS_MKFS_OPTS --iam-dir"
+ MDSn_MKFS_OPTS="$MDSn_MKFS_OPTS --iam-dir"
+ fi
+
[ "$FSTYPE" ] && FSTYPE_OPT="--backfstype $FSTYPE"
if [ ! -z $SEC ]; then
done
fi
+ # wait a while to allow sptlrpc configuration be propogated to targets,
+ # only needed when mounting new target devices.
+ $GSS && sleep 10
+
[ "$DAEMONFILE" ] && $LCTL debug_daemon start $DAEMONFILE $DAEMONSIZE
mount_client $MOUNT
[ -n "$CLIENTS" ] && zconf_mount_clients $CLIENTS $MOUNT
echo Checking config lustre mounted on $mntpt
local mgshost=$(mount | grep " $mntpt " | awk -F@ '{print $1}')
+ mgshost=$(echo $mgshost | awk -F: '{print $1}')
if [ "$mgshost" != "$mgs_HOST" ]; then
FAIL_ON_ERROR=true \
error "Bad config file: lustre is mounted with mgs $mgshost, but mgs_HOST=$mgs_HOST
fi
}
+# $1 node
+# $2 file
+get_stripe_info() {
+ local tmp_file
+
+ stripe_size=0
+ stripe_count=0
+ stripe_index=0
+ tmp_file=$(mktemp)
+
+ do_facet $1 lfs getstripe -v $2 > $tmp_file
+
+ stripe_size=`awk '$1 ~ /size/ {print $2}' $tmp_file`
+ stripe_count=`awk '$1 ~ /count/ {print $2}' $tmp_file`
+ stripe_index=`awk '/obdidx/ {start = 1; getline; print $1; exit}' $tmp_file`
+ rm -f $tmp_file
+}