| 1 |
alter table mysql.ndb_binlog_index drop primary key; |
| 2 |
use test; |
| 3 |
create table t1 (a int) engine=ndb; |
| 4 |
create procedure ins (`rows` int) |
| 5 |
begin |
| 6 |
set @x = 0; |
| 7 |
repeat |
| 8 |
insert into t1 values (1); |
| 9 |
set @x = @x + 1; |
| 10 |
until @x = `rows` |
| 11 |
end repeat; |
| 12 |
end% |
| 13 |
call ins(10000); |
| 14 |
Duplicate epochs according to mysql.ndb_binlog_index |
| 15 |
select epoch >> 32 as gci, |
| 16 |
(epoch << 32) >> 32 as ugci, |
| 17 |
sum(1) as count |
| 18 |
from mysql.ndb_binlog_index |
| 19 |
group by epoch |
| 20 |
having count > 1; |
| 21 |
gci ugci count |
| 22 |
Duplicate epochs according to MySQLD Binlog entries |
| 23 |
select epoch >> 32 as gci, |
| 24 |
(epoch << 32) >> 32 as ugci, |
| 25 |
sum(1) as count |
| 26 |
from epochs_in_binlog |
| 27 |
group by epoch |
| 28 |
having count > 1; |
| 29 |
gci ugci count |
| 30 |
reset master; |
| 31 |
alter table mysql.ndb_binlog_index add primary key (epoch, orig_server_id, orig_epoch); |
| 32 |
drop procedure ins; |
| 33 |
drop table t1; |