**** get master log position for replication slave *** master : prepare for replication File Position Binlog_do_db Binlog_ignore_db it312-35-bin.002 79 **** stop master *** stop mysql with default table type Innodb 3387 pts/3 00:00:00 mysqld 3389 pts/3 00:00:00 mysqld 3390 pts/3 00:00:00 mysqld 3391 pts/3 00:00:00 mysqld 3392 pts/3 00:00:00 mysqld 3393 pts/3 00:00:00 mysqld 3394 pts/3 00:00:00 mysqld 3395 pts/3 00:00:00 mysqld 3396 pts/3 00:00:00 mysqld 3397 pts/3 00:00:00 mysqld 3471 pts/3 00:00:00 mysqld 3705 pts/3 00:00:00 mysqld_safe 3735 pts/3 00:00:01 mysqld 3737 pts/3 00:00:00 mysqld 3738 pts/3 00:00:00 mysqld 3739 pts/3 00:00:00 mysqld 3740 pts/3 00:00:00 mysqld 3741 pts/3 00:00:00 mysqld 3742 pts/3 00:00:00 mysqld 3743 pts/3 00:00:00 mysqld 3744 pts/3 00:00:00 mysqld 3745 pts/3 00:00:00 mysqld 3764 pts/3 00:00:00 mysqld *** stop mysql database server 3387 pts/3 00:00:00 mysqld 3389 pts/3 00:00:00 mysqld 3390 pts/3 00:00:00 mysqld 3391 pts/3 00:00:00 mysqld 3392 pts/3 00:00:00 mysqld 3393 pts/3 00:00:00 mysqld 3394 pts/3 00:00:00 mysqld 3395 pts/3 00:00:00 mysqld 3396 pts/3 00:00:00 mysqld 3397 pts/3 00:00:00 mysqld 3471 pts/3 00:00:00 mysqld **** stop slave if necessary *** stop mysqld2 3387 pts/3 00:00:00 mysqld 3389 pts/3 00:00:00 mysqld 3390 pts/3 00:00:00 mysqld 3391 pts/3 00:00:00 mysqld 3392 pts/3 00:00:00 mysqld 3393 pts/3 00:00:00 mysqld 3394 pts/3 00:00:00 mysqld 3395 pts/3 00:00:00 mysqld 3396 pts/3 00:00:00 mysqld 3397 pts/3 00:00:00 mysqld 3471 pts/3 00:00:00 mysqld *** stop mysql database server 2 **** create replication slave *** create /var/lib/mysql2 for slave *** remove mysql2 at slave db server ls: /var/lib/mysql2: No such file or directory *** create slave from master *** delete old server log files -rw-rw---- 1 mysql root 5996 Oct 29 12:08 /var/lib/mysql2/it312-35-bin.001 -rw-rw---- 1 mysql mysql 79 Oct 29 12:08 /var/lib/mysql2/it312-35-bin.002 -rw-rw---- 1 mysql root 38 Oct 29 12:08 /var/lib/mysql2/it312-35-bin.index -rw-rw---- 1 mysql root 1289 Oct 29 12:08 /var/lib/mysql2/it312-35.err ls: /var/lib/mysql2/it312-*: No such file or directory ls: /var/lib/mysql2/hostname.pid*: No such file or directory *** ensure mysql2 is created total 51300 -rw-rw---- 1 mysql mysql 25088 Oct 29 12:08 ib_arch_log_0000000000 -rw-rw---- 1 mysql mysql 10485760 Oct 29 12:08 ibdata1 -rw-rw---- 1 mysql mysql 20971520 Oct 29 12:08 ib_logfile0 -rw-rw---- 1 mysql mysql 20971520 Oct 29 12:08 ib_logfile1 drwx--x--x 2 mysql root 4096 Oct 29 12:08 mysql drwxr-xr-x 2 mysql root 4096 Oct 29 12:08 test **** start replication slave *** start mysqld2 *** start mysql database server 2 3835 pts/3 00:00:00 mysqld 3837 pts/3 00:00:00 mysqld 3838 pts/3 00:00:00 mysqld 3839 pts/3 00:00:00 mysqld 3840 pts/3 00:00:00 mysqld 3841 pts/3 00:00:00 mysqld 3842 pts/3 00:00:00 mysqld 3843 pts/3 00:00:00 mysqld 3844 pts/3 00:00:00 mysqld 3845 pts/3 00:00:00 mysqld **** start master *** restart mysql with default table type Innodb 3835 pts/3 00:00:00 mysqld 3837 pts/3 00:00:00 mysqld 3838 pts/3 00:00:00 mysqld 3839 pts/3 00:00:00 mysqld 3840 pts/3 00:00:00 mysqld 3841 pts/3 00:00:00 mysqld 3842 pts/3 00:00:00 mysqld 3843 pts/3 00:00:00 mysqld 3844 pts/3 00:00:00 mysqld 3845 pts/3 00:00:00 mysqld *** stop mysql database server ./bin/mysqladmin: connect to server at 'localhost' failed error: 'Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2)' Check that mysqld is running and that the socket: '/var/lib/mysql/mysql.sock' exists! 3835 pts/3 00:00:00 mysqld 3837 pts/3 00:00:00 mysqld 3838 pts/3 00:00:00 mysqld 3839 pts/3 00:00:00 mysqld 3840 pts/3 00:00:00 mysqld 3841 pts/3 00:00:00 mysqld 3842 pts/3 00:00:00 mysqld 3843 pts/3 00:00:00 mysqld 3844 pts/3 00:00:00 mysqld 3845 pts/3 00:00:00 mysqld *** start mysql with default table type Innodb 3835 pts/3 00:00:00 mysqld 3837 pts/3 00:00:00 mysqld 3838 pts/3 00:00:00 mysqld 3839 pts/3 00:00:00 mysqld 3840 pts/3 00:00:00 mysqld 3841 pts/3 00:00:00 mysqld 3842 pts/3 00:00:00 mysqld 3843 pts/3 00:00:00 mysqld 3844 pts/3 00:00:00 mysqld 3845 pts/3 00:00:00 mysqld 3862 pts/3 00:00:00 safe_mysqld 3892 pts/3 00:00:00 mysqld 3894 pts/3 00:00:00 mysqld 3895 pts/3 00:00:00 mysqld 3896 pts/3 00:00:00 mysqld 3897 pts/3 00:00:00 mysqld 3898 pts/3 00:00:00 mysqld 3899 pts/3 00:00:00 mysqld 3900 pts/3 00:00:00 mysqld 3901 pts/3 00:00:00 mysqld 3902 pts/3 00:00:00 mysqld **** start replication process *** slave : start replication Master_Host Master_User Master_Port Connect_retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_do_db Replicate_ignore_db Last_errno Last_error Skip_counter Exec_master_log_pos Relay_log_space 127.0.0.1 root 3306 60 it312-35-bin.002 79 it312-35-relay-bin.001 4 it312-35-bin.002 No No 0 0 79 4 Master_Host Master_User Master_Port Connect_retry Master_Log_File Read_Master_Log_Pos Relay_Log_File Relay_Log_Pos Relay_Master_Log_File Slave_IO_Running Slave_SQL_Running Replicate_do_db Replicate_ignore_db Last_errno Last_error Skip_counter Exec_master_log_pos Relay_log_space 127.0.0.1 root 3306 60 it312-35-bin.002 79 it312-35-relay-bin.001 4 it312-35-bin.002 Yes Yes 0 0 79 4 **** run sql commands at master to create tables *** Initialize overall test **** restart master mysqld *** restart mysql with default table type Innodb 3835 pts/3 00:00:00 mysqld 3837 pts/3 00:00:00 mysqld 3838 pts/3 00:00:00 mysqld 3839 pts/3 00:00:00 mysqld 3840 pts/3 00:00:00 mysqld 3841 pts/3 00:00:00 mysqld 3842 pts/3 00:00:00 mysqld 3843 pts/3 00:00:00 mysqld 3844 pts/3 00:00:00 mysqld 3845 pts/3 00:00:00 mysqld 3862 pts/3 00:00:00 safe_mysqld 3892 pts/3 00:00:00 mysqld 3894 pts/3 00:00:00 mysqld 3895 pts/3 00:00:00 mysqld 3896 pts/3 00:00:00 mysqld 3897 pts/3 00:00:00 mysqld 3898 pts/3 00:00:00 mysqld 3899 pts/3 00:00:00 mysqld 3900 pts/3 00:00:00 mysqld 3901 pts/3 00:00:00 mysqld 3902 pts/3 00:00:00 mysqld 3915 pts/3 00:00:00 mysqld 3916 pts/3 00:00:00 mysqld 3917 pts/3 00:00:00 mysqld *** stop mysql database server 3835 pts/3 00:00:00 mysqld 3837 pts/3 00:00:00 mysqld 3838 pts/3 00:00:00 mysqld 3839 pts/3 00:00:00 mysqld 3840 pts/3 00:00:00 mysqld 3841 pts/3 00:00:00 mysqld 3842 pts/3 00:00:00 mysqld 3843 pts/3 00:00:00 mysqld 3844 pts/3 00:00:00 mysqld 3845 pts/3 00:00:00 mysqld 3915 pts/3 00:00:00 mysqld 3917 pts/3 00:00:00 mysqld *** start mysql with default table type Innodb 3835 pts/3 00:00:00 mysqld 3837 pts/3 00:00:00 mysqld 3838 pts/3 00:00:00 mysqld 3839 pts/3 00:00:00 mysqld 3840 pts/3 00:00:00 mysqld 3841 pts/3 00:00:00 mysqld 3842 pts/3 00:00:00 mysqld 3843 pts/3 00:00:00 mysqld 3844 pts/3 00:00:00 mysqld 3845 pts/3 00:00:00 mysqld 3915 pts/3 00:00:00 mysqld 3917 pts/3 00:00:00 mysqld 3958 pts/3 00:00:00 safe_mysqld 3988 pts/3 00:00:00 mysqld 3990 pts/3 00:00:00 mysqld 3991 pts/3 00:00:00 mysqld 3992 pts/3 00:00:00 mysqld 3993 pts/3 00:00:00 mysqld 3994 pts/3 00:00:00 mysqld 3995 pts/3 00:00:00 mysqld 3996 pts/3 00:00:00 mysqld 3997 pts/3 00:00:00 mysqld 3998 pts/3 00:00:00 mysqld **** master mysqld bug created 031029 12:08:27 mysqld started InnoDB: The first specified data file /var/lib/mysql/ibdata1 did not exist: InnoDB: a new database to be created! 031029 12:08:28 InnoDB: Setting file /var/lib/mysql/ibdata1 size to 10 MB InnoDB: Database physically writes the file full: wait... 031029 12:08:29 InnoDB: Log file /var/lib/mysql/ib_logfile0 did not exist: new to be created InnoDB: Setting log file /var/lib/mysql/ib_logfile0 size to 20 MB InnoDB: Database physically writes the file full: wait... 031029 12:08:31 InnoDB: Log file /var/lib/mysql/ib_logfile1 did not exist: new to be created InnoDB: Setting log file /var/lib/mysql/ib_logfile1 size to 20 MB InnoDB: Database physically writes the file full: wait... InnoDB: Doublewrite buffer not found: creating new InnoDB: Doublewrite buffer created InnoDB: Creating foreign key constraint system tables InnoDB: Foreign key constraint system tables created 031029 12:08:34 InnoDB: Started /usr/sbin/mysqld: ready for connections. Version: '4.0.16-standard-log' socket: '/var/lib/mysql/mysql.sock' port: 3306 031029 12:08:56 /usr/sbin/mysqld: Normal shutdown 031029 12:08:57 InnoDB: Starting shutdown... 031029 12:08:59 InnoDB: Shutdown completed 031029 12:08:59 /usr/sbin/mysqld: Shutdown Complete 031029 12:08:59 mysqld ended 031029 12:09:44 mysqld started 031029 12:09:44 InnoDB: Started /usr/sbin/mysqld: ready for connections. Version: '4.0.16-standard-log' socket: '/var/lib/mysql/mysql.sock' port: 3306 031029 12:09:56 /usr/sbin/mysqld: Normal shutdown 031029 12:09:57 InnoDB: Starting shutdown... 031029 12:10:07 InnoDB: Shutdown completed 031029 12:10:07 /usr/sbin/mysqld: Shutdown Complete 031029 12:10:07 mysqld ended 031029 12:10:17 mysqld started InnoDB: ############### CORRUPT LOG RECORD FOUND InnoDB: Log record type 127, space id 4294902784, page number 211 InnoDB: Log parsing proceeded successfully up to 0 146226 InnoDB: Previous log record type 999999, is multi 0 InnoDB: Recv offset 0, prev 0 InnoDB: Hex dump of corrupt log starting 100 bytes before the start InnoDB: of the previous log rec, InnoDB: and ending 100 bytes after the start of the corrupt rec: len 200; hex 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000021020000870d745d0e57c0810002000f63d775fffffffff040080d300b6f0ffffffff040080d300baf0ffffffff040080d300bef0ffffffff040080d300c2f0ffffffff040080d300c6f0ffffffff040080d300caf0ffffffff040080d300cef0ffffffff040080d300d2f0ffffffff040080d300d6f0ff; asc .................................................................................. ..p.E..|... ..=w_....................................................................................................; InnoDB: WARNING: the log file may have been corrupt and it InnoDB: is possible that the log scan did not proceed InnoDB: far enough in recovery! Please run CHECK TABLE InnoDB: on your InnoDB tables to check that they are ok! InnoDB: If mysqld crashes after this recovery, look at InnoDB: section 6.1 of http://www.innodb.com/ibman.html InnoDB: about forcing recovery. 031029 12:10:18 InnoDB: Error: page 2 log sequence number 0 146485 InnoDB: is in the future! Current system log sequence number 0 146226. InnoDB: Your database may be corrupt. 031029 12:10:18 InnoDB: Error: page 11 log sequence number 0 146485 InnoDB: is in the future! Current system log sequence number 0 146226. InnoDB: Your database may be corrupt. 031029 12:10:18 InnoDB: Error: page 5 log sequence number 0 146500 InnoDB: is in the future! Current system log sequence number 0 146226. InnoDB: Your database may be corrupt. 031029 12:10:18 InnoDB: Error: page 45 log sequence number 0 146500 InnoDB: is in the future! Current system log sequence number 0 146226. InnoDB: Your database may be corrupt. 031029 12:10:18 InnoDB: Error: page 0 log sequence number 0 146485 InnoDB: is in the future! Current system log sequence number 0 146226. InnoDB: Your database may be corrupt. InnoDB: WARNING: the log file may have been corrupt and it InnoDB: is possible that the log scan or parsing did not proceed InnoDB: far enough in recovery. Please run CHECK TABLE InnoDB: on your InnoDB tables to check that they are ok! InnoDB: It may be safest to recover your InnoDB database from InnoDB: a backup! 031029 12:10:18 InnoDB: Started /usr/sbin/mysqld: ready for connections. Version: '4.0.16-standard-log' socket: '/var/lib/mysql/mysql.sock' port: 3306 *** list /var/lib/mysql/master.info cat: /var/lib/mysql/master.info: No such file or directory