Commit b0febdb6 authored by Jan Lindström's avatar Jan Lindström

MDEV-7084: innodb index stats inadequate using constant innodb_stats_sample_pages

Use traditional statistics estimation by default (innodb-stats-traditional=true).
There could be performance regression for customers if there is a lot of
open table operations.
parent 48f4961a
...@@ -11746,8 +11746,8 @@ static MYSQL_SYSVAR_ULONGLONG(stats_modified_counter, srv_stats_modified_counter ...@@ -11746,8 +11746,8 @@ static MYSQL_SYSVAR_ULONGLONG(stats_modified_counter, srv_stats_modified_counter
static MYSQL_SYSVAR_BOOL(stats_traditional, srv_stats_sample_traditional, static MYSQL_SYSVAR_BOOL(stats_traditional, srv_stats_sample_traditional,
PLUGIN_VAR_RQCMDARG, PLUGIN_VAR_RQCMDARG,
"Enable traditional statistic calculation based on number of configured pages (default false)", "Enable traditional statistic calculation based on number of configured pages (default true)",
NULL, NULL, FALSE); NULL, NULL, TRUE);
static MYSQL_SYSVAR_BOOL(adaptive_hash_index, btr_search_enabled, static MYSQL_SYSVAR_BOOL(adaptive_hash_index, btr_search_enabled,
PLUGIN_VAR_OPCMDARG, PLUGIN_VAR_OPCMDARG,
......
...@@ -754,8 +754,8 @@ static ulint srv_meter_foreground[SRV_MASTER + 1]; ...@@ -754,8 +754,8 @@ static ulint srv_meter_foreground[SRV_MASTER + 1];
UNIV_INTERN unsigned long long srv_stats_modified_counter = 0; UNIV_INTERN unsigned long long srv_stats_modified_counter = 0;
/* Enable traditional statistic calculation based on number of configured /* Enable traditional statistic calculation based on number of configured
pages default false. */ pages default true. */
UNIV_INTERN my_bool srv_stats_sample_traditional = FALSE; UNIV_INTERN my_bool srv_stats_sample_traditional = TRUE;
/* The following values give info about the activity going on in /* The following values give info about the activity going on in
the database. They are protected by the server mutex. The arrays the database. They are protected by the server mutex. The arrays
......
...@@ -13114,8 +13114,8 @@ static MYSQL_SYSVAR_ULONGLONG(stats_modified_counter, srv_stats_modified_counter ...@@ -13114,8 +13114,8 @@ static MYSQL_SYSVAR_ULONGLONG(stats_modified_counter, srv_stats_modified_counter
static MYSQL_SYSVAR_BOOL(stats_traditional, srv_stats_sample_traditional, static MYSQL_SYSVAR_BOOL(stats_traditional, srv_stats_sample_traditional,
PLUGIN_VAR_RQCMDARG, PLUGIN_VAR_RQCMDARG,
"Enable traditional statistic calculation based on number of configured pages (default false)", "Enable traditional statistic calculation based on number of configured pages (default true)",
NULL, NULL, FALSE); NULL, NULL, TRUE);
static MYSQL_SYSVAR_ULINT(stats_auto_update, srv_stats_auto_update, static MYSQL_SYSVAR_ULINT(stats_auto_update, srv_stats_auto_update,
PLUGIN_VAR_RQCMDARG, PLUGIN_VAR_RQCMDARG,
......
...@@ -416,8 +416,8 @@ UNIV_INTERN ulong srv_sys_stats_root_page = 0; ...@@ -416,8 +416,8 @@ UNIV_INTERN ulong srv_sys_stats_root_page = 0;
UNIV_INTERN unsigned long long srv_stats_modified_counter = 0; UNIV_INTERN unsigned long long srv_stats_modified_counter = 0;
/* Enable traditional statistic calculation based on number of configured /* Enable traditional statistic calculation based on number of configured
pages default false. */ pages default true. */
UNIV_INTERN my_bool srv_stats_sample_traditional = FALSE; UNIV_INTERN my_bool srv_stats_sample_traditional = TRUE;
UNIV_INTERN ibool srv_use_doublewrite_buf = TRUE; UNIV_INTERN ibool srv_use_doublewrite_buf = TRUE;
UNIV_INTERN ibool srv_use_atomic_writes = FALSE; UNIV_INTERN ibool srv_use_atomic_writes = FALSE;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment