sql_print_error("MySQL synchronous replication was not able to send the binlog to the slave within the timeout %lu. We assume that the slave has become inaccessible, and switch off synchronous replication until the communication to the slave works again. MySQL synchronous replication has sent binlog to the slave up to file %s, position %lu. This transaction needs it to be sent up to file %s, position %lu.",thd->variables.sync_replication_timeout,innobase_repl_file_name,(ulong)innobase_repl_pos,trx->repl_wait_binlog_name,(ulong)trx->repl_wait_binlog_pos);
" InnoDB: Error: MySQL synchronous replication\n"
"InnoDB: was not able to send the binlog to the slave within the\n"
"InnoDB: timeout %lu. We assume that the slave has become inaccessible,\n"
"InnoDB: and switch off synchronous replication until the communication.\n"
"InnoDB: to the slave works again.\n",
thd->variables.sync_replication_timeout);
fprintf(stderr,
"InnoDB: MySQL synchronous replication has sent binlog\n"
"InnoDB: to the slave up to file %s, position %lu\n",innobase_repl_file_name,
(ulong)innobase_repl_pos);
fprintf(stderr,
"InnoDB: This transaction needs it to be sent up to\n"
"InnoDB: file %s, position %lu\n",trx->repl_wait_binlog_name,
sql_print_error("MySQL synchronous replication has sent binlog to the slave up to file %s, position %lu, but now MySQL reports that it sent the binlog only up to file %s, position %lu",innobase_repl_file_name,(ulong)innobase_repl_pos,log_file_name,(ulong)end_offset);
" InnoDB: Error: MySQL synchronous replication has sent binlog\n"
"InnoDB: to the slave up to file %s, position %lu\n",innobase_repl_file_name,
(ulong)innobase_repl_pos);
fprintf(stderr,
"InnoDB: but now MySQL reports that it sent the binlog only up to\n"
"InnoDB: file %s, position %lu\n",log_file_name,(ulong)end_offset);
}
}
}
}
...
@@ -2149,9 +2119,7 @@ innobase_close_connection(
...
@@ -2149,9 +2119,7 @@ innobase_close_connection(
if(trx->active_trans==0
if(trx->active_trans==0
&&trx->conc_state!=TRX_NOT_STARTED){
&&trx->conc_state!=TRX_NOT_STARTED){
fprintf(stderr,
sql_print_error("trx->active_trans == 0, but trx->conc_state != TRX_NOT_STARTED");
"InnoDB: Error: trx->active_trans == 0\n"
"InnoDB: but trx->conc_state != TRX_NOT_STARTED\n");
}
}
...
@@ -2363,9 +2331,7 @@ ha_innobase::open(
...
@@ -2363,9 +2331,7 @@ ha_innobase::open(
if(!row_table_got_default_clust_index(ib_table)){
if(!row_table_got_default_clust_index(ib_table)){
if(primary_key>=MAX_KEY){
if(primary_key>=MAX_KEY){
fprintf(stderr,
sql_print_error("Table %s has a primary key in InnoDB data dictionary, but not in MySQL!",name);
"InnoDB: Error: table %s has a primary key in InnoDB\n"
"InnoDB: data dictionary, but not in MySQL!\n",name);
sql_print_error("Table %s has no primary key in InnoDB data dictionary, but has one in MySQL! If you created the table with a MySQL version < 3.23.54 and did not define a primary key, but defined a unique key with all non-NULL columns, then MySQL internally treats that key as the primary key. You can fix this error by dump + DROP + CREATE + reimport of the table.",name);
"InnoDB: Error: table %s has no primary key in InnoDB\n"
"InnoDB: data dictionary, but has one in MySQL!\n"
"InnoDB: If you created the table with a MySQL\n"
"InnoDB: version < 3.23.54 and did not define a primary\n"
"InnoDB: key, but defined a unique key with all non-NULL\n"
"InnoDB: columns, then MySQL internally treats that key\n"
"InnoDB: as the primary key. You can fix this error by\n"
"InnoDB: dump + DROP + CREATE + reimport of the table.\n",
name);
}
}
((row_prebuilt_t*)innobase_prebuilt)
((row_prebuilt_t*)innobase_prebuilt)
...
@@ -2405,10 +2362,7 @@ ha_innobase::open(
...
@@ -2405,10 +2362,7 @@ ha_innobase::open(
and it will never be updated anyway. */
and it will never be updated anyway. */
if(key_used_on_scan!=MAX_KEY){
if(key_used_on_scan!=MAX_KEY){
fprintf(stderr,
sql_print_warning("Table %s key_used_on_scan is %lu even though there is no primary key inside InnoDB.",name,(ulong)key_used_on_scan);
"InnoDB: Warning: table %s key_used_on_scan is %lu even though there is no\n"
"InnoDB: primary key inside InnoDB.\n",
name,(ulong)key_used_on_scan);
}
}
}
}
...
@@ -2563,9 +2517,7 @@ innobase_mysql_cmp(
...
@@ -2563,9 +2517,7 @@ innobase_mysql_cmp(
charset=get_charset(charset_number,MYF(MY_WME));
charset=get_charset(charset_number,MYF(MY_WME));
if(charset==NULL){
if(charset==NULL){
fprintf(stderr,
sql_print_error("InnoDB needs charset %lu for doing a comparison, but MySQL cannot find that charset.",(ulong)charset_number);
"InnoDB: fatal error: InnoDB needs charset %lu for doing a comparison,\n"
"InnoDB: but MySQL cannot find that charset.\n",(ulong)charset_number);
sql_print_error("The transaction object for the table handle is at %p, but for the current thread it is at %p",prebuilt->trx,(trx_t*)current_thd->ha_data[innobase_hton.slot]);
"InnoDB: Error: the transaction object for the table handle is at\n"
"InnoDB: %p, but for the current thread it is at %p\n",
sql_print_error("last_query_id is %lu != user_thd_query_id is %lu",(ulong)last_query_id,(ulong)user_thd->query_id);
" InnoDB: Error: last_query_id is %lu != user_thd_query_id is %lu\n",
(ulong)last_query_id,(ulong)user_thd->query_id);
mem_analyze_corruption((byte*)prebuilt->trx);
mem_analyze_corruption((byte*)prebuilt->trx);
ut_error;
ut_error;
}
}
...
@@ -4284,9 +4231,8 @@ ha_innobase::position(
...
@@ -4284,9 +4231,8 @@ ha_innobase::position(
table. */
table. */
if(len!=ref_length){
if(len!=ref_length){
fprintf(stderr,
sql_print_error("Stored ref len is %lu, but table ref len is %lu",
"InnoDB: Error: stored ref len is %lu, but table ref len is %lu\n",
(ulong)len,(ulong)ref_length);
(ulong)len,(ulong)ref_length);
}
}
}
}
...
@@ -4491,11 +4437,8 @@ create_index(
...
@@ -4491,11 +4437,8 @@ create_index(
||col_type==DATA_FLOAT
||col_type==DATA_FLOAT
||col_type==DATA_DOUBLE
||col_type==DATA_DOUBLE
||col_type==DATA_DECIMAL){
||col_type==DATA_DECIMAL){
fprintf(stderr,
sql_print_error("MySQL is trying to create a column prefix index field, on an inappropriate data type. Table name %s, column name %s.",table_name,key_part->field->field_name);
"InnoDB: error: MySQL is trying to create a column prefix index field\n"
"InnoDB: on an inappropriate data type. Table name %s, column name %s.\n",
table_name,key_part->field->field_name);
prefix_len=0;
prefix_len=0;
}
}
}else{
}else{
...
@@ -5378,12 +5321,7 @@ ha_innobase::info(
...
@@ -5378,12 +5321,7 @@ ha_innobase::info(
for(i=0;i<table->s->keys;i++){
for(i=0;i<table->s->keys;i++){
if(index==NULL){
if(index==NULL){
ut_print_timestamp(stderr);
ut_print_timestamp(stderr);
fprintf(stderr,
sql_print_error("Table %s contains less indexes inside InnoDB than are defined in the MySQL .frm file. Have you mixed up .frm files from different installations? See section 15.1 at http://www.innodb.com/ibman.html",ib_table->name);
" InnoDB: Error: table %s contains less indexes inside InnoDB\n"
"InnoDB: than are defined in the MySQL .frm file. Have you mixed up\n"
"InnoDB: .frm files from different installations? See section\n"
"InnoDB: 15.1 at http://www.innodb.com/ibman.html\n",
ib_table->name);
break;
break;
}
}
...
@@ -5391,15 +5329,7 @@ ha_innobase::info(
...
@@ -5391,15 +5329,7 @@ ha_innobase::info(
if(j+1>index->n_uniq){
if(j+1>index->n_uniq){
ut_print_timestamp(stderr);
ut_print_timestamp(stderr);
fprintf(stderr,
sql_print_error("Index %s of %s has %lu columns unique inside InnoDB, but MySQL is asking statistics for %lu columns. Have you mixed up .frm files from different installations? See section 15.1 at http://www.innodb.com/ibman.html",index->name,ib_table->name,(unsignedlong)index->n_uniq,j+1);
" InnoDB: Error: index %s of %s has %lu columns unique inside InnoDB\n"
"InnoDB: but MySQL is asking statistics for %lu columns. Have you mixed up\n"
"InnoDB: .frm files from different installations? See section\n"
"InnoDB: 15.1 at http://www.innodb.com/ibman.html\n",
index->name,
ib_table->name,
(unsignedlong)index->n_uniq,
j+1);
break;
break;
}
}
...
@@ -5947,9 +5877,7 @@ ha_innobase::start_stmt(
...
@@ -5947,9 +5877,7 @@ ha_innobase::start_stmt(
if(prebuilt->stored_select_lock_type!=LOCK_S
if(prebuilt->stored_select_lock_type!=LOCK_S
&&prebuilt->stored_select_lock_type!=LOCK_X){
&&prebuilt->stored_select_lock_type!=LOCK_X){
fprintf(stderr,
sql_print_error("stored_select_lock_type is %lu inside ::start_stmt()!",prebuilt->stored_select_lock_type);
"InnoDB: Error: stored_select_lock_type is %lu inside ::start_stmt()!\n",