Bug #24560 UNDO_BUFFER_SIZE <= 64K in CREATE LOGFILE GROUP -> data node failure
Submitted: 23 Nov 2006 21:48 Modified: 30 Apr 2007 9:30
Reporter: Serge Kozlov Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Cluster: Disk Data Severity:S2 (Serious)
Version:5.1.14-bk OS:Linux (Linux FC4)
Assigned to: justin he CPU Architecture:Any

[23 Nov 2006 21:48] Serge Kozlov
Description:
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 2
Server version: 5.1.14-beta-log Source distribution

Type 'help;' or '\h' for help. Type '\c' to clear the buffer.

mysql> use test;
Database changed
mysql> drop table t1;
ERROR 1051 (42S02): Unknown table 't1'
mysql> create logfile group lg1 add undofile 'undofile.dat' initial_size 20M un
do_buffer_size 1 engine=ndb;
Query OK, 0 rows affected (10.21 sec)

mysql> create tablespace ts1 add datafile 'datafile.dat' use logfile group lg1
initial_size 10M engine=ndb;
Query OK, 0 rows affected (7.74 sec)

mysql> create table t1 (a int not null primary key, b varchar(4000)) tablespace
 ts1 storage disk engine=ndb;
ERROR 1005 (HY000): Can't create table 'test.t1' (errno: 4009)
mysql>
------------------------------------------------------------------

Current byte-offset of file-pointer is: 568

Time: Thursday 23 November 2006 - 22:39:38
Status: Temporary error, restart node
Message: Internal program error (failed ndbrequire) (Internal error, programming
 error or missing error message, please report a bug)
Error: 2341
Error data: lgman.cpp
Error object: LGMAN (Line: 1374) 0x0000000e
Program: ./builds/libexec/ndbd
Pid: 29058
Trace: /space/run/ndb_2_trace.log.1
Version: Version 5.1.14 (beta)
***EOM***

How to repeat:
1.Start cluster

2. Create log file group with small value of undo_buffer_size:
CREATE LOGFILE GROUP lg1 ADD UNDOFILE 'undofile.dat' INITIAL_SIZE 20M UN
DO_BUFFER_SIZE 1 ENGINE=NDB;

3. Create tablespace:
CREATE TABLESPACE ts1 ADD DATAFILE 'datafile.dat' USE LOGFILE GROUP lg1
INITIAL_SIZE 10M ENGINE=NDB;

4. Create a table
 CREATE TABLE t1 (a INT NOT NULL PRIMARY KEY, b VARCHAR(4000)) TABLESPACE
 ts1 STORAGE DISK ENGINE=NDB;

Suggested fix:
Seems error is correct but ndbd nodes died...
[6 Feb 2007 10:58] Kris Buytaert
Are there any figures available as to define "small" ? 

As of which value could this problem dissappear ?
[6 Feb 2007 14:20] Serge Kozlov
'Small' value means 64K or less
[25 Apr 2007 5:24] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/25364

ChangeSet@1.2553, 2007-04-25 12:59:27+08:00, Justin.He@dev3-240.dev.cn.tlan +1 -0
  Bug#24560 Data nodes died(lgman) if undo_buffer_size from logfile group has small value
[27 Apr 2007 10:09] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/25597

ChangeSet@1.2499, 2007-04-27 12:26:13+02:00, tomas@whalegate.ndb.mysql.com +1 -0
  Bug#24560 Data nodes died(lgman) if undo_buffer_size from logfile group has small value
[27 Apr 2007 10:59] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/25599

ChangeSet@1.2553, 2007-04-27 18:46:43+08:00, Justin.He@dev3-240.dev.cn.tlan +3 -0
  Bug#24560 Data nodes died(lgman) if undo_buffer_size from logfile group has small value
[28 Apr 2007 19:35] Bugs System
Pushed into 5.1.18-beta
[30 Apr 2007 9:30] Jon Stephens
Thank you for your bug report. This issue has been committed to our source repository of that product and will be incorporated into the next release.

If necessary, you can access the source repository and build the latest available version, including the bug fix. More information about accessing the source trees is available at

    http://dev.mysql.com/doc/en/installing-source.html

Documented bugfix in 5.1.18 changelog; updated synopsis to include 64K figure.