Commit 04799ddb authored by lzhou/zhl@dev3-63.(none)'s avatar lzhou/zhl@dev3-63.(none)
Browse files

BUG#29186 Return error to client in the following condition:

          1: Create a log file which is larger than 4G in 32-bit host.
          2: Create a data file (tablespace) which is larger than 4G in 32-bit host.
parent f0f025f9
Loading
Loading
Loading
Loading
+35 −0
Original line number Diff line number Diff line
set autocommit=1;
reset master;
create table bug16206 (a int);
insert into bug16206 values(1);
start transaction;
insert into bug16206 values(2);
commit;
show binlog events;
Log_name	Pos	Event_type	Server_id	End_log_pos	Info
f	n	Format_desc	1	n	Server ver: VERSION, Binlog ver: 4
f	n	Query	1	n	use `test`; create table bug16206 (a int)
f	n	Query	1	n	use `test`; insert into bug16206 values(1)
f	n	Query	1	n	use `test`; insert into bug16206 values(2)
drop table bug16206;
reset master;
create table bug16206 (a int) engine=         bdb;
insert into bug16206 values(0);
insert into bug16206 values(1);
start transaction;
insert into bug16206 values(2);
commit;
insert into bug16206 values(3);
show binlog events;
Log_name	Pos	Event_type	Server_id	End_log_pos	Info
f	n	Format_desc	1	n	Server ver: VERSION, Binlog ver: 4
f	n	Query	1	n	use `test`; create table bug16206 (a int) engine=         bdb
f	n	Query	1	n	use `test`; insert into bug16206 values(0)
f	n	Query	1	n	use `test`; insert into bug16206 values(1)
f	n	Query	1	n	use `test`; BEGIN
f	n	Query	1	n	use `test`; insert into bug16206 values(2)
f	n	Query	1	n	use `test`; COMMIT
f	n	Query	1	n	use `test`; insert into bug16206 values(3)
drop table bug16206;
set autocommit=0;
End of 5.0 tests
+38 −0
Original line number Diff line number Diff line
-- source include/not_embedded.inc
-- source include/have_bdb.inc

#
# Bug #16206: Superfluous COMMIT event in binlog when updating BDB in autocommit mode
#
set autocommit=1;

let $VERSION=`select version()`;

reset master;
create table bug16206 (a int);
insert into bug16206 values(1);
start transaction;
insert into bug16206 values(2);
commit;
--replace_result $VERSION VERSION
--replace_column 1 f 2 n 5 n
show binlog events;
drop table bug16206;

reset master;
create table bug16206 (a int) engine=         bdb;
insert into bug16206 values(0);
insert into bug16206 values(1);
start transaction;
insert into bug16206 values(2);
commit;
insert into bug16206 values(3);
--replace_result $VERSION VERSION
--replace_column 1 f 2 n 5 n
show binlog events;
drop table bug16206;

set autocommit=0;


--echo End of 5.0 tests
+2 −1
Original line number Diff line number Diff line
@@ -163,7 +163,8 @@ struct CreateFileImplRef {
    InvalidFileMetadata = 1510,
    OutOfMemory = 1511,
    FileReadError = 1512,
    FilegroupNotOnline = 1513
    FilegroupNotOnline = 1513,
    FileSizeTooLarge = 1515
  };
  
  Uint32 senderData;
+10 −0
Original line number Diff line number Diff line
@@ -12,6 +12,8 @@ Next BACKUP 10038
Next DBUTIL 11002
Next DBTUX 12008
Next SUMA 13001
Next LGMAN 15001
Next TSMAN 16001

TESTING NODE FAILURE, ARBITRATION
---------------------------------
@@ -535,3 +537,11 @@ NDBCNTR:

1000: Crash insertion on SystemError::CopyFragRef
1001: Delay sending NODE_FAILREP (to own node), until error is cleared

LGMAN:
-----
15000: Fail to create log file

TSMAN:
-----
16000: Fail to create data file
+6 −0
Original line number Diff line number Diff line
@@ -8286,6 +8286,12 @@ void Dbdih::execDIHNDBTAMPER(Signal* signal)
    } else if (tuserpointer < 15000) {
      jam();
      tuserblockref = DBDICT_REF;
    } else if (tuserpointer < 16000) {
      jam();
      tuserblockref = LGMAN_REF;
    } else if (tuserpointer < 17000) {
      jam();
      tuserblockref = TSMAN_REF;
    } else if (tuserpointer < 30000) {
      /*--------------------------------------------------------------------*/
      // Ignore errors in the 20000-range.
Loading