Server IP : 104.21.38.3 / Your IP : 172.70.147.5 Web Server : Apache System : Linux krdc-ubuntu-s-2vcpu-4gb-amd-blr1-01.localdomain 5.15.0-142-generic #152-Ubuntu SMP Mon May 19 10:54:31 UTC 2025 x86_64 User : www ( 1000) PHP Version : 7.4.33 Disable Function : passthru,exec,system,putenv,chroot,chgrp,chown,shell_exec,popen,proc_open,pcntl_exec,ini_alter,ini_restore,dl,openlog,syslog,readlink,symlink,popepassthru,pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,imap_open,apache_setenv MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : ON Directory : /www/server/mysql/src/mysql-test/suite/innodb/r/ |
Upload File : |
# # Bug#16720368 INNODB CRASHES ON BROKEN #SQL*.IBD FILE AT STARTUP # SET GLOBAL innodb_file_per_table=1; CREATE TABLE bug16720368_1 (a INT PRIMARY KEY) ENGINE=InnoDB; CREATE TABLE bug16720368 (a INT PRIMARY KEY, b INT) ENGINE=InnoDB; INSERT INTO bug16720368 (a) VALUES (1),(2),(3),(4),(5),(6),(7),(8); # Cleanly shutdown mysqld # Corrupt FIL_PAGE_OFFSET in bug16720368.ibd, # and update the checksum to the "don't care" value. # Restart mysqld # restart # This will succeed after a clean shutdown, due to # fil_open_single_table_tablespace(check_space_id=FALSE). SELECT COUNT(*) FROM bug16720368; COUNT(*) 8 INSERT INTO bug16720368_1 VALUES(1); # Kill and restart # The table is unaccessible, because after a crash we will # validate the tablespace header. SELECT COUNT(*) FROM bug16720368; ERROR HY000: Tablespace is missing for table `test`.`bug16720368`. INSERT INTO bug16720368 VALUES(0,1); ERROR HY000: Tablespace is missing for table `test`.`bug16720368`. # Kill and restart: --innodb-force-recovery=3 # The table is readable thanks to innodb-force-recovery. SELECT COUNT(*) FROM bug16720368; COUNT(*) 8 INSERT INTO bug16720368 VALUES(0,1); ERROR HY000: Operation not allowed when innodb_forced_recovery > 0. # Shut down the server cleanly to hide the corruption. # restart # The table is accessible, because after a clean shutdown we will # NOT validate the tablespace header. # We can modify the existing pages, but we cannot allocate or free # any pages, because that would hit the corruption on page 0. SELECT COUNT(*) FROM bug16720368; COUNT(*) 8 INSERT INTO bug16720368 VALUES(0,1); # Shut down the server to uncorrupt the data. # Restart the server after uncorrupting the file. # restart INSERT INTO bug16720368 VALUES(9,1); SELECT COUNT(*) FROM bug16720368; COUNT(*) 10 DROP TABLE bug16720368, bug16720368_1; # # Bug#16735660 ASSERT TABLE2 == NULL, ROLLBACK OF RESURRECTED TXNS, # DICT_TABLE_ADD_TO_CACHE # SET GLOBAL innodb_file_per_table=1; CREATE TEMPORARY TABLE t1 (a INT PRIMARY KEY) ENGINE=InnoDB; BEGIN; INSERT INTO t1 VALUES(42); CREATE TABLE bug16735660 (a INT PRIMARY KEY) ENGINE=InnoDB; XA START 'x'; INSERT INTO bug16735660 VALUES(1),(2),(3); XA END 'x'; XA PREPARE 'x'; # Kill the server # Attempt to start without an *.ibd file. # restart SET TRANSACTION ISOLATION LEVEL READ UNCOMMITTED; SELECT * FROM bug16735660; a 1 2 3 XA RECOVER; formatID gtrid_length bqual_length data 1 1 0 x XA ROLLBACK 'x'; SELECT * FROM bug16735660; a DROP TABLE bug16735660;