* the server is updated on-the-fly we will get the new features. */
imp->imp_connect_data.ocd_connect_flags = imp->imp_connect_flags_orig;
imp->imp_msghdr_flags &= ~MSGHDR_AT_SUPPORT;
+ imp->imp_msghdr_flags &= ~MSGHDR_CKSUM_INCOMPAT18;
rc = obd_reconnect(NULL, imp->imp_obd->obd_self_export, obd,
&obd->obd_uuid, &imp->imp_connect_data, NULL);
"after reconnect. We should LBUG right here.\n");
}
- if (lustre_msg_get_last_committed(request->rq_repmsg) <
+ if (lustre_msg_get_last_committed(request->rq_repmsg) > 0 &&
+ lustre_msg_get_last_committed(request->rq_repmsg) <
aa->pcaa_peer_committed) {
CERROR("%s went back in time (transno "LPD64
" was previously committed, server now claims "LPD64
else
imp->imp_msghdr_flags &= ~MSGHDR_AT_SUPPORT;
+ if ((ocd->ocd_connect_flags & OBD_CONNECT_FULL20) &&
+ (imp->imp_msg_magic == LUSTRE_MSG_MAGIC_V2))
+ imp->imp_msghdr_flags |= MSGHDR_CKSUM_INCOMPAT18;
+ else
+ imp->imp_msghdr_flags &= ~MSGHDR_CKSUM_INCOMPAT18;
+
LASSERT((cli->cl_max_pages_per_rpc <= PTLRPC_MAX_BRW_PAGES) &&
(cli->cl_max_pages_per_rpc > 0));
}
CDEBUG(D_WARNING,
"%s: version recovery fails, reconnecting\n",
req->rq_import->imp_obd->obd_name);
- cfs_spin_lock(&req->rq_import->imp_lock);
- req->rq_import->imp_vbr_failed = 0;
- cfs_spin_unlock(&req->rq_import->imp_lock);
} else {
CDEBUG(D_HA, "%s: LAST_REPLAY message error: %d, "
"reconnecting\n",
CDEBUG(D_HA, "evicted from %s@%s; invalidating\n",
obd2cli_tgt(imp->imp_obd),
imp->imp_connection->c_remote_uuid.uuid);
+ /* reset vbr_failed flag upon eviction */
+ cfs_spin_lock(&imp->imp_lock);
+ imp->imp_vbr_failed = 0;
+ cfs_spin_unlock(&imp->imp_lock);
#ifdef __KERNEL__
/* bug 17802: XXX client_disconnect_export vs connect request
RETURN(rc);
}
-static int back_to_sleep(void *unused)
-{
- return 0;
-}
-
int ptlrpc_disconnect_import(struct obd_import *imp, int noclose)
{
struct ptlrpc_request *req;