3 LCONF=${LCONF:-../utils/lconf}
10 if [ "$PORTALS" ]; then
11 portals_opt="--portals=$PORTALS"
14 if [ "$LUSTRE" ]; then
15 lustre_opt="--lustre=$LUSTRE"
18 if [ "$1" = "--force" ]; then
22 if [ "$LDAPURL" ]; then
23 conf_opt="--ldapurl $LDAPURL --config $NAME"
25 if [ ! -f $config -o $mkconfig -nt $config ]; then
26 sh $mkconfig $config || exit 1
31 [ "$NODE" ] && node_opt="--node $NODE"
34 ${LCONF} $portals_opt $lustre_opt $node_opt --cleanup $force \
35 --dump $TMP/debug $conf_opt
37 BUSY=`dmesg | grep -i destruct`
40 mv $TMP/debug $TMP/debug-busy.`date +%s`
43 LEAK_LUSTRE=`dmesg | grep "obd mem.*leaked" | tail -1 | grep -v "leaked: 0"`
44 LEAK_PORTALS=`dmesg | tail -20 | grep "Portals memory leaked"`
45 if [ "$LEAK_LUSTRE" -o "$LEAK_PORTALS" ]; then
46 echo "$LEAK_LUSTRE" 1>&2
47 echo "$LEAK_PORTALS" 1>&2
48 mv $TMP/debug $TMP/debug-leak.`date +%s`