struct lov_desc mds_lov_desc;
__u32 mds_id;
- unsigned int mds_lov_objids_dirty:1;
struct file *mds_lov_objid_filp;
/* protect update vs free in lov_add_target */
struct rw_semaphore mds_lov_objids_sem;
struct semaphore mds_qonoff_sem;
struct semaphore mds_health_sem;
unsigned long mds_lov_objids_valid:1,
+ mds_lov_objids_dirty:1,
mds_fl_user_xattr:1,
mds_fl_acl:1,
- mds_evict_ost_nids:1;
-
+ mds_evict_ost_nids:1,
+ mds_fl_cfglog:1,
+ mds_fl_synced:1;
struct upcall_cache *mds_identity_cache;
struct upcall_cache *mds_rmtacl_cache;
rc = fsfilt_read_record(obd, mds->mds_lov_objid_filp, ids, size, &off);
if (rc < 0) {
- OBD_FREE(ids, size);
+ OBD_FREE(ids, size);
CERROR("Error reading objids %d\n", rc);
GOTO(out, rc);
}
}
+/* Collect the preconditions we need to allow client connects */
+static void mds_allow_cli(struct obd_device *obd, unsigned int flag)
+{
+ if (flag & CONFIG_LOG)
+ obd->u.mds.mds_fl_cfglog = 1;
+ if (flag & CONFIG_SYNC)
+ obd->u.mds.mds_fl_synced = 1;
+ if (obd->u.mds.mds_fl_cfglog /* bz11778: && obd->u.mds.mds_fl_synced */)
+ /* Open for clients */
+ obd->obd_no_conn = 0;
+}
+
struct mds_lov_sync_info {
struct obd_device *mlsi_obd; /* the lov device to sync */
struct obd_device *mlsi_watched; /* target osc */
case OBD_NOTIFY_SYNC_NONBLOCK:
break;
case OBD_NOTIFY_CONFIG:
- /* Open for clients */
- obd->obd_no_conn = 0;
+ mds_allow_cli(obd, (unsigned int)data);
default:
RETURN(0);
}
obd->u.mds.mds_lov_desc.ld_tgt_count,
&watched->u.cli.cl_target_uuid);
mutex_up(&obd->obd_dev_sem);
+ mds_allow_cli(obd, CONFIG_SYNC);
RETURN(rc);
}
{
struct lustre_sb_info *lsi = s2lsi(sb);
struct obd_device *obd;
- char *niduuid, *ptr = 0;
- int i, rc = 0, len;
+ char *niduuid = 0, *ptr = 0;
+ int i, rc = 0, len = 0;
ENTRY;
if (!lsi)
test_5e() {
start_ost
start_mds
- # give MDS a chance to connect to OSTs (bz 10476)
- sleep 5
#define OBD_FAIL_PTLRPC_DELAY_SEND 0x506
do_facet client "sysctl -w lustre.fail_loc=0x80000506"
echo Client mount with a running ost
start_ost
mount_client $MOUNT
- sleep 5 #bz10476
check_mount || return 41
pass