Commit 781658d6 authored by tnurnberg@maint1.mysql.com's avatar tnurnberg@maint1.mysql.com

Merge tnurnberg@bk-internal.mysql.com:/home/bk/mysql-5.1-new-maint

into  maint1.mysql.com:/data/localhome/tnurnberg/mysql-5.1-maint-i51
parents c4005628 d1e1ea2c
...@@ -1295,24 +1295,16 @@ insert into t2 (a) select b from t1; ...@@ -1295,24 +1295,16 @@ insert into t2 (a) select b from t1;
insert into t1 (a) select b from t2; insert into t1 (a) select b from t2;
insert into t2 (a) select b from t1; insert into t2 (a) select b from t1;
insert into t1 (a) select b from t2; insert into t1 (a) select b from t2;
insert into t2 (a) select b from t1;
insert into t1 (a) select b from t2;
insert into t2 (a) select b from t1;
insert into t1 (a) select b from t2;
insert into t2 (a) select b from t1;
insert into t1 (a) select b from t2;
insert into t2 (a) select b from t1;
insert into t1 (a) select b from t2;
select count(*) from t1; select count(*) from t1;
count(*) count(*)
29267 623
explain select * from t1 where c between 1 and 2500; explain select * from t1 where c between 1 and 2500;
id select_type table type possible_keys key key_len ref rows Extra id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE t1 range c c 5 NULL # Using where 1 SIMPLE t1 range c c 5 NULL # Using where
update t1 set c=a; update t1 set c=a;
explain select * from t1 where c between 1 and 2500; explain select * from t1 where c between 1 and 2500;
id select_type table type possible_keys key key_len ref rows Extra id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE t1 range c c 5 NULL # Using where 1 SIMPLE t1 ALL c NULL NULL NULL # Using where
drop table t1,t2; drop table t1,t2;
create table t1 (id int primary key auto_increment, fk int, index index_fk (fk)) engine=innodb; create table t1 (id int primary key auto_increment, fk int, index index_fk (fk)) engine=innodb;
insert into t1 (id) values (null),(null),(null),(null),(null); insert into t1 (id) values (null),(null),(null),(null),(null);
...@@ -1786,10 +1778,10 @@ Variable_name Value ...@@ -1786,10 +1778,10 @@ Variable_name Value
Innodb_rows_deleted 2070 Innodb_rows_deleted 2070
show status like "Innodb_rows_inserted"; show status like "Innodb_rows_inserted";
Variable_name Value Variable_name Value
Innodb_rows_inserted 31727 Innodb_rows_inserted 3083
show status like "Innodb_rows_updated"; show status like "Innodb_rows_updated";
Variable_name Value Variable_name Value
Innodb_rows_updated 29530 Innodb_rows_updated 886
show status like "Innodb_row_lock_waits"; show status like "Innodb_row_lock_waits";
Variable_name Value Variable_name Value
Innodb_row_lock_waits 0 Innodb_row_lock_waits 0
......
...@@ -1083,12 +1083,12 @@ partition by range (a) ...@@ -1083,12 +1083,12 @@ partition by range (a)
subpartition by hash (a) subpartition by hash (a)
(partition p0 VALUES LESS THAN (1) DATA DIRECTORY = 'hello/master-data/tmpdata' INDEX DIRECTORY = 'hello/master-data/tmpinx' (partition p0 VALUES LESS THAN (1) DATA DIRECTORY = 'hello/master-data/tmpdata' INDEX DIRECTORY = 'hello/master-data/tmpinx'
(SUBPARTITION subpart00, SUBPARTITION subpart01)); (SUBPARTITION subpart00, SUBPARTITION subpart01));
hello/master-data/test/t1.frm
hello/master-data/test/t1.par
hello/master-data/test/t1#P#p0#SP#subpart00.MYD hello/master-data/test/t1#P#p0#SP#subpart00.MYD
hello/master-data/test/t1#P#p0#SP#subpart00.MYI hello/master-data/test/t1#P#p0#SP#subpart00.MYI
hello/master-data/test/t1#P#p0#SP#subpart01.MYD hello/master-data/test/t1#P#p0#SP#subpart01.MYD
hello/master-data/test/t1#P#p0#SP#subpart01.MYI hello/master-data/test/t1#P#p0#SP#subpart01.MYI
hello/master-data/test/t1.frm
hello/master-data/test/t1.par
hello/master-data/tmpdata/t1#P#p0#SP#subpart00.MYD hello/master-data/tmpdata/t1#P#p0#SP#subpart00.MYD
hello/master-data/tmpdata/t1#P#p0#SP#subpart01.MYD hello/master-data/tmpdata/t1#P#p0#SP#subpart01.MYD
hello/master-data/tmpinx/t1#P#p0#SP#subpart00.MYI hello/master-data/tmpinx/t1#P#p0#SP#subpart00.MYI
...@@ -1098,6 +1098,8 @@ ALTER TABLE t1 REORGANIZE PARTITION p0 INTO ...@@ -1098,6 +1098,8 @@ ALTER TABLE t1 REORGANIZE PARTITION p0 INTO
(SUBPARTITION subpart10, SUBPARTITION subpart11), (SUBPARTITION subpart10, SUBPARTITION subpart11),
partition p2 VALUES LESS THAN (2) DATA DIRECTORY = 'hello/master-data/tmpdata' INDEX DIRECTORY = 'hello/master-data/tmpinx' partition p2 VALUES LESS THAN (2) DATA DIRECTORY = 'hello/master-data/tmpdata' INDEX DIRECTORY = 'hello/master-data/tmpinx'
(SUBPARTITION subpart20, SUBPARTITION subpart21)); (SUBPARTITION subpart20, SUBPARTITION subpart21));
hello/master-data/test/t1.frm
hello/master-data/test/t1.par
hello/master-data/test/t1#P#p1#SP#subpart10.MYD hello/master-data/test/t1#P#p1#SP#subpart10.MYD
hello/master-data/test/t1#P#p1#SP#subpart10.MYI hello/master-data/test/t1#P#p1#SP#subpart10.MYI
hello/master-data/test/t1#P#p1#SP#subpart11.MYD hello/master-data/test/t1#P#p1#SP#subpart11.MYD
...@@ -1106,8 +1108,6 @@ hello/master-data/test/t1#P#p2#SP#subpart20.MYD ...@@ -1106,8 +1108,6 @@ hello/master-data/test/t1#P#p2#SP#subpart20.MYD
hello/master-data/test/t1#P#p2#SP#subpart20.MYI hello/master-data/test/t1#P#p2#SP#subpart20.MYI
hello/master-data/test/t1#P#p2#SP#subpart21.MYD hello/master-data/test/t1#P#p2#SP#subpart21.MYD
hello/master-data/test/t1#P#p2#SP#subpart21.MYI hello/master-data/test/t1#P#p2#SP#subpart21.MYI
hello/master-data/test/t1.frm
hello/master-data/test/t1.par
hello/master-data/tmpdata/t1#P#p1#SP#subpart10.MYD hello/master-data/tmpdata/t1#P#p1#SP#subpart10.MYD
hello/master-data/tmpdata/t1#P#p1#SP#subpart11.MYD hello/master-data/tmpdata/t1#P#p1#SP#subpart11.MYD
hello/master-data/tmpdata/t1#P#p2#SP#subpart20.MYD hello/master-data/tmpdata/t1#P#p2#SP#subpart20.MYD
......
...@@ -7,12 +7,12 @@ t1 CREATE TABLE `t1` ( ...@@ -7,12 +7,12 @@ t1 CREATE TABLE `t1` (
`f_date` date DEFAULT NULL, `f_date` date DEFAULT NULL,
`f_varchar` varchar(30) DEFAULT NULL `f_varchar` varchar(30) DEFAULT NULL
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (CAST(YEAR(f_date) AS SIGNED INTEGER)) PARTITIONS 2 */ ) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (CAST(YEAR(f_date) AS SIGNED INTEGER)) PARTITIONS 2 */
hello/master-data/test/t1.frm
hello/master-data/test/t1.par
hello/master-data/test/t1#P#p0.MYD hello/master-data/test/t1#P#p0.MYD
hello/master-data/test/t1#P#p0.MYI hello/master-data/test/t1#P#p0.MYI
hello/master-data/test/t1#P#p1.MYD hello/master-data/test/t1#P#p1.MYD
hello/master-data/test/t1#P#p1.MYI hello/master-data/test/t1#P#p1.MYI
hello/master-data/test/t1.frm
hello/master-data/test/t1.par
ALTER TABLE t1 COALESCE PARTITION 1; ALTER TABLE t1 COALESCE PARTITION 1;
SHOW CREATE TABLE t1; SHOW CREATE TABLE t1;
Table Create Table Table Create Table
...@@ -20,10 +20,10 @@ t1 CREATE TABLE `t1` ( ...@@ -20,10 +20,10 @@ t1 CREATE TABLE `t1` (
`f_date` date DEFAULT NULL, `f_date` date DEFAULT NULL,
`f_varchar` varchar(30) DEFAULT NULL `f_varchar` varchar(30) DEFAULT NULL
) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (CAST(YEAR(f_date) AS SIGNED INTEGER)) PARTITIONS 1 */ ) ENGINE=MyISAM DEFAULT CHARSET=latin1 /*!50100 PARTITION BY HASH (CAST(YEAR(f_date) AS SIGNED INTEGER)) PARTITIONS 1 */
hello/master-data/test/t1#P#p0.MYD
hello/master-data/test/t1#P#p0.MYI
hello/master-data/test/t1.frm hello/master-data/test/t1.frm
hello/master-data/test/t1.par hello/master-data/test/t1.par
hello/master-data/test/t1#P#p0.MYD
hello/master-data/test/t1#P#p0.MYI
drop table t1; drop table t1;
create table t1 (a int) create table t1 (a int)
partition by list (a) partition by list (a)
......
...@@ -45,3 +45,4 @@ rpl_truncate_7ndb : BUG#21298 2006-07-27 msvensson ...@@ -45,3 +45,4 @@ rpl_truncate_7ndb : BUG#21298 2006-07-27 msvensson
crash_commit_before : 2006-08-02 msvensson crash_commit_before : 2006-08-02 msvensson
rpl_ndb_dd_advance : BUG#18679 2006-07-28 jimw (Test fails randomly) rpl_ndb_dd_advance : BUG#18679 2006-07-28 jimw (Test fails randomly)
federated_transactions : Need to be re-enabled once Patrick's merge is complete federated_transactions : Need to be re-enabled once Patrick's merge is complete
partition : BUG#21658 2006-08-17 azundris fails w/ --ps-protocol
...@@ -904,14 +904,6 @@ insert into t2 (a) select b from t1; ...@@ -904,14 +904,6 @@ insert into t2 (a) select b from t1;
insert into t1 (a) select b from t2; insert into t1 (a) select b from t2;
insert into t2 (a) select b from t1; insert into t2 (a) select b from t1;
insert into t1 (a) select b from t2; insert into t1 (a) select b from t2;
insert into t2 (a) select b from t1;
insert into t1 (a) select b from t2;
insert into t2 (a) select b from t1;
insert into t1 (a) select b from t2;
insert into t2 (a) select b from t1;
insert into t1 (a) select b from t2;
insert into t2 (a) select b from t1;
insert into t1 (a) select b from t2;
select count(*) from t1; select count(*) from t1;
--replace_column 9 # --replace_column 9 #
explain select * from t1 where c between 1 and 2500; explain select * from t1 where c between 1 and 2500;
......
This diff is collapsed.
...@@ -77,8 +77,7 @@ EXTRA_DIST = include/btr0btr.h include/btr0btr.ic include/btr0cur.h include/btr ...@@ -77,8 +77,7 @@ EXTRA_DIST = include/btr0btr.h include/btr0btr.ic include/btr0cur.h include/btr
include/ut0byte.h include/ut0byte.ic include/ut0dbg.h include/ut0lst.h \ include/ut0byte.h include/ut0byte.ic include/ut0dbg.h include/ut0lst.h \
include/ut0mem.h include/ut0mem.ic include/ut0rnd.h include/ut0rnd.ic \ include/ut0mem.h include/ut0mem.ic include/ut0rnd.h include/ut0rnd.ic \
include/ut0sort.h include/ut0ut.h include/ut0ut.ic include/ut0vec.h include/ut0vec.ic include/ha_prototypes.h \ include/ut0sort.h include/ut0ut.h include/ut0ut.ic include/ut0vec.h include/ut0vec.ic include/ha_prototypes.h \
include/ut0list.h include/ut0list.ic \ include/ut0list.h include/ut0list.ic include/ut0wqueue.h \
include/ut0wqueue.h \
CMakeLists.txt CMakeLists.txt
noinst_LIBRARIES = libinnobase.a noinst_LIBRARIES = libinnobase.a
......
...@@ -624,7 +624,7 @@ btr_page_get_father_for_rec( ...@@ -624,7 +624,7 @@ btr_page_get_father_for_rec(
fputs( fputs(
"InnoDB: You should dump + drop + reimport the table to fix the\n" "InnoDB: You should dump + drop + reimport the table to fix the\n"
"InnoDB: corruption. If the crash happens at the database startup, see\n" "InnoDB: corruption. If the crash happens at the database startup, see\n"
"InnoDB: http://dev.mysql.com/doc/mysql/en/Forcing_recovery.html about\n" "InnoDB: http://dev.mysql.com/doc/refman/5.1/en/forcing-recovery.html about\n"
"InnoDB: forcing recovery. Then dump + drop + reimport.\n", stderr); "InnoDB: forcing recovery. Then dump + drop + reimport.\n", stderr);
} }
......
...@@ -323,7 +323,8 @@ buf_page_is_corrupted( ...@@ -323,7 +323,8 @@ buf_page_is_corrupted(
"InnoDB: is in the future! Current system log sequence number %lu %lu.\n" "InnoDB: is in the future! Current system log sequence number %lu %lu.\n"
"InnoDB: Your database may be corrupt or you may have copied the InnoDB\n" "InnoDB: Your database may be corrupt or you may have copied the InnoDB\n"
"InnoDB: tablespace but not the InnoDB log files. See\n" "InnoDB: tablespace but not the InnoDB log files. See\n"
"http://dev.mysql.com/doc/mysql/en/backing-up.html for more information.\n", "InnoDB: http://dev.mysql.com/doc/refman/5.1/en/forcing-recovery.html\n"
"InnoDB: for more information.\n",
(ulong) mach_read_from_4(read_buf + FIL_PAGE_OFFSET), (ulong) mach_read_from_4(read_buf + FIL_PAGE_OFFSET),
(ulong) ut_dulint_get_high( (ulong) ut_dulint_get_high(
mach_read_from_8(read_buf + FIL_PAGE_LSN)), mach_read_from_8(read_buf + FIL_PAGE_LSN)),
...@@ -1923,7 +1924,7 @@ buf_page_io_complete( ...@@ -1923,7 +1924,7 @@ buf_page_io_complete(
"InnoDB: the corrupt table. You can use CHECK\n" "InnoDB: the corrupt table. You can use CHECK\n"
"InnoDB: TABLE to scan your table for corruption.\n" "InnoDB: TABLE to scan your table for corruption.\n"
"InnoDB: See also " "InnoDB: See also "
"http://dev.mysql.com/doc/mysql/en/Forcing_recovery.html\n" "InnoDB: http://dev.mysql.com/doc/refman/5.1/en/forcing-recovery.html\n"
"InnoDB: about forcing recovery.\n", stderr); "InnoDB: about forcing recovery.\n", stderr);
if (srv_force_recovery < SRV_FORCE_IGNORE_CORRUPT) { if (srv_force_recovery < SRV_FORCE_IGNORE_CORRUPT) {
......
...@@ -2215,8 +2215,8 @@ dict_foreign_error_report( ...@@ -2215,8 +2215,8 @@ dict_foreign_error_report(
if (fk->foreign_index) { if (fk->foreign_index) {
fputs("The index in the foreign key in table is ", file); fputs("The index in the foreign key in table is ", file);
ut_print_name(file, NULL, FALSE, fk->foreign_index->name); ut_print_name(file, NULL, FALSE, fk->foreign_index->name);
fputs( fputs("\n"
"\nSee http://dev.mysql.com/doc/mysql/en/InnoDB_foreign_key_constraints.html\n" "See http://dev.mysql.com/doc/refman/5.1/en/innodb-foreign-key-constraints.html\n"
"for correct foreign key definition.\n", "for correct foreign key definition.\n",
file); file);
} }
...@@ -3119,7 +3119,7 @@ dict_create_foreign_constraints_low( ...@@ -3119,7 +3119,7 @@ dict_create_foreign_constraints_low(
ut_print_name(ef, NULL, TRUE, name); ut_print_name(ef, NULL, TRUE, name);
fprintf(ef, " where the columns appear\n" fprintf(ef, " where the columns appear\n"
"as the first columns. Constraint:\n%s\n" "as the first columns. Constraint:\n%s\n"
"See http://dev.mysql.com/doc/mysql/en/InnoDB_foreign_key_constraints.html\n" "See http://dev.mysql.com/doc/refman/5.1/en/innodb-foreign-key-constraints.html\n"
"for correct foreign key definition.\n", "for correct foreign key definition.\n",
start_of_latest_foreign); start_of_latest_foreign);
mutex_exit(&dict_foreign_err_mutex); mutex_exit(&dict_foreign_err_mutex);
...@@ -3387,7 +3387,7 @@ dict_create_foreign_constraints_low( ...@@ -3387,7 +3387,7 @@ dict_create_foreign_constraints_low(
"Note that the internal storage type of ENUM and SET changed in\n" "Note that the internal storage type of ENUM and SET changed in\n"
"tables created with >= InnoDB-4.1.12, and such columns in old tables\n" "tables created with >= InnoDB-4.1.12, and such columns in old tables\n"
"cannot be referenced by such columns in new tables.\n" "cannot be referenced by such columns in new tables.\n"
"See http://dev.mysql.com/doc/mysql/en/InnoDB_foreign_key_constraints.html\n" "See http://dev.mysql.com/doc/refman/5.1/en/innodb-foreign-key-constraints.html\n"
"for correct foreign key definition.\n", "for correct foreign key definition.\n",
start_of_latest_foreign); start_of_latest_foreign);
mutex_exit(&dict_foreign_err_mutex); mutex_exit(&dict_foreign_err_mutex);
...@@ -3941,8 +3941,7 @@ dict_update_statistics_low( ...@@ -3941,8 +3941,7 @@ dict_update_statistics_low(
fprintf(stderr, fprintf(stderr,
" InnoDB: cannot calculate statistics for table %s\n" " InnoDB: cannot calculate statistics for table %s\n"
"InnoDB: because the .ibd file is missing. For help, please refer to\n" "InnoDB: because the .ibd file is missing. For help, please refer to\n"
"InnoDB: " "InnoDB: http://dev.mysql.com/doc/refman/5.1/en/innodb-troubleshooting.html\n",
"http://dev.mysql.com/doc/mysql/en/InnoDB_troubleshooting_datadict.html\n",
table->name); table->name);
return; return;
......
...@@ -251,9 +251,6 @@ struct fil_system_struct { ...@@ -251,9 +251,6 @@ struct fil_system_struct {
initialized. */ initialized. */
fil_system_t* fil_system = NULL; fil_system_t* fil_system = NULL;
/* The tablespace memory cache hash table size */
#define FIL_SYSTEM_HASH_SIZE 50 /* TODO: make bigger! */
/************************************************************************ /************************************************************************
NOTE: you must call fil_mutex_enter_and_prepare_for_io() first! NOTE: you must call fil_mutex_enter_and_prepare_for_io() first!
...@@ -1323,11 +1320,17 @@ fil_init( ...@@ -1323,11 +1320,17 @@ fil_init(
/*=====*/ /*=====*/
ulint max_n_open) /* in: max number of open files */ ulint max_n_open) /* in: max number of open files */
{ {
ulint hash_size;
ut_a(fil_system == NULL); ut_a(fil_system == NULL);
/*printf("Initializing the tablespace cache with max %lu open files\n", if (srv_file_per_table) {
max_n_open); */ hash_size = 50000;
fil_system = fil_system_create(FIL_SYSTEM_HASH_SIZE, max_n_open); } else {
hash_size = 5000;
}
fil_system = fil_system_create(hash_size, max_n_open);
} }
/*********************************************************************** /***********************************************************************
...@@ -2560,7 +2563,7 @@ fil_reset_too_high_lsns( ...@@ -2560,7 +2563,7 @@ fil_reset_too_high_lsns(
ut_print_timestamp(stderr); ut_print_timestamp(stderr);
fprintf(stderr, fprintf(stderr,
" InnoDB: Flush lsn in the tablespace file %lu to be imported\n" " InnoDB: Flush lsn in the tablespace file %lu to be imported\n"
"InnoDB: is %lu %lu, which exceeds current system lsn %lu %lu.\n" "InnoDB: is %lu %lu, which exceeds current system lsn %lu %lu.\n"
"InnoDB: We reset the lsn's in the file ", "InnoDB: We reset the lsn's in the file ",
(ulong) space_id, (ulong) space_id,
...@@ -2685,8 +2688,7 @@ fil_open_single_table_tablespace( ...@@ -2685,8 +2688,7 @@ fil_open_single_table_tablespace(
"InnoDB: It is also possible that this is a temporary table #sql...,\n" "InnoDB: It is also possible that this is a temporary table #sql...,\n"
"InnoDB: and MySQL removed the .ibd file for this.\n" "InnoDB: and MySQL removed the .ibd file for this.\n"
"InnoDB: Please refer to\n" "InnoDB: Please refer to\n"
"InnoDB:" "InnoDB: http://dev.mysql.com/doc/refman/5.1/en/innodb-troubleshooting.html\n"
" http://dev.mysql.com/doc/mysql/en/InnoDB_troubleshooting_datadict.html\n"
"InnoDB: for how to resolve the issue.\n", stderr); "InnoDB: for how to resolve the issue.\n", stderr);
mem_free(filepath); mem_free(filepath);
...@@ -2725,8 +2727,7 @@ fil_open_single_table_tablespace( ...@@ -2725,8 +2727,7 @@ fil_open_single_table_tablespace(
"InnoDB: Have you moved InnoDB .ibd files around without using the\n" "InnoDB: Have you moved InnoDB .ibd files around without using the\n"
"InnoDB: commands DISCARD TABLESPACE and IMPORT TABLESPACE?\n" "InnoDB: commands DISCARD TABLESPACE and IMPORT TABLESPACE?\n"
"InnoDB: Please refer to\n" "InnoDB: Please refer to\n"
"InnoDB:" "InnoDB: http://dev.mysql.com/doc/refman/5.1/en/innodb-troubleshooting.html\n"
" http://dev.mysql.com/doc/mysql/en/InnoDB_troubleshooting_datadict.html\n"
"InnoDB: for how to resolve the issue.\n", (ulong) space_id, (ulong) id); "InnoDB: for how to resolve the issue.\n", (ulong) space_id, (ulong) id);
ret = FALSE; ret = FALSE;
...@@ -3373,8 +3374,7 @@ fil_space_for_table_exists_in_mem( ...@@ -3373,8 +3374,7 @@ fil_space_for_table_exists_in_mem(
error_exit: error_exit:
fputs( fputs(
"InnoDB: Please refer to\n" "InnoDB: Please refer to\n"
"InnoDB:" "InnoDB: http://dev.mysql.com/doc/refman/5.1/en/innodb-troubleshooting.html\n"
" http://dev.mysql.com/doc/mysql/en/InnoDB_troubleshooting_datadict.html\n"
"InnoDB: for how to resolve the issue.\n", stderr); "InnoDB: for how to resolve the issue.\n", stderr);
mem_free(path); mem_free(path);
......
...@@ -2988,7 +2988,7 @@ fseg_free_page_low( ...@@ -2988,7 +2988,7 @@ fseg_free_page_low(
crash: crash:
fputs( fputs(
"InnoDB: Please refer to\n" "InnoDB: Please refer to\n"
"InnoDB: http://dev.mysql.com/doc/mysql/en/Forcing_recovery.html\n" "InnoDB: http://dev.mysql.com/doc/refman/5.1/en/forcing-recovery.html\n"
"InnoDB: about forcing recovery.\n", stderr); "InnoDB: about forcing recovery.\n", stderr);
ut_error; ut_error;
} }
......
...@@ -373,7 +373,6 @@ ibuf_init_at_db_start(void) ...@@ -373,7 +373,6 @@ ibuf_init_at_db_start(void)
ibuf->max_size = buf_pool_get_curr_size() / UNIV_PAGE_SIZE ibuf->max_size = buf_pool_get_curr_size() / UNIV_PAGE_SIZE
/ IBUF_POOL_SIZE_PER_MAX_SIZE; / IBUF_POOL_SIZE_PER_MAX_SIZE;
ibuf->meter = IBUF_THRESHOLD + 1;
UT_LIST_INIT(ibuf->data_list); UT_LIST_INIT(ibuf->data_list);
...@@ -3517,21 +3516,9 @@ ibuf_print( ...@@ -3517,21 +3516,9 @@ ibuf_print(
data = UT_LIST_GET_FIRST(ibuf->data_list); data = UT_LIST_GET_FIRST(ibuf->data_list);
while (data) { while (data) {
fprintf(file,
"Ibuf for space %lu: size %lu, free list len %lu, seg size %lu,",
(ulong) data->space, (ulong) data->size,
(ulong) data->free_list_len,
(ulong) data->seg_size);
if (data->empty) {
fputs(" is empty\n", file);
} else {
fputs(" is not empty\n", file);
}
fprintf(file, fprintf(file,
"Ibuf for space %lu: size %lu, free list len %lu, seg size %lu,\n" "Ibuf: size %lu, free list len %lu, seg size %lu,\n"
"%lu inserts, %lu merged recs, %lu merges\n", "%lu inserts, %lu merged recs, %lu merges\n",
(ulong) data->space,
(ulong) data->size, (ulong) data->size,
(ulong) data->free_list_len, (ulong) data->free_list_len,
(ulong) data->seg_size, (ulong) data->seg_size,
......
...@@ -52,10 +52,7 @@ btr_cur_get_page( ...@@ -52,10 +52,7 @@ btr_cur_get_page(
/* out: pointer to page */ /* out: pointer to page */
btr_cur_t* cursor) /* in: tree cursor */ btr_cur_t* cursor) /* in: tree cursor */
{ {
page_t* page = buf_frame_align(page_cur_get_rec(&(cursor->page_cur))); return(buf_frame_align(page_cur_get_rec(&(cursor->page_cur))));
ut_ad(!!page_is_comp(page)
== dict_table_is_comp(cursor->index->table));
return(page);
} }
/************************************************************* /*************************************************************
......
...@@ -216,8 +216,8 @@ buf_block_align( ...@@ -216,8 +216,8 @@ buf_block_align(
"InnoDB: Error: trying to access a stray pointer %p\n" "InnoDB: Error: trying to access a stray pointer %p\n"
"InnoDB: buf pool start is at %p, end at %p\n" "InnoDB: buf pool start is at %p, end at %p\n"
"InnoDB: Probable reason is database corruption or memory\n" "InnoDB: Probable reason is database corruption or memory\n"
"InnoDB: corruption. If this happens in an InnoDB database recovery,\n" "InnoDB: corruption. If this happens in an InnoDB database recovery, see\n"
"InnoDB: you can look from section 6.1 at http://www.innodb.com/ibman.html\n" "InnoDB: http://dev.mysql.com/doc/refman/5.1/en/forcing-recovery.html\n"
"InnoDB: how to force recovery.\n", "InnoDB: how to force recovery.\n",
ptr, frame_zero, ptr, frame_zero,
buf_pool->high_end); buf_pool->high_end);
...@@ -252,8 +252,8 @@ buf_frame_align( ...@@ -252,8 +252,8 @@ buf_frame_align(
"InnoDB: Error: trying to access a stray pointer %p\n" "InnoDB: Error: trying to access a stray pointer %p\n"
"InnoDB: buf pool start is at %p, end at %p\n" "InnoDB: buf pool start is at %p, end at %p\n"
"InnoDB: Probable reason is database corruption or memory\n" "InnoDB: Probable reason is database corruption or memory\n"
"InnoDB: corruption. If this happens in an InnoDB database recovery,\n" "InnoDB: corruption. If this happens in an InnoDB database recovery, see\n"
"InnoDB: you can look from section 6.1 at http://www.innodb.com/ibman.html\n" "InnoDB: http://dev.mysql.com/doc/refman/5.1/en/forcing-recovery.html\n"
"InnoDB: how to force recovery.\n", "InnoDB: how to force recovery.\n",
ptr, buf_pool->frame_zero, ptr, buf_pool->frame_zero,
buf_pool->high_end); buf_pool->high_end);
......
...@@ -39,19 +39,11 @@ struct ibuf_data_struct{ ...@@ -39,19 +39,11 @@ struct ibuf_data_struct{
ulint n_merged_recs;/* number of records merged */ ulint n_merged_recs;/* number of records merged */
}; };
/* If the ibuf meter exceeds this value, then the suitable inserts are made to
the insert buffer instead of directly to the disk page */
#define IBUF_THRESHOLD 50
struct ibuf_struct{ struct ibuf_struct{
ulint size; /* current size of the ibuf index ulint size; /* current size of the ibuf index
trees in pages */ trees in pages */
ulint max_size; /* recommended maximum size in pages ulint max_size; /* recommended maximum size in pages
for the ibuf index tree */ for the ibuf index tree */
ulint meter; /* heuristic meter which measures
desirability of doing inserts to the
insert buffer instead of directly to
the disk page */
UT_LIST_BASE_NODE_T(ibuf_data_t) data_list; UT_LIST_BASE_NODE_T(ibuf_data_t) data_list;
/* list of ibuf data structs for /* list of ibuf data structs for
each tablespace */ each tablespace */
...@@ -88,8 +80,7 @@ ibuf_should_try( ...@@ -88,8 +80,7 @@ ibuf_should_try(
decide */ decide */
{ {
if (!(index->type & DICT_CLUSTERED) if (!(index->type & DICT_CLUSTERED)
&& (ignore_sec_unique || !(index->type & DICT_UNIQUE)) && (ignore_sec_unique || !(index->type & DICT_UNIQUE))) {
&& ibuf->meter > IBUF_THRESHOLD) {
ibuf_flush_count++; ibuf_flush_count++;
......
...@@ -720,7 +720,7 @@ log_calc_max_ages(void) ...@@ -720,7 +720,7 @@ log_calc_max_ages(void)
"InnoDB: To get mysqld to start up, set innodb_thread_concurrency in my.cnf\n" "InnoDB: To get mysqld to start up, set innodb_thread_concurrency in my.cnf\n"
"InnoDB: to a lower value, for example, to 8. After an ERROR-FREE shutdown\n" "InnoDB: to a lower value, for example, to 8. After an ERROR-FREE shutdown\n"
"InnoDB: of mysqld you can adjust the size of ib_logfiles, as explained in\n" "InnoDB: of mysqld you can adjust the size of ib_logfiles, as explained in\n"
"InnoDB: http://dev.mysql.com/doc/mysql/en/Adding_and_removing.html\n" "InnoDB: http://dev.mysql.com/doc/refman/5.1/en/adding-and-removing.html\n"
"InnoDB: Cannot continue operation. Calling exit(1).\n", "InnoDB: Cannot continue operation. Calling exit(1).\n",
(ulong)srv_thread_concurrency); (ulong)srv_thread_concurrency);
......
...@@ -542,7 +542,7 @@ recv_find_max_checkpoint( ...@@ -542,7 +542,7 @@ recv_find_max_checkpoint(
"InnoDB: the problem may be that during an earlier attempt you managed\n" "InnoDB: the problem may be that during an earlier attempt you managed\n"
"InnoDB: to create the InnoDB data files, but log file creation failed.\n" "InnoDB: to create the InnoDB data files, but log file creation failed.\n"
"InnoDB: If that is the case, please refer to\n" "InnoDB: If that is the case, please refer to\n"
"InnoDB: http://dev.mysql.com/doc/mysql/en/Error_creating_InnoDB.html\n"); "InnoDB: http://dev.mysql.com/doc/refman/5.1/en/error-creating-innodb.html\n");
return(DB_ERROR); return(DB_ERROR);
} }
...@@ -1962,7 +1962,7 @@ recv_report_corrupt_log( ...@@ -1962,7 +1962,7 @@ recv_report_corrupt_log(
"InnoDB: far enough in recovery! Please run CHECK TABLE\n" "InnoDB: far enough in recovery! Please run CHECK TABLE\n"
"InnoDB: on your InnoDB tables to check that they are ok!\n" "InnoDB: on your InnoDB tables to check that they are ok!\n"
"InnoDB: If mysqld crashes after this recovery, look at\n" "InnoDB: If mysqld crashes after this recovery, look at\n"
"InnoDB: http://dev.mysql.com/doc/mysql/en/Forcing_recovery.html\n" "InnoDB: http://dev.mysql.com/doc/refman/5.1/en/forcing-recovery.html\n"
"InnoDB: about forcing recovery.\n", stderr); "InnoDB: about forcing recovery.\n", stderr);
fflush(stderr); fflush(stderr);
......
...@@ -248,7 +248,7 @@ os_file_get_last_error( ...@@ -248,7 +248,7 @@ os_file_get_last_error(
fprintf(stderr, fprintf(stderr,
"InnoDB: Some operating system error numbers are described at\n" "InnoDB: Some operating system error numbers are described at\n"
"InnoDB: " "InnoDB: "
"http://dev.mysql.com/doc/mysql/en/Operating_System_error_codes.html\n"); "http://dev.mysql.com/doc/refman/5.1/en/operating-system-error-codes.html\n");
} }
} }
...@@ -295,7 +295,7 @@ os_file_get_last_error( ...@@ -295,7 +295,7 @@ os_file_get_last_error(
fprintf(stderr, fprintf(stderr,
"InnoDB: Some operating system error numbers are described at\n" "InnoDB: Some operating system error numbers are described at\n"
"InnoDB: " "InnoDB: "
"http://dev.mysql.com/doc/mysql/en/Operating_System_error_codes.html\n"); "http://dev.mysql.com/doc/refman/5.1/en/operating-system-error-codes.html\n");
} }
} }
...@@ -688,7 +688,7 @@ os_file_readdir_next_file( ...@@ -688,7 +688,7 @@ os_file_readdir_next_file(
/* TODO: test Windows symlinks */ /* TODO: test Windows symlinks */
/* TODO: MySQL has apparently its own symlink implementation in Windows, /* TODO: MySQL has apparently its own symlink implementation in Windows,
dbname.sym can redirect a database directory: dbname.sym can redirect a database directory:
http://www.mysql.com/doc/en/Windows_symbolic_links.html */ http://dev.mysql.com/doc/refman/5.1/en/windows-symbolic-links.html */
info->type = OS_FILE_TYPE_LINK; info->type = OS_FILE_TYPE_LINK;
} else if (lpFindFileData->dwFileAttributes } else if (lpFindFileData->dwFileAttributes
& FILE_ATTRIBUTE_DIRECTORY) { & FILE_ATTRIBUTE_DIRECTORY) {
...@@ -2343,7 +2343,7 @@ os_file_write( ...@@ -2343,7 +2343,7 @@ os_file_write(
"InnoDB: offset %lu %lu. Operating system error number %lu.\n" "InnoDB: offset %lu %lu. Operating system error number %lu.\n"
"InnoDB: Some operating system error numbers are described at\n" "InnoDB: Some operating system error numbers are described at\n"
"InnoDB: " "InnoDB: "
"http://dev.mysql.com/doc/mysql/en/Operating_System_error_codes.html\n", "http://dev.mysql.com/doc/refman/5.1/en/operating-system-error-codes.html\n",
name, (ulong) offset_high, (ulong) offset, name, (ulong) offset_high, (ulong) offset,
(ulong) GetLastError()); (ulong) GetLastError());
...@@ -2408,7 +2408,7 @@ os_file_write( ...@@ -2408,7 +2408,7 @@ os_file_write(
fprintf(stderr, fprintf(stderr,
"InnoDB: Some operating system error numbers are described at\n" "InnoDB: Some operating system error numbers are described at\n"
"InnoDB: " "InnoDB: "
"http://dev.mysql.com/doc/mysql/en/Operating_System_error_codes.html\n"); "http://dev.mysql.com/doc/refman/5.1/en/operating-system-error-codes.html\n");
os_has_said_disk_full = TRUE; os_has_said_disk_full = TRUE;
} }
...@@ -2444,7 +2444,7 @@ os_file_write( ...@@ -2444,7 +2444,7 @@ os_file_write(
fprintf(stderr, fprintf(stderr,
"InnoDB: Some operating system error numbers are described at\n" "InnoDB: Some operating system error numbers are described at\n"
"InnoDB: " "InnoDB: "
"http://dev.mysql.com/doc/mysql/en/Operating_System_error_codes.html\n"); "http://dev.mysql.com/doc/refman/5.1/en/operating-system-error-codes.html\n");
os_has_said_disk_full = TRUE; os_has_said_disk_full = TRUE;
} }
......
...@@ -54,27 +54,6 @@ static const char S_innodb_tablespace_monitor[] = "innodb_tablespace_monitor"; ...@@ -54,27 +54,6 @@ static const char S_innodb_tablespace_monitor[] = "innodb_tablespace_monitor";
static const char S_innodb_table_monitor[] = "innodb_table_monitor"; static const char S_innodb_table_monitor[] = "innodb_table_monitor";
static const char S_innodb_mem_validate[] = "innodb_mem_validate"; static const char S_innodb_mem_validate[] = "innodb_mem_validate";
/* Name suffix for recovered orphaned temporary tables */
static const char S_recover_innodb_tmp_table[] = "_recover_innodb_tmp_table";
/***********************************************************************
Determine if the given name ends in the suffix reserved for recovered
orphaned temporary tables. */
static
ibool
row_mysql_is_recovered_tmp_table(
/*=============================*/
/* out: TRUE if table name ends in
the reserved suffix */
const char* name)
{
ulint namelen = strlen(name) + 1;
return(namelen >= sizeof S_recover_innodb_tmp_table
&& !memcmp(name + namelen -
sizeof S_recover_innodb_tmp_table,
S_recover_innodb_tmp_table,
sizeof S_recover_innodb_tmp_table));
}
/*********************************************************************** /***********************************************************************
Determine if the given name is a name reserved for MySQL system tables. */ Determine if the given name is a name reserved for MySQL system tables. */
static static
...@@ -550,7 +529,7 @@ row_mysql_handle_errors( ...@@ -550,7 +529,7 @@ row_mysql_handle_errors(
"InnoDB: tables and recreate the whole InnoDB tablespace.\n" "InnoDB: tables and recreate the whole InnoDB tablespace.\n"
"InnoDB: If the mysqld server crashes after the startup or when\n" "InnoDB: If the mysqld server crashes after the startup or when\n"
"InnoDB: you dump the tables, look at\n" "InnoDB: you dump the tables, look at\n"
"InnoDB: http://dev.mysql.com/doc/mysql/en/Forcing_recovery.html" "InnoDB: http://dev.mysql.com/doc/refman/5.1/en/forcing-recovery.html"
" for help.\n", stderr); " for help.\n", stderr);
} else { } else {
...@@ -1083,7 +1062,7 @@ row_insert_for_mysql( ...@@ -1083,7 +1062,7 @@ row_insert_for_mysql(
"InnoDB: Have you deleted the .ibd file from the database directory under\n" "InnoDB: Have you deleted the .ibd file from the database directory under\n"
"InnoDB: the MySQL datadir, or have you used DISCARD TABLESPACE?\n" "InnoDB: the MySQL datadir, or have you used DISCARD TABLESPACE?\n"
"InnoDB: Look from\n" "InnoDB: Look from\n"
"http://dev.mysql.com/doc/mysql/en/InnoDB_troubleshooting_datadict.html\n" "InnoDB: http://dev.mysql.com/doc/refman/5.1/en/innodb-troubleshooting.html\n"
"InnoDB: how you can resolve the problem.\n", "InnoDB: how you can resolve the problem.\n",
prebuilt->table->name); prebuilt->table->name);
return(DB_ERROR); return(DB_ERROR);
...@@ -1319,7 +1298,7 @@ row_update_for_mysql( ...@@ -1319,7 +1298,7 @@ row_update_for_mysql(
"InnoDB: Have you deleted the .ibd file from the database directory under\n" "InnoDB: Have you deleted the .ibd file from the database directory under\n"
"InnoDB: the MySQL datadir, or have you used DISCARD TABLESPACE?\n" "InnoDB: the MySQL datadir, or have you used DISCARD TABLESPACE?\n"
"InnoDB: Look from\n" "InnoDB: Look from\n"
"http://dev.mysql.com/doc/mysql/en/InnoDB_troubleshooting_datadict.html\n" "InnoDB: http://dev.mysql.com/doc/refman/5.1/en/innodb-troubleshooting.html\n"
"InnoDB: how you can resolve the problem.\n", "InnoDB: how you can resolve the problem.\n",
prebuilt->table->name); prebuilt->table->name);
return(DB_ERROR); return(DB_ERROR);
...@@ -1659,48 +1638,6 @@ row_get_mysql_key_number_for_index( ...@@ -1659,48 +1638,6 @@ row_get_mysql_key_number_for_index(
return(i); return(i);
} }
/*************************************************************************
Recovers an orphaned tmp table inside InnoDB by renaming it. In the table
name #sql becomes rsql, and "_recover_innodb_tmp_table" is catenated to
the end of name. table->name should be of the form
"dbname/rsql..._recover_innodb_tmp_table". This renames a table whose
name is "#sql..." */
static
int
row_mysql_recover_tmp_table(
/*========================*/
/* out: error code or DB_SUCCESS */
dict_table_t* table, /* in: table definition */
trx_t* trx) /* in: transaction handle */
{
const char* ptr = strstr(table->name, "/rsql");
if (!ptr) {
/* table name does not begin with "/rsql" */
dict_mem_table_free(table);
trx_commit_for_mysql(trx);
return(DB_ERROR);
}
else {
int status;
int namelen = (int) strlen(table->name);
char* old_name = mem_strdupl(table->name, namelen);
/* replace "rsql" with "#sql" */
old_name[ptr - table->name + 1] = '#';
/* remove "_recover_innodb_tmp_table" suffix */
ut_ad(namelen > (int) sizeof S_recover_innodb_tmp_table);
ut_ad(!strcmp(old_name + namelen + 1 -
sizeof S_recover_innodb_tmp_table,
S_recover_innodb_tmp_table));
old_name[namelen + 1 - sizeof S_recover_innodb_tmp_table] = 0;
status = row_rename_table_for_mysql(old_name,
table->name, trx);
mem_free(old_name);
return(status);
}
}
/************************************************************************* /*************************************************************************
Locks the data dictionary in shared mode from modifications, for performing Locks the data dictionary in shared mode from modifications, for performing
foreign key check, rollback, or other operation invisible to MySQL. */ foreign key check, rollback, or other operation invisible to MySQL. */
...@@ -1845,18 +1782,6 @@ row_create_table_for_mysql( ...@@ -1845,18 +1782,6 @@ row_create_table_for_mysql(
trx_start_if_not_started(trx); trx_start_if_not_started(trx);
if (row_mysql_is_recovered_tmp_table(table->name)) {
/* MySQL prevents accessing of tables whose name begins
with #sql, that is temporary tables. If mysqld crashes in
the middle of an ALTER TABLE, we may get an orphaned
#sql-table in the tablespace. We have here a special
mechanism to recover such tables by renaming them to
rsql... */
return(row_mysql_recover_tmp_table(table, trx));
}
/* The table name is prefixed with the database name and a '/'. /* The table name is prefixed with the database name and a '/'.
Certain table names starting with 'innodb_' have their special Certain table names starting with 'innodb_' have their special
meaning regardless of the database name. Thus, we need to meaning regardless of the database name. Thus, we need to
...@@ -1968,8 +1893,8 @@ row_create_table_for_mysql( ...@@ -1968,8 +1893,8 @@ row_create_table_for_mysql(
"InnoDB: Then MySQL thinks the table exists, and DROP TABLE will\n" "InnoDB: Then MySQL thinks the table exists, and DROP TABLE will\n"
"InnoDB: succeed.\n" "InnoDB: succeed.\n"
"InnoDB: You can look for further help from\n" "InnoDB: You can look for further help from\n"
"InnoDB: http://dev.mysql.com/doc/mysql/en/" "InnoDB: http://dev.mysql.com/doc/refman/5.1/en/innodb-troubleshooting.html\n",
"InnoDB_troubleshooting_datadict.html\n", stderr); stderr);
} }
/* We may also get err == DB_ERROR if the .ibd file for the /* We may also get err == DB_ERROR if the .ibd file for the
...@@ -2063,11 +1988,6 @@ row_create_index_for_mysql( ...@@ -2063,11 +1988,6 @@ row_create_index_for_mysql(
} }
} }
if (row_mysql_is_recovered_tmp_table(index->table_name)) {
return(DB_SUCCESS);
}
heap = mem_heap_create(512); heap = mem_heap_create(512);
trx->dict_operation = TRUE; trx->dict_operation = TRUE;
...@@ -2142,11 +2062,6 @@ row_table_add_foreign_constraints( ...@@ -2142,11 +2062,6 @@ row_table_add_foreign_constraints(
trx_start_if_not_started(trx); trx_start_if_not_started(trx);
if (row_mysql_is_recovered_tmp_table(name)) {
return(DB_SUCCESS);
}
trx->dict_operation = TRUE; trx->dict_operation = TRUE;
err = dict_create_foreign_constraints(trx, sql_string, name, err = dict_create_foreign_constraints(trx, sql_string, name,
...@@ -3054,8 +2969,8 @@ row_drop_table_for_mysql( ...@@ -3054,8 +2969,8 @@ row_drop_table_for_mysql(
"InnoDB: Have you copied the .frm file of the table to the\n" "InnoDB: Have you copied the .frm file of the table to the\n"
"InnoDB: MySQL database directory from another database?\n" "InnoDB: MySQL database directory from another database?\n"
"InnoDB: You can look for further help from\n" "InnoDB: You can look for further help from\n"
"InnoDB: http://dev.mysql.com/doc/mysql/en/" "InnoDB: http://dev.mysql.com/doc/refman/5.1/en/innodb-troubleshooting.html\n",
"InnoDB_troubleshooting_datadict.html\n", stderr); stderr);
goto funct_exit; goto funct_exit;
} }
...@@ -3495,7 +3410,6 @@ row_rename_table_for_mysql( ...@@ -3495,7 +3410,6 @@ row_rename_table_for_mysql(
mem_heap_t* heap = NULL; mem_heap_t* heap = NULL;
const char** constraints_to_drop = NULL; const char** constraints_to_drop = NULL;
ulint n_constraints_to_drop = 0; ulint n_constraints_to_drop = 0;
ibool recovering_temp_table = FALSE;
ibool old_is_tmp, new_is_tmp; ibool old_is_tmp, new_is_tmp;
pars_info_t* info = NULL; pars_info_t* info = NULL;
...@@ -3533,15 +3447,10 @@ row_rename_table_for_mysql( ...@@ -3533,15 +3447,10 @@ row_rename_table_for_mysql(
old_is_tmp = row_is_mysql_tmp_table_name(old_name); old_is_tmp = row_is_mysql_tmp_table_name(old_name);
new_is_tmp = row_is_mysql_tmp_table_name(new_name); new_is_tmp = row_is_mysql_tmp_table_name(new_name);
if (row_mysql_is_recovered_tmp_table(new_name)) { /* Serialize data dictionary operations with dictionary mutex:
no deadlocks can occur then in these operations */
recovering_temp_table = TRUE;
} else {
/* Serialize data dictionary operations with dictionary mutex:
no deadlocks can occur then in these operations */
row_mysql_lock_data_dictionary(trx); row_mysql_lock_data_dictionary(trx);
}
table = dict_table_get_low(old_name); table = dict_table_get_low(old_name);
...@@ -3556,8 +3465,8 @@ row_rename_table_for_mysql( ...@@ -3556,8 +3465,8 @@ row_rename_table_for_mysql(
"InnoDB: Have you copied the .frm file of the table to the\n" "InnoDB: Have you copied the .frm file of the table to the\n"
"InnoDB: MySQL database directory from another database?\n" "InnoDB: MySQL database directory from another database?\n"
"InnoDB: You can look for further help from\n" "InnoDB: You can look for further help from\n"
"InnoDB: http://dev.mysql.com/doc/mysql/en/" "InnoDB: http://dev.mysql.com/doc/refman/5.1/en/innodb-troubleshooting.html\n",
"InnoDB_troubleshooting_datadict.html\n", stderr); stderr);
goto funct_exit; goto funct_exit;
} }
...@@ -3570,8 +3479,8 @@ row_rename_table_for_mysql( ...@@ -3570,8 +3479,8 @@ row_rename_table_for_mysql(
fputs( fputs(
" does not have an .ibd file in the database directory.\n" " does not have an .ibd file in the database directory.\n"
"InnoDB: You can look for further help from\n" "InnoDB: You can look for further help from\n"
"InnoDB: http://dev.mysql.com/doc/mysql/en/" "InnoDB: http://dev.mysql.com/doc/refman/5.1/en/innodb-troubleshooting.html\n",
"InnoDB_troubleshooting_datadict.html\n", stderr); stderr);
goto funct_exit; goto funct_exit;
} }
...@@ -3719,8 +3628,7 @@ row_rename_table_for_mysql( ...@@ -3719,8 +3628,7 @@ row_rename_table_for_mysql(
fputs(" to it.\n" fputs(" to it.\n"
"InnoDB: Have you deleted the .frm file and not used DROP TABLE?\n" "InnoDB: Have you deleted the .frm file and not used DROP TABLE?\n"
"InnoDB: You can look for further help from\n" "InnoDB: You can look for further help from\n"
"InnoDB: http://dev.mysql.com/doc/mysql/en/" "InnoDB: http://dev.mysql.com/doc/refman/5.1/en/innodb-troubleshooting.html\n"
"InnoDB_troubleshooting_datadict.html\n"
"InnoDB: If table ", stderr); "InnoDB: If table ", stderr);
ut_print_name(stderr, trx, TRUE, new_name); ut_print_name(stderr, trx, TRUE, new_name);
fputs( fputs(
...@@ -3748,8 +3656,8 @@ row_rename_table_for_mysql( ...@@ -3748,8 +3656,8 @@ row_rename_table_for_mysql(
trx_general_rollback_for_mysql(trx, FALSE, NULL); trx_general_rollback_for_mysql(trx, FALSE, NULL);
trx->error_state = DB_SUCCESS; trx->error_state = DB_SUCCESS;
ut_print_timestamp(stderr); ut_print_timestamp(stderr);
fputs(" InnoDB: Error in table rename, cannot rename ", fputs(
stderr); " InnoDB: Error in table rename, cannot rename ", stderr);
ut_print_name(stderr, trx, TRUE, old_name); ut_print_name(stderr, trx, TRUE, old_name);
fputs(" to ", stderr); fputs(" to ", stderr);
ut_print_name(stderr, trx, TRUE, new_name); ut_print_name(stderr, trx, TRUE, new_name);
...@@ -3797,10 +3705,7 @@ row_rename_table_for_mysql( ...@@ -3797,10 +3705,7 @@ row_rename_table_for_mysql(
funct_exit: funct_exit:
trx_commit_for_mysql(trx); trx_commit_for_mysql(trx);
row_mysql_unlock_data_dictionary(trx);
if (!recovering_temp_table) {
row_mysql_unlock_data_dictionary(trx);
}
if (UNIV_LIKELY_NULL(heap)) { if (UNIV_LIKELY_NULL(heap)) {
mem_heap_free(heap); mem_heap_free(heap);
...@@ -3968,7 +3873,7 @@ row_check_table_for_mysql( ...@@ -3968,7 +3873,7 @@ row_check_table_for_mysql(
"InnoDB: Have you deleted the .ibd file from the database directory under\n" "InnoDB: Have you deleted the .ibd file from the database directory under\n"
"InnoDB: the MySQL datadir, or have you used DISCARD TABLESPACE?\n" "InnoDB: the MySQL datadir, or have you used DISCARD TABLESPACE?\n"
"InnoDB: Look from\n" "InnoDB: Look from\n"
"http://dev.mysql.com/doc/mysql/en/InnoDB_troubleshooting_datadict.html\n" "InnoDB: http://dev.mysql.com/doc/refman/5.1/en/innodb-troubleshooting.html\n"
"InnoDB: how you can resolve the problem.\n", "InnoDB: how you can resolve the problem.\n",
prebuilt->table->name); prebuilt->table->name);
return(DB_ERROR); return(DB_ERROR);
......
...@@ -3245,7 +3245,7 @@ row_search_for_mysql( ...@@ -3245,7 +3245,7 @@ row_search_for_mysql(
"InnoDB: Have you deleted the .ibd file from the database directory under\n" "InnoDB: Have you deleted the .ibd file from the database directory under\n"
"InnoDB: the MySQL datadir, or have you used DISCARD TABLESPACE?\n" "InnoDB: the MySQL datadir, or have you used DISCARD TABLESPACE?\n"
"InnoDB: Look from\n" "InnoDB: Look from\n"
"http://dev.mysql.com/doc/mysql/en/InnoDB_troubleshooting_datadict.html\n" "InnoDB: http://dev.mysql.com/doc/refman/5.1/en/innodb-troubleshooting.html\n"
"InnoDB: how you can resolve the problem.\n", "InnoDB: how you can resolve the problem.\n",
prebuilt->table->name); prebuilt->table->name);
......
...@@ -553,7 +553,7 @@ row_vers_build_for_semi_consistent_read( ...@@ -553,7 +553,7 @@ row_vers_build_for_semi_consistent_read(
mem_heap_t* heap = NULL; mem_heap_t* heap = NULL;
byte* buf; byte* buf;
ulint err; ulint err;
dulint rec_trx_id; dulint rec_trx_id = ut_dulint_create(0, 0);
ut_ad(index->type & DICT_CLUSTERED); ut_ad(index->type & DICT_CLUSTERED);
ut_ad(mtr_memo_contains(mtr, buf_block_align(rec), MTR_MEMO_PAGE_X_FIX) ut_ad(mtr_memo_contains(mtr, buf_block_align(rec), MTR_MEMO_PAGE_X_FIX)
......
...@@ -1691,7 +1691,7 @@ NetWare. */ ...@@ -1691,7 +1691,7 @@ NetWare. */
"InnoDB: You have now successfully upgraded to the multiple tablespaces\n" "InnoDB: You have now successfully upgraded to the multiple tablespaces\n"
"InnoDB: format. You should NOT DOWNGRADE to an earlier version of\n" "InnoDB: format. You should NOT DOWNGRADE to an earlier version of\n"
"InnoDB: InnoDB! But if you absolutely need to downgrade, see\n" "InnoDB: InnoDB! But if you absolutely need to downgrade, see\n"
"InnoDB: http://dev.mysql.com/doc/mysql/en/Multiple_tablespaces.html\n" "InnoDB: http://dev.mysql.com/doc/refman/5.1/en/multiple-tablespaces.html\n"
"InnoDB: for instructions.\n"); "InnoDB: for instructions.\n");
} }
......
...@@ -42,7 +42,7 @@ ut_dbg_assertion_failed( ...@@ -42,7 +42,7 @@ ut_dbg_assertion_failed(
{ {
ut_print_timestamp(stderr); ut_print_timestamp(stderr);
fprintf(stderr, fprintf(stderr,
"InnoDB: Assertion failure in thread %lu" " InnoDB: Assertion failure in thread %lu"
" in file %s line %lu\n", " in file %s line %lu\n",
os_thread_pf(os_thread_get_curr_id()), file, line); os_thread_pf(os_thread_get_curr_id()), file, line);
if (expr) { if (expr) {
...@@ -56,7 +56,7 @@ ut_dbg_assertion_failed( ...@@ -56,7 +56,7 @@ ut_dbg_assertion_failed(
"InnoDB: If you get repeated assertion failures or crashes, even\n" "InnoDB: If you get repeated assertion failures or crashes, even\n"
"InnoDB: immediately after the mysqld startup, there may be\n" "InnoDB: immediately after the mysqld startup, there may be\n"
"InnoDB: corruption in the InnoDB tablespace. Please refer to\n" "InnoDB: corruption in the InnoDB tablespace. Please refer to\n"
"InnoDB: http://dev.mysql.com/doc/mysql/en/Forcing_recovery.html\n" "InnoDB: http://dev.mysql.com/doc/refman/5.1/en/forcing-recovery.html\n"
"InnoDB: about forcing recovery.\n", stderr); "InnoDB: about forcing recovery.\n", stderr);
#if defined(UNIV_SYNC_DEBUG) || !defined(UT_DBG_USE_ABORT) #if defined(UNIV_SYNC_DEBUG) || !defined(UT_DBG_USE_ABORT)
ut_dbg_stop_threads = TRUE; ut_dbg_stop_threads = TRUE;
......
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