PTDEBUG=1 pt-online-schema-change --alter "MODIFY content VARCHAR(512) NOT NULL" --execute D=howaboutwe_staging,t=answers,u=root,p= # /usr/bin/perl 5.014002 # Linux staging-db-master 3.2.0-38-virtual #61-Ubuntu SMP Tue Feb 19 12:37:47 UTC 2013 x86_64 x86_64 x86_64 GNU/Linux # Arguments: _[--alter]_ _[MODIFY content VARCHAR(512) NOT NULL]_ _[--execute]_ _[D=howaboutwe_staging,t=answers,u=root,p=]_ # OptionParser:244 23158 Option rule: --dry-run and --execute are mutually exclusive. # OptionParser:244 23158 Option rule: This tool accepts additional command-line arguments. Refer to the SYNOPSIS and usage information for details. # OptionParser:253 23158 =item --alter # OptionParser:280 23158 Short help: The schema modification, without the ALTER TABLE keywords # OptionParser:253 23158 =item --alter-foreign-keys-method # OptionParser:280 23158 Short help: How to modify foreign keys so they reference the new table # OptionParser:253 23158 =item --ask-pass # OptionParser:272 23158 Option has no attributes # OptionParser:280 23158 Short help: Prompt for a password when connecting to MySQL # OptionParser:253 23158 =item --charset # OptionParser:280 23158 Short help: Default character set # OptionParser:253 23158 =item --[no]check-alter # OptionParser:280 23158 Short help: Parses the --alter specified and tries to warn of possible unintended behavior # OptionParser:253 23158 =item --check-interval # OptionParser:280 23158 Short help: Sleep time between checks for --max-lag # OptionParser:253 23158 =item --[no]check-plan # OptionParser:280 23158 Short help: Check query execution plans for safety # OptionParser:253 23158 =item --[no]check-replication-filters # OptionParser:280 23158 Short help: Abort if any replication filter is set on any server # OptionParser:253 23158 =item --check-slave-lag # OptionParser:280 23158 Short help: Pause the data copy until this replica's lag is less than --max-lag # OptionParser:253 23158 =item --chunk-index # OptionParser:280 23158 Short help: Prefer this index for chunking tables # OptionParser:253 23158 =item --chunk-index-columns # OptionParser:280 23158 Short help: Use only this many left-most columns of a --chunk-index # OptionParser:253 23158 =item --chunk-size # OptionParser:280 23158 Short help: Number of rows to select for each chunk copied # OptionParser:253 23158 =item --chunk-size-limit # OptionParser:280 23158 Short help: Do not copy chunks this much larger than the desired chunk size # OptionParser:253 23158 =item --chunk-time # OptionParser:280 23158 Short help: Adjust the chunk size dynamically so each data-copy query takes this long to execute # OptionParser:253 23158 =item --config # OptionParser:280 23158 Short help: Read this comma-separated list of config files; if specified, this must be the first option on the command line # OptionParser:253 23158 =item --critical-load # OptionParser:280 23158 Short help: Examine SHOW GLOBAL STATUS after every chunk, and abort if the load is too high # OptionParser:253 23158 =item --database # OptionParser:280 23158 Short help: Connect to this database # OptionParser:253 23158 =item --default-engine # OptionParser:272 23158 Option has no attributes # OptionParser:280 23158 Short help: Remove ENGINE from the new table # OptionParser:253 23158 =item --defaults-file # OptionParser:280 23158 Short help: Only read mysql options from the given file # OptionParser:253 23158 =item --[no]drop-new-table # OptionParser:280 23158 Short help: Drop the new table if copying the original table fails # OptionParser:253 23158 =item --[no]drop-old-table # OptionParser:280 23158 Short help: Drop the original table after renaming it # OptionParser:253 23158 =item --dry-run # OptionParser:272 23158 Option has no attributes # OptionParser:280 23158 Short help: Create and alter the new table, but do not create triggers, copy data, or replace the original table # OptionParser:253 23158 =item --execute # OptionParser:272 23158 Option has no attributes # OptionParser:280 23158 Short help: Indicate that you have read the documentation and want to alter the table # OptionParser:253 23158 =item --help # OptionParser:272 23158 Option has no attributes # OptionParser:280 23158 Short help: Show help and exit # OptionParser:253 23158 =item --host # OptionParser:280 23158 Short help: Connect to host # OptionParser:253 23158 =item --max-lag # OptionParser:280 23158 Short help: Pause the data copy until all replicas' lag is less than this value # OptionParser:253 23158 =item --max-load # OptionParser:280 23158 Short help: Examine SHOW GLOBAL STATUS after every chunk, and pause if any status variables are higher than their thresholds # OptionParser:253 23158 =item --password # OptionParser:280 23158 Short help: Password to use when connecting # OptionParser:253 23158 =item --pid # OptionParser:280 23158 Short help: Create the given PID file # OptionParser:253 23158 =item --plugin # OptionParser:280 23158 Short help: Perl module file that defines a pt_online_schema_change_plugin class # OptionParser:253 23158 =item --port # OptionParser:280 23158 Short help: Port number to use for connection # OptionParser:253 23158 =item --print # OptionParser:272 23158 Option has no attributes # OptionParser:280 23158 Short help: Print SQL statements to STDOUT # OptionParser:253 23158 =item --progress # OptionParser:280 23158 Short help: Print progress reports to STDERR while copying rows # OptionParser:253 23158 =item --quiet # OptionParser:280 23158 Short help: Do not print messages to STDOUT (disables --progress) # OptionParser:253 23158 =item --recurse # OptionParser:280 23158 Short help: Number of levels to recurse in the hierarchy when discovering replicas # OptionParser:253 23158 =item --recursion-method # OptionParser:280 23158 Short help: Preferred recursion method for discovering replicas # OptionParser:253 23158 =item --set-vars # OptionParser:280 23158 Short help: Set the MySQL variables in this comma-separated list of variable=value pairs # OptionParser:253 23158 =item --socket # OptionParser:280 23158 Short help: Socket file to use for connection # OptionParser:253 23158 =item --statistics # OptionParser:272 23158 Option has no attributes # OptionParser:280 23158 Short help: Print statistics about internal counters # OptionParser:253 23158 =item --[no]swap-tables # OptionParser:280 23158 Short help: Swap the original table and the new, altered table # OptionParser:253 23158 =item --tries # OptionParser:280 23158 Short help: How many times to try critical operations # OptionParser:253 23158 =item --user # OptionParser:280 23158 Short help: User for login if not current user # OptionParser:253 23158 =item --version # OptionParser:272 23158 Option has no attributes # OptionParser:280 23158 Short help: Show version and exit # OptionParser:253 23158 =item --[no]version-check # OptionParser:280 23158 Short help: Check for the latest version of Percona Toolkit, MySQL, and other programs # OptionParser:319 23158 Parsing opt spec: group => default spec => alter=s desc => The schema modification, without the ALTER TABLE keywords # OptionParser:357 23158 alter type: s # OptionParser:319 23158 Parsing opt spec: group => default spec => alter-foreign-keys-method=s desc => How to modify foreign keys so they reference the new table # OptionParser:357 23158 alter-foreign-keys-method type: s # OptionParser:319 23158 Parsing opt spec: group => default spec => ask-pass desc => Prompt for a password when connecting to MySQL # OptionParser:357 23158 ask-pass type: undef # OptionParser:319 23158 Parsing opt spec: group => default spec => charset|A=s desc => Default character set # OptionParser:357 23158 charset type: s # OptionParser:319 23158 Parsing opt spec: group => default spec => check-alter! desc => Parses the --alter specified and tries to warn of possible unintended behavior (default yes) # OptionParser:357 23158 check-alter type: undef # OptionParser:364 23158 check-alter default: yes # OptionParser:319 23158 Parsing opt spec: group => default spec => check-interval=m desc => Sleep time between checks for --max-lag (default 1) # OptionParser:357 23158 check-interval type: m # OptionParser:364 23158 check-interval default: 1 # OptionParser:319 23158 Parsing opt spec: group => default spec => check-plan! desc => Check query execution plans for safety (default yes) # OptionParser:357 23158 check-plan type: undef # OptionParser:364 23158 check-plan default: yes # OptionParser:319 23158 Parsing opt spec: group => default spec => check-replication-filters! desc => Abort if any replication filter is set on any server (default yes) # OptionParser:357 23158 check-replication-filters type: undef # OptionParser:364 23158 check-replication-filters default: yes # OptionParser:319 23158 Parsing opt spec: group => default spec => check-slave-lag=s desc => Pause the data copy until this replica's lag is less than --max-lag # OptionParser:357 23158 check-slave-lag type: s # OptionParser:319 23158 Parsing opt spec: group => default spec => chunk-index=s desc => Prefer this index for chunking tables # OptionParser:357 23158 chunk-index type: s # OptionParser:319 23158 Parsing opt spec: group => default spec => chunk-index-columns=i desc => Use only this many left-most columns of a --chunk-index # OptionParser:357 23158 chunk-index-columns type: i # OptionParser:319 23158 Parsing opt spec: group => default spec => chunk-size=z desc => Number of rows to select for each chunk copied (default 1000) # OptionParser:357 23158 chunk-size type: z # OptionParser:364 23158 chunk-size default: 1000 # OptionParser:319 23158 Parsing opt spec: group => default spec => chunk-size-limit=f desc => Do not copy chunks this much larger than the desired chunk size (default 4.0) # OptionParser:357 23158 chunk-size-limit type: f # OptionParser:364 23158 chunk-size-limit default: 4.0 # OptionParser:319 23158 Parsing opt spec: group => default spec => chunk-time=f desc => Adjust the chunk size dynamically so each data-copy query takes this long to execute (default 0.5) # OptionParser:357 23158 chunk-time type: f # OptionParser:364 23158 chunk-time default: 0.5 # OptionParser:319 23158 Parsing opt spec: group => default spec => config=A desc => Read this comma-separated list of config files; if specified, this must be the first option on the command line # OptionParser:357 23158 config type: A # OptionParser:319 23158 Parsing opt spec: group => default spec => critical-load=A desc => Examine SHOW GLOBAL STATUS after every chunk, and abort if the load is too high (default Threads_running=50) # OptionParser:357 23158 critical-load type: A # OptionParser:364 23158 critical-load default: Threads_running=50 # OptionParser:319 23158 Parsing opt spec: group => default spec => database|D=s desc => Connect to this database # OptionParser:357 23158 database type: s # OptionParser:319 23158 Parsing opt spec: group => default spec => default-engine desc => Remove ENGINE from the new table # OptionParser:357 23158 default-engine type: undef # OptionParser:319 23158 Parsing opt spec: group => default spec => defaults-file|F=s desc => Only read mysql options from the given file # OptionParser:357 23158 defaults-file type: s # OptionParser:319 23158 Parsing opt spec: group => default spec => drop-new-table! desc => Drop the new table if copying the original table fails (default yes) # OptionParser:357 23158 drop-new-table type: undef # OptionParser:364 23158 drop-new-table default: yes # OptionParser:319 23158 Parsing opt spec: group => default spec => drop-old-table! desc => Drop the original table after renaming it (default yes) # OptionParser:357 23158 drop-old-table type: undef # OptionParser:364 23158 drop-old-table default: yes # OptionParser:319 23158 Parsing opt spec: group => default spec => dry-run desc => Create and alter the new table, but do not create triggers, copy data, or replace the original table # OptionParser:357 23158 dry-run type: undef # OptionParser:319 23158 Parsing opt spec: group => default spec => execute desc => Indicate that you have read the documentation and want to alter the table # OptionParser:357 23158 execute type: undef # OptionParser:319 23158 Parsing opt spec: group => default spec => help desc => Show help and exit # OptionParser:357 23158 help type: undef # OptionParser:319 23158 Parsing opt spec: group => default spec => host|h=s desc => Connect to host # OptionParser:357 23158 host type: s # OptionParser:319 23158 Parsing opt spec: group => default spec => max-lag=m desc => Pause the data copy until all replicas' lag is less than this value (default 1s) # OptionParser:357 23158 max-lag type: m # OptionParser:364 23158 max-lag default: 1s # OptionParser:319 23158 Parsing opt spec: group => default spec => max-load=A desc => Examine SHOW GLOBAL STATUS after every chunk, and pause if any status variables are higher than their thresholds (default Threads_running=25) # OptionParser:357 23158 max-load type: A # OptionParser:364 23158 max-load default: Threads_running=25 # OptionParser:319 23158 Parsing opt spec: group => default spec => password|p=s desc => Password to use when connecting # OptionParser:357 23158 password type: s # OptionParser:319 23158 Parsing opt spec: group => default spec => pid=s desc => Create the given PID file # OptionParser:357 23158 pid type: s # OptionParser:319 23158 Parsing opt spec: group => default spec => plugin=s desc => Perl module file that defines a pt_online_schema_change_plugin class # OptionParser:357 23158 plugin type: s # OptionParser:319 23158 Parsing opt spec: group => default spec => port|P=i desc => Port number to use for connection # OptionParser:357 23158 port type: i # OptionParser:319 23158 Parsing opt spec: group => default spec => print desc => Print SQL statements to STDOUT # OptionParser:357 23158 print type: undef # OptionParser:319 23158 Parsing opt spec: group => default spec => progress=a desc => Print progress reports to STDERR while copying rows (default time,30) # OptionParser:357 23158 progress type: a # OptionParser:364 23158 progress default: time,30 # OptionParser:319 23158 Parsing opt spec: group => default spec => quiet|q desc => Do not print messages to STDOUT (disables --progress) # OptionParser:357 23158 quiet type: undef # OptionParser:373 23158 Deferring check of disables rule for HASH(0x266e5c0) disables --progress) # OptionParser:319 23158 Parsing opt spec: group => default spec => recurse=i desc => Number of levels to recurse in the hierarchy when discovering replicas # OptionParser:357 23158 recurse type: i # OptionParser:319 23158 Parsing opt spec: group => default spec => recursion-method=a desc => Preferred recursion method for discovering replicas (default processlist,hosts) # OptionParser:357 23158 recursion-method type: a # OptionParser:364 23158 recursion-method default: processlist,hosts # OptionParser:319 23158 Parsing opt spec: group => default spec => set-vars=A desc => Set the MySQL variables in this comma-separated list of variable=value pairs # OptionParser:357 23158 set-vars type: A # OptionParser:319 23158 Parsing opt spec: group => default spec => socket|S=s desc => Socket file to use for connection # OptionParser:357 23158 socket type: s # OptionParser:319 23158 Parsing opt spec: group => default spec => statistics desc => Print statistics about internal counters # OptionParser:357 23158 statistics type: undef # OptionParser:319 23158 Parsing opt spec: group => default spec => swap-tables! desc => Swap the original table and the new, altered table (default yes) # OptionParser:357 23158 swap-tables type: undef # OptionParser:364 23158 swap-tables default: yes # OptionParser:319 23158 Parsing opt spec: group => default spec => tries=a desc => How many times to try critical operations # OptionParser:357 23158 tries type: a # OptionParser:319 23158 Parsing opt spec: group => default spec => user|u=s desc => User for login if not current user # OptionParser:357 23158 user type: s # OptionParser:319 23158 Parsing opt spec: group => default spec => version desc => Show version and exit # OptionParser:357 23158 version type: undef # OptionParser:319 23158 Parsing opt spec: group => default spec => version-check! desc => Check for the latest version of Percona Toolkit, MySQL, and other programs (default yes) # OptionParser:357 23158 version-check type: undef # OptionParser:364 23158 version-check default: yes # OptionParser:379 23158 Parsing rule: --dry-run and --execute are mutually exclusive. # OptionParser:435 23158 Participants for --dry-run and --execute are mutually exclusive. : dry-run execute # OptionParser:387 23158 dry-run execute are mutually exclusive # OptionParser:379 23158 Parsing rule: This tool accepts additional command-line arguments. Refer to the SYNOPSIS and usage information for details. # OptionParser:435 23158 Participants for This tool accepts additional command-line arguments. Refer to the SYNOPSIS and usage information for details. : # OptionParser:411 23158 Strict mode disabled by rule # OptionParser:435 23158 Participants for disables --progress) : progress # OptionParser:421 23158 Option quiet disables progress # OptionParser:163 23158 Parsing DSN OPTIONS # OptionParser:253 23158 =item * A # OptionParser:280 23158 Short help: Default character set # OptionParser:253 23158 =item * D # OptionParser:280 23158 Short help: Database for the old and new table # OptionParser:253 23158 =item * F # OptionParser:280 23158 Short help: Only read default options from the given file # OptionParser:253 23158 =item * h # OptionParser:280 23158 Short help: Connect to host # OptionParser:253 23158 =item * p # OptionParser:280 23158 Short help: Password to use when connecting # OptionParser:253 23158 =item * P # OptionParser:280 23158 Short help: Port number to use for connection # OptionParser:253 23158 =item * S # OptionParser:280 23158 Short help: Socket file to use for connection # OptionParser:253 23158 =item * t # OptionParser:280 23158 Short help: Table to alter # OptionParser:253 23158 =item * u # OptionParser:280 23158 Short help: User for login if not current user # DSNParser:2014 23158 DSN option: copy=1, dsn=charset, desc=Default character set, key=A # DSNParser:2014 23158 DSN option: copy=1, dsn=database, desc=Database for the old and new table, key=D # DSNParser:2014 23158 DSN option: copy=1, dsn=mysql_read_default_file, desc=Only read default options from the given file, key=F # DSNParser:2014 23158 DSN option: copy=1, dsn=host, desc=Connect to host, key=h # DSNParser:2014 23158 DSN option: copy=1, dsn=password, desc=Password to use when connecting, key=p # DSNParser:2014 23158 DSN option: copy=1, dsn=port, desc=Port number to use for connection, key=P # DSNParser:2014 23158 DSN option: copy=1, dsn=mysql_socket, desc=Socket file to use for connection, key=S # DSNParser:2014 23158 DSN option: copy=, dsn=table, desc=Table to alter, key=t # DSNParser:2014 23158 DSN option: copy=1, dsn=user, desc=User for login if not current user, key=u # OptionParser:207 23158 pt-online-schema-change 2.2.2 # OptionParser:519 23158 Cannot open /etc/percona-toolkit/percona-toolkit.conf: No such file or directory # # OptionParser:519 23158 Cannot open /etc/percona-toolkit/pt-online-schema-change.conf: No such file or directory # # OptionParser:519 23158 Cannot open /root/.percona-toolkit.conf: No such file or directory # # OptionParser:519 23158 Cannot open /root/.pt-online-schema-change.conf: No such file or directory # # OptionParser:487 23158 Got option alter = MODIFY content VARCHAR(512) NOT NULL # OptionParser:487 23158 Got option execute = 1 # OptionParser:697 23158 Parsing option chunk-size as a size value # OptionParser:707 23158 Nothing to validate for option check-slave-lag type s value undef # OptionParser:707 23158 Nothing to validate for option chunk-index type s value undef # OptionParser:707 23158 Nothing to validate for option password type s value undef # OptionParser:707 23158 Nothing to validate for option chunk-index-columns type i value undef # OptionParser:707 23158 Nothing to validate for option pid type s value undef # OptionParser:707 23158 Nothing to validate for option user type s value undef # OptionParser:707 23158 Nothing to validate for option alter type s value MODIFY content VARCHAR(512) NOT NULL # OptionParser:707 23158 Nothing to validate for option tries type a value undef # OptionParser:707 23158 Nothing to validate for option chunk-time type f value 0.5 # OptionParser:707 23158 Nothing to validate for option alter-foreign-keys-method type s value undef # OptionParser:707 23158 Nothing to validate for option charset type s value undef # OptionParser:707 23158 Nothing to validate for option port type i value undef # OptionParser:707 23158 Nothing to validate for option socket type s value undef # OptionParser:658 23158 Parsing option check-interval as a time value # OptionParser:663 23158 No suffix given; using s for check-interval (value: 1 ) # OptionParser:672 23158 Setting option check-interval to 1 # OptionParser:707 23158 Nothing to validate for option recurse type i value undef # OptionParser:658 23158 Parsing option max-lag as a time value # OptionParser:672 23158 Setting option max-lag to 1 # OptionParser:707 23158 Nothing to validate for option plugin type s value undef # OptionParser:707 23158 Nothing to validate for option chunk-size-limit type f value 4.0 # OptionParser:707 23158 Nothing to validate for option defaults-file type s value undef # OptionParser:707 23158 Nothing to validate for option host type s value undef # OptionParser:707 23158 Nothing to validate for option database type s value undef # OptionParser:1101 23158 --set-vars: $VAR1 = { # innodb_lock_wait_timeout => { # default => 1, # val => '1' # }, # lock_wait_timeout => { # default => 1, # val => '60' # }, # wait_timeout => { # default => 1, # val => '10000' # } # }; # # DSNParser:2030 23158 Setting set-vars property # DSNParser:2102 23158 DSN string made from options: # DSNParser:2039 23158 No DSN to parse # DSNParser:2042 23158 Parsing D=howaboutwe_staging,t=answers,u=root,p= # DSNParser:2061 23158 Finding value for S # DSNParser:2071 23158 Copying value for S from defaults # DSNParser:2061 23158 Finding value for F # DSNParser:2071 23158 Copying value for F from defaults # DSNParser:2061 23158 Finding value for A # DSNParser:2071 23158 Copying value for A from defaults # DSNParser:2061 23158 Finding value for P # DSNParser:2071 23158 Copying value for P from defaults # DSNParser:2061 23158 Finding value for p # DSNParser:2061 23158 Finding value for u # DSNParser:2061 23158 Finding value for h # DSNParser:2071 23158 Copying value for h from defaults # DSNParser:2061 23158 Finding value for D # DSNParser:2061 23158 Finding value for t # pt_online_schema_change:9234 23158 --tries: $VAR1 = { # copy_rows => { # tries => 10, # wait => '0.25' # }, # create_triggers => { # tries => 10, # wait => 1 # }, # drop_triggers => { # tries => 10, # wait => 1 # }, # swap_tables => { # tries => 10, # wait => 1 # }, # update_foreign_keys => { # tries => 10, # wait => 1 # } # }; # # OptionParser:781 23158 Getting description and usage from SYNOPSIS in /usr/bin/pt-online-schema-change # OptionParser:1034 23158 Parsing SYNOPSIS in /usr/bin/pt-online-schema-change # OptionParser:1047 23158 Raw SYNOPSIS text: Usage: pt-online-schema-change [OPTIONS] DSN # # pt-online-schema-change alters a table's structure without blocking reads or # writes. Specify the database and table in the DSN. Do not use this tool before # reading its documentation and checking your backups carefully. # # # OptionParser:785 23158 Description: pt-online-schema-change alters a table's structure without blocking reads or writes. Specify the database and table in the DSN. Do not use this tool before reading its documentation and checking your backups carefully. # Usage: pt-online-schema-change [OPTIONS] DSN # DSNParser:2102 23158 DSN string made from options: # DSNParser:2039 23158 No DSN to parse # DSNParser:2155 23158 DBI:mysql:howaboutwe_staging;;mysql_read_default_group=client # DSNParser:2204 23158 DBI:mysql:howaboutwe_staging;;mysql_read_default_group=client root mysql_enable_utf8=>0, ShowErrorStatement=>1, AutoCommit=>1, RaiseError=>1, PrintError=>0 # DSNParser:2232 23158 DBI::db=HASH(0x26b7050) SELECT @@SQL_MODE # DSNParser:2363 23158 DBI::db=HASH(0x26b7050) SET SESSION innodb_lock_wait_timeout=1 # DSNParser:2363 23158 DBI::db=HASH(0x26b7050) SET SESSION lock_wait_timeout=60 # DSNParser:2363 23158 DBI::db=HASH(0x26b7050) SET SESSION wait_timeout=10000 # DSNParser:2263 23158 DBI::db=HASH(0x26b7050) SET @@SQL_QUOTE_SHOW_CREATE = 1/*!40101, @@SQL_MODE='NO_AUTO_VALUE_ON_ZERO'*/ # DSNParser:2272 23158 DBH info: DBI::db=HASH(0x26b7050) $VAR1 = { # '@@hostname' => 'staging-db-master', # 'CONNECTION_ID()' => '6132', # 'DATABASE()' => 'howaboutwe_staging', # 'VERSION()' => '5.5.31-30.3-log' # }; # Connection info: Localhost via UNIX socket Character set info: $VAR1 = [ # { # Value => 'latin1', # Variable_name => 'character_set_client' # }, # { # Value => 'latin1', # Variable_name => 'character_set_connection' # }, # { # Value => 'utf8', # Variable_name => 'character_set_database' # }, # { # Value => 'binary', # Variable_name => 'character_set_filesystem' # }, # { # Value => 'latin1', # Variable_name => 'character_set_results' # }, # { # Value => 'utf8', # Variable_name => 'character_set_server' # }, # { # Value => 'utf8', # Variable_name => 'character_set_system' # }, # { # Value => '/usr/share/mysql/charsets/', # Variable_name => 'character_sets_dir' # } # ]; # $DBD::mysql::VERSION: 4.020 $DBI::VERSION: 1.616 # Cxn:3745 23158 DBI::db=HASH(0x26b7050) Setting dbh # Cxn:3750 23158 DBI::db=HASH(0x26b7050) SELECT @@server_id /*!50038 , @@hostname*/ # Cxn:3752 23158 DBI::db=HASH(0x26b7050) hostname: staging-db-master 2987022983 # Cxn:3733 23158 DBI::db=HASH(0x26b7050) Connected dbh to staging-db-master # DSNParser:2102 23158 DSN string made from options: # DSNParser:2039 23158 No DSN to parse # DSNParser:2155 23158 DBI:mysql:howaboutwe_staging;;mysql_read_default_group=client # DSNParser:2204 23158 DBI:mysql:howaboutwe_staging;;mysql_read_default_group=client root mysql_enable_utf8=>0, ShowErrorStatement=>1, AutoCommit=>1, RaiseError=>1, PrintError=>0 # DSNParser:2232 23158 DBI::db=HASH(0x26849e0) SELECT @@SQL_MODE # DSNParser:2363 23158 DBI::db=HASH(0x26849e0) SET SESSION innodb_lock_wait_timeout=1 # DSNParser:2363 23158 DBI::db=HASH(0x26849e0) SET SESSION lock_wait_timeout=60 # DSNParser:2363 23158 DBI::db=HASH(0x26849e0) SET SESSION wait_timeout=10000 # DSNParser:2263 23158 DBI::db=HASH(0x26849e0) SET @@SQL_QUOTE_SHOW_CREATE = 1/*!40101, @@SQL_MODE='NO_AUTO_VALUE_ON_ZERO'*/ # DSNParser:2272 23158 DBH info: DBI::db=HASH(0x26849e0) $VAR1 = { # '@@hostname' => 'staging-db-master', # 'CONNECTION_ID()' => '6133', # 'DATABASE()' => 'howaboutwe_staging', # 'VERSION()' => '5.5.31-30.3-log' # }; # Connection info: Localhost via UNIX socket Character set info: $VAR1 = [ # { # Value => 'latin1', # Variable_name => 'character_set_client' # }, # { # Value => 'latin1', # Variable_name => 'character_set_connection' # }, # { # Value => 'utf8', # Variable_name => 'character_set_database' # }, # { # Value => 'binary', # Variable_name => 'character_set_filesystem' # }, # { # Value => 'latin1', # Variable_name => 'character_set_results' # }, # { # Value => 'utf8', # Variable_name => 'character_set_server' # }, # { # Value => 'utf8', # Variable_name => 'character_set_system' # }, # { # Value => '/usr/share/mysql/charsets/', # Variable_name => 'character_sets_dir' # } # ]; # $DBD::mysql::VERSION: 4.020 $DBI::VERSION: 1.616 # Cxn:3745 23158 DBI::db=HASH(0x26849e0) Setting dbh # Cxn:3750 23158 DBI::db=HASH(0x26849e0) SELECT @@server_id /*!50038 , @@hostname*/ # Cxn:3752 23158 DBI::db=HASH(0x26849e0) hostname: staging-db-master 2987022983 # Cxn:3733 23158 DBI::db=HASH(0x26849e0) Connected dbh to staging-db-master # Percona::XtraDB::Cluster:7531 23158 staging-db-master SHOW VARIABLES LIKE 'wsrep_on' # Percona::XtraDB::Cluster:7533 23158 $VAR1 = undef; # # VersionParser:1894 23158 VersionParser got a dbh, trying to get the version # VersionParser:1942 23158 InnoDB support: DEFAULT # VersionParser:1954 23158 InnoDB version: 5.5.31-rel30.3 # MasterSlave:3976 23158 Recursion methods: processlist hosts # MasterSlave:3986 23158 Connected to D=howaboutwe_staging,p=...,t=answers,u=root # MasterSlave:3995 23158 SELECT @@SERVER_ID # MasterSlave:3997 23158 Working on server ID 2987022983 # MasterSlave:4030 23158 Looking for slaves on D=howaboutwe_staging,p=...,t=answers,u=root using methods processlist hosts # MasterSlave:4037 23158 Finding slaves with _find_slaves_by_processlist # MasterSlave:4099 23158 DBI::db=HASH(0x26b7050) SHOW GRANTS FOR CURRENT_USER() # MasterSlave:4129 23158 DBI::db=HASH(0x26b7050) SHOW PROCESSLIST # DSNParser:2042 23158 Parsing h=192.168.6.6 # DSNParser:2061 23158 Finding value for S # DSNParser:2071 23158 Copying value for S from defaults # DSNParser:2061 23158 Finding value for F # DSNParser:2071 23158 Copying value for F from defaults # DSNParser:2061 23158 Finding value for A # DSNParser:2071 23158 Copying value for A from defaults # DSNParser:2061 23158 Finding value for P # DSNParser:2071 23158 Copying value for P from defaults # DSNParser:2061 23158 Finding value for p # DSNParser:2067 23158 Copying value for p from previous DSN # DSNParser:2061 23158 Finding value for u # DSNParser:2067 23158 Copying value for u from previous DSN # DSNParser:2061 23158 Finding value for h # DSNParser:2061 23158 Finding value for D # DSNParser:2067 23158 Copying value for D from previous DSN # DSNParser:2061 23158 Finding value for t # DSNParser:2071 23158 Copying value for t from defaults # MasterSlave:4042 23158 Found 1 slaves # MasterSlave:4019 23158 Recursing from D=howaboutwe_staging,p=...,t=answers,u=root to D=howaboutwe_staging,h=192.168.6.6,p=...,u=root # MasterSlave:3976 23158 Recursion methods: processlist hosts # DSNParser:2155 23158 DBI:mysql:howaboutwe_staging;host=192.168.6.6;mysql_read_default_group=client # DSNParser:2204 23158 DBI:mysql:howaboutwe_staging;host=192.168.6.6;mysql_read_default_group=client root mysql_enable_utf8=>0, ShowErrorStatement=>1, AutoCommit=>1, RaiseError=>1, PrintError=>0 # DSNParser:2232 23158 DBI::db=HASH(0x274e9a8) SELECT @@SQL_MODE # DSNParser:2363 23158 DBI::db=HASH(0x274e9a8) SET SESSION innodb_lock_wait_timeout=1 # DSNParser:2363 23158 DBI::db=HASH(0x274e9a8) SET SESSION lock_wait_timeout=60 # DSNParser:2363 23158 DBI::db=HASH(0x274e9a8) SET SESSION wait_timeout=10000 # DSNParser:2263 23158 DBI::db=HASH(0x274e9a8) SET @@SQL_QUOTE_SHOW_CREATE = 1/*!40101, @@SQL_MODE='NO_AUTO_VALUE_ON_ZERO'*/ # DSNParser:2272 23158 DBH info: DBI::db=HASH(0x274e9a8) $VAR1 = { # '@@hostname' => 'staging-db-slave-sphinx', # 'CONNECTION_ID()' => '1261', # 'DATABASE()' => 'howaboutwe_staging', # 'VERSION()' => '5.5.31-30.3-log' # }; # Connection info: 192.168.6.6 via TCP/IP Character set info: $VAR1 = [ # { # Value => 'latin1', # Variable_name => 'character_set_client' # }, # { # Value => 'latin1', # Variable_name => 'character_set_connection' # }, # { # Value => 'utf8', # Variable_name => 'character_set_database' # }, # { # Value => 'binary', # Variable_name => 'character_set_filesystem' # }, # { # Value => 'latin1', # Variable_name => 'character_set_results' # }, # { # Value => 'utf8', # Variable_name => 'character_set_server' # }, # { # Value => 'utf8', # Variable_name => 'character_set_system' # }, # { # Value => '/usr/share/mysql/charsets/', # Variable_name => 'character_sets_dir' # } # ]; # $DBD::mysql::VERSION: 4.020 $DBI::VERSION: 1.616 # MasterSlave:3986 23158 Connected to D=howaboutwe_staging,h=192.168.6.6,p=...,u=root # MasterSlave:3995 23158 SELECT @@SERVER_ID # MasterSlave:3997 23158 Working on server ID 2831156742 # MasterSlave:3929 23158 Found slave: D=howaboutwe_staging,h=192.168.6.6,p=...,u=root # DSNParser:2102 23158 DSN string made from options: # DSNParser:2039 23158 No DSN to parse # Cxn:3745 23158 DBI::db=HASH(0x274e9a8) Setting dbh # Cxn:3750 23158 DBI::db=HASH(0x274e9a8) SELECT @@server_id /*!50038 , @@hostname*/ # Cxn:3752 23158 DBI::db=HASH(0x274e9a8) hostname: staging-db-slave-sphinx 2831156742 # Cxn:3733 23158 DBI::db=HASH(0x274e9a8) Connected dbh to staging-db-slave-sphinx h=192.168.6.6 # MasterSlave:4030 23158 Looking for slaves on D=howaboutwe_staging,h=192.168.6.6,p=...,u=root using methods processlist hosts # MasterSlave:4037 23158 Finding slaves with _find_slaves_by_processlist # MasterSlave:4099 23158 DBI::db=HASH(0x274e9a8) SHOW GRANTS FOR CURRENT_USER() # MasterSlave:4129 23158 DBI::db=HASH(0x274e9a8) SHOW PROCESSLIST # MasterSlave:4037 23158 Finding slaves with _find_slaves_by_hosts # MasterSlave:4071 23158 DBI::db=HASH(0x274e9a8) SHOW SLAVE HOSTS # MasterSlave:4042 23158 Found 0 slaves # pt_online_schema_change:7972 23158 1 slaves found # pt_online_schema_change:7983 23158 Will check slave lag on all slaves # pt_online_schema_change:7991 23158 Checking slave replication filters # MasterSlave:4213 23158 DBI::db=HASH(0x274e9a8) SHOW MASTER STATUS # MasterSlave:4217 23158 binlog_do_db= position=61621 file=mysql-bin.000002 binlog_ignore_db= # MasterSlave:4189 23158 DBI::db=HASH(0x274e9a8) SHOW SLAVE STATUS # MasterSlave:4515 23158 DBI::db=HASH(0x274e9a8) SHOW VARIABLES LIKE 'slave_skip_errors' # MySQLStatusWaiter:4743 23158 Parsing spec for max thresholds # MySQLStatusWaiter:4885 23158 Checking and setting values # pt_online_schema_change:8070 23158 SHOW GLOBAL STATUS LIKE ? Threads_running # MySQLStatusWaiter:4901 23158 Wait if Threads_running >= 25 # MySQLStatusWaiter:4753 23158 Parsing spec for critical thresholds # MySQLStatusWaiter:4885 23158 Checking and setting values # pt_online_schema_change:8070 23158 SHOW GLOBAL STATUS LIKE ? Threads_running # MySQLStatusWaiter:4901 23158 Wait if Threads_running >= 50 # VersionCheck:6973 23158 FindBin::Bin: /usr/bin # VersionCheck:7132 23158 SELECT CONCAT(@@hostname, @@port) # VersionCheck:7153 23158 MySQL instance: 534c0d85b618351b025b3453e8291aa9 staging-db-master3306 $VAR1 = { # A => undef, # D => 'howaboutwe_staging', # F => undef, # P => undef, # S => undef, # h => undef, # p => '', # t => 'answers', # u => 'root' # }; # # VersionCheck:7132 23158 SELECT CONCAT(@@hostname, @@port) # VersionCheck:7153 23158 MySQL instance: 488620d0da07283f0e954315b692e608 staging-db-slave-sphinx3306 $VAR1 = { # A => undef, # D => 'howaboutwe_staging', # F => undef, # P => undef, # S => undef, # h => '192.168.6.6', # p => '', # t => 'answers', # u => 'root' # }; # # VersionCheck:6953 23158 Version check file percona-version-check in /tmp # VersionCheck:7067 23158 Version check file /tmp/percona-version-check contents: 0,1370470200 # 488620d0da07283f0e954315b692e608,1370470200 # 534c0d85b618351b025b3453e8291aa9,1370470200 # VersionCheck:7075 23158 Intsance 534c0d85b618351b025b3453e8291aa9 last checked 1370470200 now 1370524075 diff 53875 hours until next check 9.03 # VersionCheck:7075 23158 Intsance 488620d0da07283f0e954315b692e608 last checked 1370470200 now 1370524075 diff 53875 hours until next check 9.03 # VersionCheck:7075 23158 Intsance 0 last checked 1370470200 now 1370524075 diff 53875 hours until next check 9.03 # VersionCheck:6996 23158 0 instances to check # TableParser:3234 23158 Checking `howaboutwe_staging`.`answers` # TableParser:3238 23158 SHOW TABLES FROM `howaboutwe_staging` LIKE 'answers' # TableParser:3252 23158 Table howaboutwe_staging answers exists # pt_online_schema_change:9638 23158 SHOW TRIGGERS FROM `howaboutwe_staging` LIKE 'answers' # TableParser:3063 23158 /*!40101 SET @OLD_SQL_MODE := @@SQL_MODE, @@SQL_MODE := '', @OLD_QUOTE := @@SQL_QUOTE_SHOW_CREATE, @@SQL_QUOTE_SHOW_CREATE := 1 */ # TableParser:3068 23158 DBI::db=HASH(0x26b7050) USE `howaboutwe_staging` # TableParser:3072 23158 SHOW CREATE TABLE `howaboutwe_staging`.`answers` # TableParser:3082 23158 /*!40101 SET @@SQL_MODE := @OLD_SQL_MODE, @@SQL_QUOTE_SHOW_CREATE := @OLD_QUOTE */ # TableParser:3260 23158 Storage engine: InnoDB # TableParser:3114 23158 Table cols: `id`, `content`, `question_id`, `user_id`, `created_at`, `updated_at` # TableParser:3260 23158 Storage engine: InnoDB # TableParser:3276 23158 Parsed key: PRIMARY KEY (`id`), # TableParser:3296 23158 PRIMARY key cols: `id` # TableParser:3318 23158 This key is the clustered key # TableParser:3276 23158 Parsed key: KEY `index_answers_on_question_id` (`question_id`), # TableParser:3296 23158 index_answers_on_question_id key cols: `question_id` # TableParser:3276 23158 Parsed key: KEY `index_answers_on_user_id` (`user_id`), # TableParser:3296 23158 index_answers_on_user_id key cols: `user_id` # TableParser:3276 23158 Parsed key: KEY `index_answers_on_question_id_and_user_id` (`question_id`,`user_id`), # TableParser:3296 23158 index_answers_on_question_id_and_user_id key cols: `question_id`, `user_id` # TableParser:3276 23158 Parsed key: KEY `index_answers_on_updated_at` (`updated_at`) # TableParser:3296 23158 index_answers_on_updated_at key cols: `updated_at` # NibbleIterator:5498 23158 EXPLAIN SELECT * FROM `howaboutwe_staging`.`answers` WHERE 1=1 # NibbleIterator:5500 23158 $VAR1 = { # extra => '', # id => '1', # key => undef, # key_len => undef, # possible_keys => undef, # ref => undef, # rows => '2677209', # select_type => 'SIMPLE', # table => 'answers', # type => 'ALL' # }; # # NibbleIterator:5375 23158 One nibble: no # NibbleIterator:5430 23158 Auto-selecting best index # TableParser:3175 23158 Indexes sorted best-first: PRIMARY, index_answers_on_question_id, index_answers_on_updated_at, index_answers_on_user_id, index_answers_on_question_id_and_user_id # NibbleIterator:5463 23158 Best index: PRIMARY Operation, tries, wait: copy_rows, 10, 0.25 create_triggers, 10, 1 drop_triggers, 10, 1 swap_tables, 10, 1 update_foreign_keys, 10, 1 # pt_online_schema_change:9685 23158 Finding child tables # pt_online_schema_change:9691 23158 SELECT table_schema, table_name FROM information_schema.key_column_usage WHERE constraint_schema='howaboutwe_staging' AND referenced_table_name='answers' # pt_online_schema_change:9694 23158 No child tables found Altering `howaboutwe_staging`.`answers`... # CleanupTask:6070 23158 Created cleanup task CODE(0x27614c8) # pt_online_schema_change:9372 23158 Renamed columns (old => new): $VAR1 = {}; # # Percona::XtraDB::Cluster:7531 23158 staging-db-master SHOW VARIABLES LIKE 'wsrep_on' # Percona::XtraDB::Cluster:7533 23158 $VAR1 = undef; # # TableParser:3063 23158 /*!40101 SET @OLD_SQL_MODE := @@SQL_MODE, @@SQL_MODE := '', @OLD_QUOTE := @@SQL_QUOTE_SHOW_CREATE, @@SQL_QUOTE_SHOW_CREATE := 1 */ # TableParser:3068 23158 DBI::db=HASH(0x26b7050) USE `howaboutwe_staging` # TableParser:3072 23158 SHOW CREATE TABLE `howaboutwe_staging`.`answers` # TableParser:3082 23158 /*!40101 SET @@SQL_MODE := @OLD_SQL_MODE, @@SQL_QUOTE_SHOW_CREATE := @OLD_QUOTE */ Creating new table... # pt_online_schema_change:9497 23158 CREATE TABLE `howaboutwe_staging`.`_answers_new` ( # `id` int(11) NOT NULL AUTO_INCREMENT, # `content` text, # `question_id` int(11) DEFAULT NULL, # `user_id` int(11) DEFAULT NULL, # `created_at` datetime DEFAULT NULL, # `updated_at` datetime DEFAULT NULL, # PRIMARY KEY (`id`), # KEY `index_answers_on_question_id` (`question_id`), # KEY `index_answers_on_user_id` (`user_id`), # KEY `index_answers_on_question_id_and_user_id` (`question_id`,`user_id`), # KEY `index_answers_on_updated_at` (`updated_at`) # ) ENGINE=InnoDB AUTO_INCREMENT=2859784 DEFAULT CHARSET=utf8 Created new table howaboutwe_staging._answers_new OK. # pt_online_schema_change:8438 23158 Waiting until staging-db-slave-sphinx replicates the table # TableParser:3234 23158 Checking `howaboutwe_staging`.`_answers_new` # TableParser:3238 23158 SHOW TABLES FROM `howaboutwe_staging` LIKE '\_answers\_new' # TableParser:3252 23158 Table howaboutwe_staging _answers_new exists Altering new table... # pt_online_schema_change:8470 23158 ALTER TABLE `howaboutwe_staging`.`_answers_new` MODIFY content VARCHAR(512) NOT NULL Altered `howaboutwe_staging`.`_answers_new` OK. # TableParser:3063 23158 /*!40101 SET @OLD_SQL_MODE := @@SQL_MODE, @@SQL_MODE := '', @OLD_QUOTE := @@SQL_QUOTE_SHOW_CREATE, @@SQL_QUOTE_SHOW_CREATE := 1 */ # TableParser:3068 23158 DBI::db=HASH(0x26b7050) USE `howaboutwe_staging` # TableParser:3072 23158 SHOW CREATE TABLE `howaboutwe_staging`.`_answers_new` # TableParser:3082 23158 /*!40101 SET @@SQL_MODE := @OLD_SQL_MODE, @@SQL_QUOTE_SHOW_CREATE := @OLD_QUOTE */ # TableParser:3260 23158 Storage engine: InnoDB # TableParser:3114 23158 Table cols: `id`, `content`, `question_id`, `user_id`, `created_at`, `updated_at` # TableParser:3260 23158 Storage engine: InnoDB # TableParser:3276 23158 Parsed key: PRIMARY KEY (`id`), # TableParser:3296 23158 PRIMARY key cols: `id` # TableParser:3318 23158 This key is the clustered key # TableParser:3276 23158 Parsed key: KEY `index_answers_on_question_id` (`question_id`), # TableParser:3296 23158 index_answers_on_question_id key cols: `question_id` # TableParser:3276 23158 Parsed key: KEY `index_answers_on_user_id` (`user_id`), # TableParser:3296 23158 index_answers_on_user_id key cols: `user_id` # TableParser:3276 23158 Parsed key: KEY `index_answers_on_question_id_and_user_id` (`question_id`,`user_id`), # TableParser:3296 23158 index_answers_on_question_id_and_user_id key cols: `question_id`, `user_id` # TableParser:3276 23158 Parsed key: KEY `index_answers_on_updated_at` (`updated_at`) # TableParser:3296 23158 index_answers_on_updated_at key cols: `updated_at` # pt_online_schema_change:8504 23158 Common columns $VAR1 = [ # { # new => 'id', # old => 'id' # }, # { # new => 'content', # old => 'content' # }, # { # new => 'question_id', # old => 'question_id' # }, # { # new => 'user_id', # old => 'user_id' # }, # { # new => 'created_at', # old => 'created_at' # }, # { # new => 'updated_at', # old => 'updated_at' # } # ]; # # TableParser:3175 23158 Indexes sorted best-first: PRIMARY, index_answers_on_question_id, index_answers_on_updated_at, index_answers_on_user_id, index_answers_on_question_id_and_user_id # pt_online_schema_change:8513 23158 Delete trigger new index: $VAR1 = 'PRIMARY'; # # pt_online_schema_change:8518 23158 New table delete index: PRIMARY # TableParser:3175 23158 Indexes sorted best-first: PRIMARY, index_answers_on_question_id, index_answers_on_updated_at, index_answers_on_user_id, index_answers_on_question_id_and_user_id # pt_online_schema_change:8525 23158 Delete trigger orig index: $VAR1 = 'PRIMARY'; # # pt_online_schema_change:8530 23158 Orig table delete index: PRIMARY # pt_online_schema_change:8572 23158 Index for delete trigger: table `howaboutwe_staging`.`_answers_new` index PRIMARY columns id Creating triggers... # Retry:3610 23158 Try 1 of 10 # pt_online_schema_change:9990 23158 CREATE TRIGGER `pt_osc_howaboutwe_staging_answers_del` AFTER DELETE ON `howaboutwe_staging`.`answers` FOR EACH ROW DELETE IGNORE FROM `howaboutwe_staging`.`_answers_new` WHERE `howaboutwe_staging`.`_answers_new`.`id` <=> OLD.`id` # Retry:3627 23158 Try code succeeded # Retry:3610 23158 Try 1 of 10 # pt_online_schema_change:9990 23158 CREATE TRIGGER `pt_osc_howaboutwe_staging_answers_upd` AFTER UPDATE ON `howaboutwe_staging`.`answers` FOR EACH ROW REPLACE INTO `howaboutwe_staging`.`_answers_new` (`id`, `content`, `question_id`, `user_id`, `created_at`, `updated_at`) VALUES (NEW.`id`, NEW.`content`, NEW.`question_id`, NEW.`user_id`, NEW.`created_at`, NEW.`updated_at`) # Retry:3627 23158 Try code succeeded # Retry:3610 23158 Try 1 of 10 # pt_online_schema_change:9990 23158 CREATE TRIGGER `pt_osc_howaboutwe_staging_answers_ins` AFTER INSERT ON `howaboutwe_staging`.`answers` FOR EACH ROW REPLACE INTO `howaboutwe_staging`.`_answers_new` (`id`, `content`, `question_id`, `user_id`, `created_at`, `updated_at`) VALUES (NEW.`id`, NEW.`content`, NEW.`question_id`, NEW.`user_id`, NEW.`created_at`, NEW.`updated_at`) # Retry:3627 23158 Try code succeeded Created triggers OK. # NibbleIterator:5498 23158 EXPLAIN SELECT * FROM `howaboutwe_staging`.`answers` WHERE 1=1 # NibbleIterator:5500 23158 $VAR1 = { # extra => '', # id => '1', # key => undef, # key_len => undef, # possible_keys => undef, # ref => undef, # rows => '2742684', # select_type => 'SIMPLE', # table => 'answers', # type => 'ALL' # }; # # NibbleIterator:5375 23158 One nibble: no # NibbleIterator:5430 23158 Auto-selecting best index # TableParser:3175 23158 Indexes sorted best-first: PRIMARY, index_answers_on_question_id, index_answers_on_updated_at, index_answers_on_user_id, index_answers_on_question_id_and_user_id # NibbleIterator:5463 23158 Best index: PRIMARY # TableNibbler:2787 23158 Will ascend index PRIMARY # TableNibbler:2799 23158 Will ascend columns id # TableNibbler:2810 23158 Will ascend, in ordinal position: 0 # NibbleIterator:5080 23158 Ascend params: $VAR1 = { # boundaries => { # '<' => '((`id` < ?))', # '<=' => '((`id` <= ?))', # '>' => '((`id` > ?))', # '>=' => '((`id` >= ?))' # }, # cols => [ # 'id', # 'content', # 'question_id', # 'user_id', # 'created_at', # 'updated_at' # ], # index => 'PRIMARY', # scols => [ # 'id' # ], # slice => [ # 0 # ], # where => '((`id` > ?))' # }; # # NibbleIterator:5093 23158 First lower boundary statement: SELECT /*!40001 SQL_NO_CACHE */ `id` FROM `howaboutwe_staging`.`answers` FORCE INDEX(`PRIMARY`) ORDER BY `id` LIMIT 1 /*first lower boundary*/ # NibbleIterator:5118 23158 Last upper boundary statement: SELECT /*!40001 SQL_NO_CACHE */ `id` FROM `howaboutwe_staging`.`answers` FORCE INDEX(`PRIMARY`) ORDER BY `id` DESC LIMIT 1 /*last upper boundary*/ # NibbleIterator:5129 23158 Upper boundary statement: SELECT /*!40001 SQL_NO_CACHE */ `id` FROM `howaboutwe_staging`.`answers` FORCE INDEX(`PRIMARY`) WHERE ((`id` >= ?)) ORDER BY `id` LIMIT ?, 2 /*next chunk boundary*/ # NibbleIterator:5142 23158 Nibble statement: INSERT LOW_PRIORITY IGNORE INTO `howaboutwe_staging`.`_answers_new` (`id`, `content`, `question_id`, `user_id`, `created_at`, `updated_at`) SELECT `id`, `content`, `question_id`, `user_id`, `created_at`, `updated_at` FROM `howaboutwe_staging`.`answers` FORCE INDEX(`PRIMARY`) WHERE ((`id` >= ?)) AND ((`id` <= ?)) LOCK IN SHARE MODE /*pt-online-schema-change 23158 copy nibble*/ # NibbleIterator:5155 23158 Explain nibble statement: EXPLAIN SELECT `id`, `content`, `question_id`, `user_id`, `created_at`, `updated_at` FROM `howaboutwe_staging`.`answers` FORCE INDEX(`PRIMARY`) WHERE ((`id` >= ?)) AND ((`id` <= ?)) LOCK IN SHARE MODE /*explain pt-online-schema-change 23158 copy nibble*/ # NibbleIterator:5158 23158 Initial chunk size (LIMIT): 999 # NibbleIterator:5510 23158 Preparing statement handles # NibbleIterator:5539 23158 First lower boundary: $VAR1 = [ # '2' # ]; # # NibbleIterator:5555 23158 Next lower boundary: $VAR1 = [ # '2' # ]; # Copying approximately 2742684 rows... # IndexLength:6205 23158 SELECT /*!40001 SQL_NO_CACHE */ `id` FROM `howaboutwe_staging`.`answers` FORCE INDEX (`PRIMARY`) WHERE `id` IS NOT NULL ORDER BY `id` LIMIT 1 /*key_len*/ # IndexLength:6172 23158 EXPLAIN SELECT /*!40001 SQL_NO_CACHE */ * FROM `howaboutwe_staging`.`answers` FORCE INDEX (`PRIMARY`) WHERE `id` >= ? /*key_len*/ params: 2 # IndexLength:6176 23158 Range scan: $VAR1 = { # extra => 'Using where', # id => '1', # key => 'PRIMARY', # key_len => '4', # possible_keys => 'PRIMARY', # ref => undef, # rows => '1371342', # select_type => 'SIMPLE', # table => 'answers', # type => 'range' # }; # # NibbleIterator:5210 23158 init callback returned 1 # pt_online_schema_change:10288 23158 EXPLAIN SELECT /*!40001 SQL_NO_CACHE */ `id` FROM `howaboutwe_staging`.`answers` FORCE INDEX(`PRIMARY`) WHERE ((`id` >= ?)) ORDER BY `id` LIMIT ?, 2 /*next chunk boundary*/ params: 2 999 # pt_online_schema_change:10297 23158 EXPLAIN plan: $VAR1 = { # extra => 'Using where; Using index', # id => '1', # key => 'PRIMARY', # key_len => '4', # possible_keys => 'PRIMARY', # ref => undef, # rows => '1371342', # select_type => 'SIMPLE', # table => 'answers', # type => 'range' # }; # # NibbleIterator:5610 23158 next_boundaries callback returned 1 # NibbleIterator:5619 23158 SELECT /*!40001 SQL_NO_CACHE */ `id` FROM `howaboutwe_staging`.`answers` FORCE INDEX(`PRIMARY`) WHERE ((`id` >= ?)) ORDER BY `id` LIMIT ?, 2 /*next chunk boundary*/ params: 2 999 # NibbleIterator:5622 23158 Next boundary: $VAR1 = [ # [ # '1260' # ], # [ # '1261' # ] # ]; # # NibbleIterator:5228 23158 Nibble: INSERT LOW_PRIORITY IGNORE INTO `howaboutwe_staging`.`_answers_new` (`id`, `content`, `question_id`, `user_id`, `created_at`, `updated_at`) SELECT `id`, `content`, `question_id`, `user_id`, `created_at`, `updated_at` FROM `howaboutwe_staging`.`answers` FORCE INDEX(`PRIMARY`) WHERE ((`id` >= ?)) AND ((`id` <= ?)) LOCK IN SHARE MODE /*pt-online-schema-change 23158 copy nibble*/ params: 2, 1260 # pt_online_schema_change:10288 23158 EXPLAIN SELECT `id`, `content`, `question_id`, `user_id`, `created_at`, `updated_at` FROM `howaboutwe_staging`.`answers` FORCE INDEX(`PRIMARY`) WHERE ((`id` >= ?)) AND ((`id` <= ?)) LOCK IN SHARE MODE /*explain pt-online-schema-change 23158 copy nibble*/ params: 2 1260 # pt_online_schema_change:10297 23158 EXPLAIN plan: $VAR1 = { # extra => 'Using where', # id => '1', # key => 'PRIMARY', # key_len => '4', # possible_keys => 'PRIMARY', # ref => undef, # rows => '999', # select_type => 'SIMPLE', # table => 'answers', # type => 'range' # }; # # Quoter:2683 23158 Serializing $VAR1 = [ # '2' # ]; # # Quoter:2699 23158 Serialized: < 2 > # Quoter:2683 23158 Serializing $VAR1 = [ # '1260' # ]; # # Quoter:2699 23158 Serialized: < 1260 > # Retry:3610 23158 Try 1 of 10 # pt_online_schema_change:10198 23158 INSERT LOW_PRIORITY IGNORE INTO `howaboutwe_staging`.`_answers_new` (`id`, `content`, `question_id`, `user_id`, `created_at`, `updated_at`) SELECT `id`, `content`, `question_id`, `user_id`, `created_at`, `updated_at` FROM `howaboutwe_staging`.`answers` FORCE INDEX(`PRIMARY`) WHERE ((`id` >= ?)) AND ((`id` <= ?)) LOCK IN SHARE MODE /*pt-online-schema-change 23158 copy nibble*/ lower boundary: 2 upper boundary: 1260 # pt_online_schema_change:10217 23158 SHOW WARNINGS # Retry:3616 23158 Try code failed: Undefined subroutine &pt_online_schema_change::get called at /usr/bin/pt-online-schema-change line 10238. # # pt_online_schema_change:10099 23158 Retry fail: Undefined subroutine &pt_online_schema_change::get called at /usr/bin/pt-online-schema-change line 10238. # # Retry:3632 23158 Try code did not succeed # CleanupTask:6078 23158 Calling cleanup task CODE(0x27614c8) # pt_online_schema_change:8596 23158 Clean up triggers Dropping triggers... # Retry:3610 23158 Try 1 of 10 # pt_online_schema_change:10040 23158 DROP TRIGGER IF EXISTS `howaboutwe_staging`.`pt_osc_howaboutwe_staging_answers_del`; # Retry:3627 23158 Try code succeeded # Retry:3610 23158 Try 1 of 10 # pt_online_schema_change:10040 23158 DROP TRIGGER IF EXISTS `howaboutwe_staging`.`pt_osc_howaboutwe_staging_answers_upd`; # Retry:3627 23158 Try code succeeded # Retry:3610 23158 Try 1 of 10 # pt_online_schema_change:10040 23158 DROP TRIGGER IF EXISTS `howaboutwe_staging`.`pt_osc_howaboutwe_staging_answers_ins`; # Retry:3627 23158 Try code succeeded Dropped triggers OK. # pt_online_schema_change:8393 23158 Clean up new table # TableParser:3234 23158 Checking `howaboutwe_staging`.`_answers_new` # TableParser:3238 23158 SHOW TABLES FROM `howaboutwe_staging` LIKE '\_answers\_new' # TableParser:3252 23158 Table howaboutwe_staging _answers_new exists # pt_online_schema_change:8399 23158 New table exists: yes Dropping new table... # pt_online_schema_change:8425 23158 DROP TABLE IF EXISTS `howaboutwe_staging`.`_answers_new`; Dropped new table OK. # pt_online_schema_change:8278 23158 Clean up done, report if orig table was altered `howaboutwe_staging`.`answers` was not altered. (in cleanup) Error copying rows from `howaboutwe_staging`.`answers` to `howaboutwe_staging`.`_answers_new`: Undefined subroutine &pt_online_schema_change::get called at /usr/bin/pt-online-schema-change line 10238. # NibbleIterator:5669 23158 Finish explain_first_lb_sth # NibbleIterator:5669 23158 Finish nibble_sth # NibbleIterator:5669 23158 Finish ub_sth # NibbleIterator:5669 23158 Finish explain_nibble_sth # NibbleIterator:5669 23158 Finish explain_ub_sth # Cxn:3823 23158 Destroying cxn # Cxn:3832 23158 DBI::db=HASH(0x274e9a8) Disconnecting dbh on staging-db-slave-sphinx h=192.168.6.6 # Cxn:3823 23158 Destroying cxn # Cxn:3832 23158 DBI::db=HASH(0x26849e0) Disconnecting dbh on staging-db-master # CleanupTask:6078 23158 Calling cleanup task CODE(0x27614c8) # pt_online_schema_change:8596 23158 Clean up triggers Dropping triggers... # Retry:3610 23158 Try 1 of 10 # pt_online_schema_change:10040 23158 DROP TRIGGER IF EXISTS `howaboutwe_staging`.`pt_osc_howaboutwe_staging_answers_del`; # Retry:3627 23158 Try code succeeded # Retry:3610 23158 Try 1 of 10 # pt_online_schema_change:10040 23158 DROP TRIGGER IF EXISTS `howaboutwe_staging`.`pt_osc_howaboutwe_staging_answers_upd`; # Retry:3627 23158 Try code succeeded # Retry:3610 23158 Try 1 of 10 # pt_online_schema_change:10040 23158 DROP TRIGGER IF EXISTS `howaboutwe_staging`.`pt_osc_howaboutwe_staging_answers_ins`; # Retry:3627 23158 Try code succeeded Dropped triggers OK. # pt_online_schema_change:8393 23158 Clean up new table # TableParser:3234 23158 Checking `howaboutwe_staging`.`_answers_new` # TableParser:3238 23158 SHOW TABLES FROM `howaboutwe_staging` LIKE '\_answers\_new' # TableParser:3248 23158 Table does not exist # pt_online_schema_change:8399 23158 New table exists: no # pt_online_schema_change:8278 23158 Clean up done, report if orig table was altered `howaboutwe_staging`.`answers` was not altered. # Cxn:3823 23158 Destroying cxn # Cxn:3832 23158 DBI::db=HASH(0x26b7050) Disconnecting dbh on staging-db-master