Bug #33566 Backup: crash with partitions and Falcon
Submitted: 29 Dec 2007 0:23 Modified: 19 Aug 2008 8:16
Reporter: Peter Gulutzan Email Updates:
Status: Duplicate Impact on me:
None 
Category:MySQL Server: Backup Severity:S3 (Non-critical)
Version:6.0.5-alpha-debug OS:Linux (SUSE 10 64-bit)
Assigned to: Assigned Account CPU Architecture:Any

[29 Dec 2007 0:23] Peter Gulutzan
Description:
I create a partitioned Falcon table.
I insert a few rows.
I say BACKUP DATABASE.
Crash.

Built from mysql-6.0-backup source with BUILD/compile-pentium-debug-max.
Last changeset = "ChangeSet@1.2753, 2007-12-20 15:32:22-05:00".

How to repeat:
CREATE DATABASE k;
USE k
CREATE TABLE t (
  int_column int(11), char_column char(5))
  engine=falcon
  PARTITION BY RANGE (int_column)
  (PARTITION p1 VALUES LESS THAN (0),
   PARTITION p2 VALUES LESS THAN MAXVALUE);
INSERT INTO t VALUES (0,'pVtIa');
INSERT INTO t VALUES (5,'jTfSg');
INSERT INTO t VALUES (20,'UezFi');
INSERT INTO t VALUES (25,'cxmeH');
INSERT INTO t VALUES (65,'lIuNS');
BACKUP DATABASE k TO '/usr/local/mysql/var/t25';
[29 Dec 2007 5:43] MySQL Verification Team
Thank you for the bug report.

mysql1>INSERT INTO t VALUES (65,'lIuNS');
Query OK, 1 row affected (0.00 sec)

mysql1>BACKUP DATABASE k TO '/home/miguel/dbs/6.0b/var/t25';
ERROR 2013 (HY000): Lost connection to MySQL server during query
mysql1>
[26 Jan 2008 2:47] Chuck Bell
This bug was tested against the code for WL#3574 and WL#4205. It does not fail under these patches. Recommend this bug be retested once the patches are pushed.
[27 Feb 2008 21:46] Chuck Bell
Confirmed bug still exists in latest mysql-6.0-backup tree. The bug appears inside the field_string::store() method as called from the falcon code. The call stack is:

mysqld.exe!_NMSG_WRITE(int rterrnum=10)  Line 198	C
mysqld.exe!abort()  Line 59 + 0x7 bytes	C
mysqld.exe!_wassert(const wchar_t * expr=0x00cb3218, const wchar_t * filename=0x00cb31fc, unsigned int lineno=6246)  Line 212	C
mysqld.exe!Field_string::store(const char * from=0x0714a884, unsigned int length=5, charset_info_st * cs=0x00eead68)  Line 6246 + 0x24 bytes	C++
mysqld.exe!StorageInterface::decodeRecord(unsigned char * buf=0x027e8850)  Line 2385 + 0x37 bytes	C++
mysqld.exe!StorageInterface::rnd_next(unsigned char * buf=0x027e8850)  Line 514	C++
mysqld.exe!ha_partition::rnd_next(unsigned char * buf=0x027e8850)  Line 3228 + 0x16 bytes	C++
mysqld.exe!default_backup::Backup::get_data(backup::Buffer & buf={...})  Line 364 + 0x22 bytes	C++
mysqld.exe!backup::Backup_pump::pump(unsigned int * howmuch=0x04e09db8)  Line 1251 + 0x1c bytes	C++
mysqld.exe!backup::Scheduler::step()  Line 761 + 0x13 bytes	C++
mysqld.exe!backup::write_table_data(THD * thd=0x027acea0, backup::Backup_info & info={...}, backup::OStream & s={...})  Line 597 + 0x8 bytes	C++
mysqld.exe!mysql_backup(THD * thd=0x027acea0, backup::Backup_info & info={...}, backup::OStream & s={...})  Line 465 + 0x11 bytes	C++
mysqld.exe!execute_backup_command(THD * thd=0x027acea0, st_lex * lex=0x027ade40)  Line 343 + 0x17 bytes	C++
mysqld.exe!mysql_execute_command(THD * thd=0x027acea0)  Line 2128 + 0xd bytes	C++
mysqld.exe!mysql_parse(THD * thd=0x027acea0, const char * inBuf=0x0280a9d8, unsigned int length=28, const char * * found_semicolon=0x04e0fcb4)  Line 5616 + 0x9 bytes	C++
mysqld.exe!dispatch_command(enum_server_command command=COM_QUERY, THD * thd=0x027acea0, char * packet=0x028026e9, unsigned int packet_length=28)  Line 1030 + 0x1e bytes	C++
mysqld.exe!do_command(THD * thd=0x027acea0)  Line 722 + 0x1b bytes	C++
mysqld.exe!handle_one_connection(void * arg=0x027acea0)  Line 1122 + 0x9 bytes	C++
mysqld.exe!pthread_start(void * param=0x027b5d48)  Line 86 + 0x9 bytes	C
mysqld.exe!_callthreadstart()  Line 293 + 0xf bytes	C
mysqld.exe!_threadstart(void * ptd=0x02806720)  Line 277	C
kernel32.dll!76853833() 	
[Frames below may be incorrect and/or missing, no symbols loaded for kernel32.dll]	
ntdll.dll!77d9a9bd() 	

Recommend retesting bug once falcon tree is pushed to main and pulled into backup tree.
[29 Jul 2008 11:39] Øystein Grøvlen
Bug still present.  See Bug#36792
[12 Aug 2008 12:08] Jørgen Løland
I think this is a duplicate of bug#35117. I'll recheck once 35117 is fixed.