diff options
author | Michael Cahill <michael.cahill@mongodb.com> | 2015-09-18 17:17:34 +1000 |
---|---|---|
committer | Michael Cahill <michael.cahill@mongodb.com> | 2015-09-18 17:17:34 +1000 |
commit | 881f00984ce2692b81154d5ea3d5fb589b484c70 (patch) | |
tree | 5a9b5aeaf3c6023457dd08dbb9e26150b45a7f14 /src/third_party/wiredtiger/src/txn/txn_log.c | |
parent | 250b05a6184b559dc5c2e3ee53c3183a70f47fd2 (diff) | |
download | mongo-881f00984ce2692b81154d5ea3d5fb589b484c70.tar.gz |
Import wiredtiger-wiredtiger-2.6.1-1119-g16e3e48.tar.gz from wiredtiger branch mongodb-3.2
Diffstat (limited to 'src/third_party/wiredtiger/src/txn/txn_log.c')
-rw-r--r-- | src/third_party/wiredtiger/src/txn/txn_log.c | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/src/third_party/wiredtiger/src/txn/txn_log.c b/src/third_party/wiredtiger/src/txn/txn_log.c index a63720d736f..7a53fb65b1f 100644 --- a/src/third_party/wiredtiger/src/txn/txn_log.c +++ b/src/third_party/wiredtiger/src/txn/txn_log.c @@ -307,7 +307,7 @@ __wt_txn_checkpoint_log( switch (flags) { case WT_TXN_LOG_CKPT_PREPARE: txn->full_ckpt = 1; - WT_ERR(__wt_log_ckpt_lsn(session, ckpt_lsn)); + WT_ERR(__wt_log_flush_lsn(session, ckpt_lsn, 1)); /* * We need to make sure that the log records in the checkpoint * LSN are on disk. In particular to make sure that the @@ -336,7 +336,7 @@ __wt_txn_checkpoint_log( txn->ckpt_nsnapshot = 0; WT_CLEAR(empty); ckpt_snapshot = ∅ - WT_ERR(__wt_log_ckpt_lsn(session, ckpt_lsn)); + WT_ERR(__wt_log_flush_lsn(session, ckpt_lsn, 1)); } else ckpt_snapshot = txn->ckpt_snapshot; @@ -358,9 +358,13 @@ __wt_txn_checkpoint_log( /* * If this full checkpoint completed successfully and there is * no hot backup in progress, tell the logging subsystem the - * checkpoint LSN so that it can archive. + * checkpoint LSN so that it can archive. Do not update the + * logging checkpoint LSN if this is during a clean connection + * close, only during a full checkpoint. A clean close may not + * update any metadata LSN and we do not want to archive in + * that case. */ - if (!S2C(session)->hot_backup) + if (!S2C(session)->hot_backup && txn->full_ckpt) WT_ERR(__wt_log_ckpt(session, ckpt_lsn)); /* FALLTHROUGH */ |