1
0
mirror of https://github.com/MariaDB/server.git synced 2025-12-10 19:44:09 +03:00

Merge r1067:1077 from branches/5.0:

innobase_start_or_create_for_mysql(): Remove unnecessary delay now that
we moved the setting sync_order_checks_on=TRUE to log0recv.c,
to the start of the rollback phase in crash recovery.

Fix assertion failure sync0sync.c line 1239
(the latter ut_error in sync_thread_reset_level())
in crash recovery when UNIV_SYNC_DEBUG is enabled.
This commit is contained in:
heikki
2006-11-28 14:37:05 +00:00
parent e8ad2f5744
commit 0daa938c0c
2 changed files with 6 additions and 11 deletions

View File

@@ -33,6 +33,7 @@ Created 9/20/1997 Heikki Tuuri
#include "btr0cur.h" #include "btr0cur.h"
#include "dict0boot.h" #include "dict0boot.h"
#include "fil0fil.h" #include "fil0fil.h"
#include "sync0sync.h"
#ifdef UNIV_HOTBACKUP #ifdef UNIV_HOTBACKUP
/* This is set to FALSE if the backup was originally taken with the /* This is set to FALSE if the backup was originally taken with the
@@ -2855,6 +2856,11 @@ recv_recovery_from_checkpoint_finish(void)
#ifndef UNIV_LOG_DEBUG #ifndef UNIV_LOG_DEBUG
recv_sys_free(); recv_sys_free();
#endif #endif
#ifdef UNIV_SYNC_DEBUG
/* Switch latching order checks on in sync0sync.c */
sync_order_checks_on = TRUE;
#endif
if (srv_force_recovery < SRV_FORCE_NO_TRX_UNDO) { if (srv_force_recovery < SRV_FORCE_NO_TRX_UNDO) {
/* Rollback the uncommitted transactions which have no user /* Rollback the uncommitted transactions which have no user
session */ session */

View File

@@ -1601,17 +1601,6 @@ innobase_start_or_create_for_mysql(void)
srv_was_started = TRUE; srv_was_started = TRUE;
srv_is_being_started = FALSE; srv_is_being_started = FALSE;
#ifdef UNIV_SYNC_DEBUG
/* Wait a while so that the created threads have time to suspend
themselves before we switch sync debugging on; otherwise a thread may
execute mutex_enter() before the checks are on, and mutex_exit() after
the checks are on, which will cause an assertion failure in sync
debug. */
os_thread_sleep(3000000);
sync_order_checks_on = TRUE;
#endif
if (trx_doublewrite == NULL) { if (trx_doublewrite == NULL) {
/* Create the doublewrite buffer to a new tablespace */ /* Create the doublewrite buffer to a new tablespace */