Initialize rollback segment header of

Call trx_sys_create_rsegs were:

About innodb_undo_logs explain the parameters and innodb_rollback_segments parameters, their role is to set the number of rollback segment, the paper 128, for example.

The comments and the code is already eliminated innodb_undo_logs parameter should be replaced with innodb_rollback_segments.
These two parameters and the default is 128 TRX_SYS_N_RSEGS fact, do not set. This article also discussed with 128.

Parameters innodb_rollback_segments

static MYSQL_SYSVAR_ULONG(rollback_segments, srv_rollback_segments,
PLUGIN_VAR_OPCMDARG,
"Number of rollback segments to use for storing undo logs.",
NULL, NULL,
TRX_SYS_N_RSEGS, /* Default setting */
1, /* Minimum value */
TRX_SYS_N_RSEGS, 0); /* Maximum value */
参数 innodb_undo_logs

static MYSQL_SYSVAR_ULONG(undo_logs, srv_undo_logs,
PLUGIN_VAR_OPCMDARG,
"Number of rollback segments to use for storing undo logs. (deprecated)",
NULL, innodb_undo_logs_update,
TRX_SYS_N_RSEGS, /* Default setting */
1, /* Minimum value */
TRX_SYS_N_RSEGS, 0); /* Maximum value */
TRX_SYS_N_RSEGS 就是128

The following are notes and code

/* Deprecate innodb_undo_logs. But still use it if it is set to
non-default and innodb_rollback_segments is default. */

if (srv_undo_logs < TRX_SYS_N_RSEGS) {
ib::warn() << deprecated_undo_logs;
if (srv_rollback_segments == TRX_SYS_N_RSEGS) {
srv_rollback_segments = srv_undo_logs;
}
}

Guess you like

Origin www.cnblogs.com/liyanyan665/p/11311293.html