Skip to content
Snippets Groups Projects
Commit 11ea9ca2 authored by Robert Read's avatar Robert Read
Browse files

b=2936

Skip closing files for the self_export, and add a test.
parent 1e4392a7
No related branches found
No related tags found
No related merge requests found
......@@ -321,6 +321,9 @@ static int mds_destroy_export(struct obd_export *export)
med = &export->exp_mds_data;
target_destroy_export(export);
if (obd_uuid_equals(&export->exp_client_uuid, &obd->obd_uuid))
GOTO(out, 0);
push_ctxt(&saved, &obd->obd_ctxt, NULL);
/* Close any open files (which may also cause orphan unlinking). */
spin_lock(&med->med_open_lock);
......@@ -350,6 +353,7 @@ static int mds_destroy_export(struct obd_export *export)
spin_unlock(&med->med_open_lock);
pop_ctxt(&saved, &obd->obd_ctxt, NULL);
out:
mds_client_free(export, !(export->exp_flags & OBD_OPT_FAILOVER));
RETURN(rc);
......
......@@ -646,4 +646,29 @@ test_16() {
}
run_test 16 "verify that lustre will correct the mode of OBJECTS/LOGS/PENDING"
test_17() {
TMPMTPT="/mnt/conf17"
if [ ! -f "$MDSDEV" ]; then
echo "no $MDSDEV existing, so mount Lustre to create one"
start_ost
start_mds
mount_client $MOUNT
check_mount || return 41
cleanup || return $?
fi
echo "Remove mds config log"
[ -d $TMPMTPT ] || mkdir -p $TMPMTPT
mount -o loop -t ext3 $MDSDEV $TMPMTPT || return $?
rm -f $TMPMTPT/LOGS/mds_svc || return $?
umount $TMPMTPT || return $?
start_ost
start mds $MDSLCONFARGS && return 42
cleanup || return $?
}
run_test 17 "Verify failed mds_postsetup won't fail assertion (2936)"
equals_msg "Done"
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment