Fixes for BUG#10039 "MEMORY engine is reported as HEAP",

BUG#9738 "SHOW VARIABLES still displays the deprecated 'log_update' in 5.0",
BUG#9542 "MySQL dies with signal 11 when it is using non-existent location of binary logs"
parent a0c3aed7
...@@ -210,7 +210,7 @@ drop table if exists t1; ...@@ -210,7 +210,7 @@ drop table if exists t1;
SET SESSION storage_engine="heap"; SET SESSION storage_engine="heap";
SELECT @@storage_engine; SELECT @@storage_engine;
@@storage_engine @@storage_engine
HEAP MEMORY
CREATE TABLE t1 (a int not null); CREATE TABLE t1 (a int not null);
show create table t1; show create table t1;
Table Create Table Table Create Table
...@@ -222,7 +222,7 @@ SET SESSION storage_engine="gemini"; ...@@ -222,7 +222,7 @@ SET SESSION storage_engine="gemini";
ERROR 42000: Unknown table engine 'gemini' ERROR 42000: Unknown table engine 'gemini'
SELECT @@storage_engine; SELECT @@storage_engine;
@@storage_engine @@storage_engine
HEAP MEMORY
CREATE TABLE t1 (a int not null); CREATE TABLE t1 (a int not null);
show create table t1; show create table t1;
Table Create Table Table Create Table
...@@ -371,7 +371,7 @@ drop database mysqltest; ...@@ -371,7 +371,7 @@ drop database mysqltest;
SET SESSION storage_engine="heap"; SET SESSION storage_engine="heap";
SELECT @@storage_engine; SELECT @@storage_engine;
@@storage_engine @@storage_engine
HEAP MEMORY
CREATE TABLE t1 (a int not null); CREATE TABLE t1 (a int not null);
show create table t1; show create table t1;
Table Create Table Table Create Table
...@@ -383,7 +383,7 @@ SET SESSION storage_engine="gemini"; ...@@ -383,7 +383,7 @@ SET SESSION storage_engine="gemini";
ERROR 42000: Unknown table engine 'gemini' ERROR 42000: Unknown table engine 'gemini'
SELECT @@storage_engine; SELECT @@storage_engine;
@@storage_engine @@storage_engine
HEAP MEMORY
CREATE TABLE t1 (a int not null); CREATE TABLE t1 (a int not null);
show create table t1; show create table t1;
Table Create Table Table Create Table
......
...@@ -322,8 +322,8 @@ prepare stmt4 from ' show storage engines '; ...@@ -322,8 +322,8 @@ prepare stmt4 from ' show storage engines ';
execute stmt4; execute stmt4;
Engine Support Comment Engine Support Comment
MyISAM YES/NO Default engine as of MySQL 3.23 with great performance MyISAM YES/NO Default engine as of MySQL 3.23 with great performance
HEAP YES/NO Alias for MEMORY
MEMORY YES/NO Hash based, stored in memory, useful for temporary tables MEMORY YES/NO Hash based, stored in memory, useful for temporary tables
HEAP YES/NO Alias for MEMORY
MERGE YES/NO Collection of identical MyISAM tables MERGE YES/NO Collection of identical MyISAM tables
MRG_MYISAM YES/NO Alias for MERGE MRG_MYISAM YES/NO Alias for MERGE
ISAM YES/NO Obsolete storage engine, now replaced by MyISAM ISAM YES/NO Obsolete storage engine, now replaced by MyISAM
......
...@@ -148,7 +148,7 @@ timed_mutexes OFF ...@@ -148,7 +148,7 @@ timed_mutexes OFF
set storage_engine=MYISAM, storage_engine="HEAP", global storage_engine="MERGE"; set storage_engine=MYISAM, storage_engine="HEAP", global storage_engine="MERGE";
show local variables like 'storage_engine'; show local variables like 'storage_engine';
Variable_name Value Variable_name Value
storage_engine HEAP storage_engine MEMORY
show global variables like 'storage_engine'; show global variables like 'storage_engine';
Variable_name Value Variable_name Value
storage_engine MERGE storage_engine MERGE
...@@ -254,7 +254,7 @@ set storage_engine=MERGE, big_tables=2; ...@@ -254,7 +254,7 @@ set storage_engine=MERGE, big_tables=2;
ERROR 42000: Variable 'big_tables' can't be set to the value of '2' ERROR 42000: Variable 'big_tables' can't be set to the value of '2'
show local variables like 'storage_engine'; show local variables like 'storage_engine';
Variable_name Value Variable_name Value
storage_engine HEAP storage_engine MEMORY
set SESSION query_cache_size=10000; set SESSION query_cache_size=10000;
ERROR HY000: Variable 'query_cache_size' is a GLOBAL variable and should be set with SET GLOBAL ERROR HY000: Variable 'query_cache_size' is a GLOBAL variable and should be set with SET GLOBAL
set GLOBAL storage_engine=DEFAULT; set GLOBAL storage_engine=DEFAULT;
......
...@@ -70,10 +70,10 @@ struct show_table_type_st sys_table_types[]= ...@@ -70,10 +70,10 @@ struct show_table_type_st sys_table_types[]=
{ {
{"MyISAM", &have_yes, {"MyISAM", &have_yes,
"Default engine as of MySQL 3.23 with great performance", DB_TYPE_MYISAM}, "Default engine as of MySQL 3.23 with great performance", DB_TYPE_MYISAM},
{"HEAP", &have_yes,
"Alias for MEMORY", DB_TYPE_HEAP},
{"MEMORY", &have_yes, {"MEMORY", &have_yes,
"Hash based, stored in memory, useful for temporary tables", DB_TYPE_HEAP}, "Hash based, stored in memory, useful for temporary tables", DB_TYPE_HEAP},
{"HEAP", &have_yes,
"Alias for MEMORY", DB_TYPE_HEAP},
{"MERGE", &have_yes, {"MERGE", &have_yes,
"Collection of identical MyISAM tables", DB_TYPE_MRG_MYISAM}, "Collection of identical MyISAM tables", DB_TYPE_MRG_MYISAM},
{"MRG_MYISAM",&have_yes, {"MRG_MYISAM",&have_yes,
......
...@@ -2857,6 +2857,13 @@ int TC_LOG_BINLOG::open(const char *opt_name) ...@@ -2857,6 +2857,13 @@ int TC_LOG_BINLOG::open(const char *opt_name)
pthread_mutex_init(&LOCK_prep_xids, MY_MUTEX_INIT_FAST); pthread_mutex_init(&LOCK_prep_xids, MY_MUTEX_INIT_FAST);
pthread_cond_init (&COND_prep_xids, 0); pthread_cond_init (&COND_prep_xids, 0);
if (!my_b_inited(&index_file))
{
/* There was a failure to open the index file, can't open the binlog */
cleanup();
return 1;
}
if (using_heuristic_recover()) if (using_heuristic_recover())
{ {
/* generate a new binlog to mask a corrupted one */ /* generate a new binlog to mask a corrupted one */
......
...@@ -847,7 +847,6 @@ struct show_var_st init_vars[]= { ...@@ -847,7 +847,6 @@ struct show_var_st init_vars[]= {
{"log_slave_updates", (char*) &opt_log_slave_updates, SHOW_MY_BOOL}, {"log_slave_updates", (char*) &opt_log_slave_updates, SHOW_MY_BOOL},
#endif #endif
{"log_slow_queries", (char*) &opt_slow_log, SHOW_BOOL}, {"log_slow_queries", (char*) &opt_slow_log, SHOW_BOOL},
{"log_update", (char*) &opt_update_log, SHOW_BOOL},
{sys_log_warnings.name, (char*) &sys_log_warnings, SHOW_SYS}, {sys_log_warnings.name, (char*) &sys_log_warnings, SHOW_SYS},
{sys_long_query_time.name, (char*) &sys_long_query_time, SHOW_SYS}, {sys_long_query_time.name, (char*) &sys_long_query_time, SHOW_SYS},
{sys_low_priority_updates.name, (char*) &sys_low_priority_updates, SHOW_SYS}, {sys_low_priority_updates.name, (char*) &sys_low_priority_updates, SHOW_SYS},
......
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