Brian Fraser
9ae940cd76
PerconaTest: Add load_data_is_disabled and correct full_output
...
load_data_is_disabled checks if LOAD DATA LOCAL INFILE is disabled;
it'll be used in the future by a couple of tests.
full_output was changed to use two different filehandles for STDOUT
and STDERR; THis is because otherwise, code closing STDOUT (like
the --quiet option in pt-osc) would also accidentally close STDERR.
2012-07-11 17:29:04 -03:00
Brian Fraser
f30c50be44
Updated the fles in /lib to use the new VersionParser
2012-07-11 15:10:33 -03:00
Brian Fraser
acd5281e3c
Redesigned VersionParser.
...
Now using Mo and overloading, so that $version_object < 5.1
is the new way to test things.
2012-07-11 15:05:00 -03:00
Brian Fraser
bcc618ba5b
Fixup: A mistakenly moved BEGIN { was breaking things
2012-07-11 15:04:50 -03:00
Brian Fraser
c012159989
Make Mo add itself to %INC
2012-07-11 12:25:54 -03:00
Brian Fraser
1a217a1eec
Add Mo to lib/
2012-07-11 12:24:29 -03:00
Daniel Nichter
7813aeef55
eval tput which fails if TERM isn't set, like when ran via Jenkins.
2012-07-09 15:59:00 -06:00
Daniel Nichter
938b9720c1
Add RawLogParser.pm and implement --type rawlog in pt-query-digest (Percona 22371).
2012-06-28 15:04:10 -06:00
Daniel Nichter
d7099496ca
Add Cxn::is_cluster_node(). Add /*!99997*/ to SELECT..INSERT if the master is a cluster ndoe.
2012-06-27 11:57:08 -06:00
Brian Fraser fraserb@gmail.com
c87235b0ff
Fix 984915: DSNParser does not check return value of do() calls
2012-06-11 22:02:49 -03:00
Daniel Nichter
18073bd7a2
Remove --[no]zero-bool from pt-query-digest.
2012-06-11 20:43:05 -04:00
Brian Fraser fraserb@gmail.com
bc8f5a610c
Change TMPDIR to PT_TMPDIR
2012-06-11 17:51:43 -03:00
Daniel Nichter
bf2a769536
Export TMPDIR to make tmpdir.t pass.
2012-06-11 13:28:14 -07:00
Brian Fraser fraserb@gmail.com
07081d5761
tmpdir.sh: Use the -t flag for mktemp
2012-06-11 17:07:38 -03:00
Brian Fraser fraserb@gmail.com
d387b22c07
Bug 1007938: MySQLConfig doesn't support end-of-line comments
...
Patch provided by Kaiwang CHEN (~kaiwang-chen) on Launchpad.
2012-06-11 12:33:45 -03:00
Brian Fraser fraserb@gmail.com
87f32cc857
Sandbox.pm: Catch errors from shelled-out commands
2012-06-11 11:50:52 -03:00
Daniel Nichter
583bc2957e
Don't crash if N is > number of index columns.
2012-06-11 07:55:23 -04:00
Daniel Nichter
12f98d771e
Merge detect-key-len-with-range-scan.
2012-06-11 13:04:54 -04:00
Daniel Nichter
3f2295ec46
Implement IndexLength in pt-table-checksum and pt-online-schema-change. Tag the IndexLength queries with "key_len" and make n_index_cols optional--get full key_len if not given.
2012-06-11 12:54:26 -04:00
Daniel Nichter
fa9cf03505
Add IndexLength.pm.
2012-06-11 11:47:03 -04:00
Daniel Nichter
970f7d7e64
Merge ~percona-toolkit-dev/percona-toolkit/explain-checksum-chunks.
2012-06-10 13:25:44 -04:00
Daniel Nichter
272f963733
Remove --chunk-index-columns and extend --chunk-index instead to take INDEX:N value. Add n_index_values to TableNibbler.
2012-06-10 10:01:25 -04:00
Daniel Nichter
2a92a0a0ff
Check key_len for each chunk to ensure it doesn't decrease. Add --[no]check-plan.
2012-06-09 22:23:00 -04:00
Baron Schwartz
47fb3d65e8
Fix a bazillion tests with ANSI sql_mode, and get rid of a bunch of MySQLDump usage.
2012-06-09 14:43:33 -04:00
Baron Schwartz
8e9dfeec68
Some fixes for ANSI SQL quotes
2012-06-07 14:53:47 -04:00
Baron Schwartz
f7c97e749e
Make TableParser.pm handle ANSI quotes
2012-06-07 00:59:59 -04:00
Brian Fraser fraserb@gmail.com
63b31873e5
PerconaTest::full_output: Fix a bug in the returned status
2012-06-07 17:43:50 -03:00
Baron Schwartz
aa42210f72
Fix a number of SQL queries to work with ANSI_QUOTES
2012-06-06 23:36:07 -04:00
Baron Schwartz
b9304dabb5
Fix a number of SQL queries to work with ANSI_QUOTES
2012-06-06 23:14:20 -04:00
Daniel Nichter
79c716d358
Remove pt-table-sync/issue_79.t (it was broken but coincidentally working) and write better tests in filters.t. Add subs to Sandbox and PerconaTest to clear and parse tables used from the general logs. Set log=genlog in the sandbox configs.
2012-06-07 12:38:45 -04:00
Brian Fraser fraserb@gmail.com
03a9461daf
Removed PerconaTest::{wait_until_no_lag|wait_until_slaves_running}, replaced them with Sandbox::wait_for_slaves
2012-06-07 12:00:40 -03:00
Baron Schwartz
af38351e82
wait for slaves after load_file
2012-06-06 16:32:14 -04:00
Brian Fraser fraserb@gmail.com
a0a42eebe8
Bug #995896 : Useless use of cat in Daemon.pm
2012-06-06 14:19:27 -03:00
Brian Fraser fraserb@gmail.com
c2bb24befc
Merged lp:~percona-toolkit-dev/percona-toolkit/replace-MKDEBUG
2012-06-06 14:15:05 -03:00
Brian Fraser fraserb@gmail.com
3babaab15a
Merged lp:~percona-toolkit-dev/percona-toolkit/pt-osc-cleanup-guards
2012-06-06 11:50:00 -03:00
Daniel Nichter
f4b3bdb88b
Use just RAND() instead of RAND() + NOW() to avoid be coerced to an int and therefore not sub-second safe.
2012-06-06 13:52:17 -07:00
Daniel Nichter
a178bb32f8
Use md5 "pings" in percona_test.sentinel for sub-second tests that call wipe_clean() twice. Update t/lib/samples/SchemaIterator/all-dbs-tbls-5.0.txt for percona_test.sentinel. Restart slaves in pt-table-checksum/replication_filters.t. Modernize and make pt-table-sync/replicate_do_db.t stable.
2012-06-06 13:31:24 -07:00
Daniel Nichter
14b615ebd9
5s default wait_until() time. Wait 5m instead of 16m for wipe_clean(). Don't connect to slave2 in wipe_clean() any longer.
2012-06-06 11:43:56 -07:00
Baron Schwartz
9865ad451d
add sanity checks and slave-lag synchronization to prevent replication breakage, false sandbox breakage, etc.
2012-06-06 04:47:45 -04:00
Daniel Nichter
48677eb4d1
All Test::More::diag() in Sandbox.pm instead of just diag().
2012-06-05 19:56:46 -07:00
Daniel Nichter
0e4b01bad7
Make wipe_clean() wait until 12347 is clean. Fix ChangeHandler.t, CompareResults.t, and Quoter.t so they leave the dbs clean.
2012-06-05 19:55:03 -07:00
Daniel Nichter
2d7cc5e8a4
Check for leftover databases. Fix MasterSlave.t so it doesn't leave leftover dbs and it resets 12347.
2012-06-05 18:55:32 -07:00
Brian Fraser fraserb@gmail.com
e57b67f10e
Cxn & pt-osc: Guard the cleanup tasks.
...
Does this twofold: By adding a __DIE__ hook to make sure they are
called, and by checking that the dbh is an actual database handle.
2012-06-05 16:24:32 -03:00
Daniel Nichter
ac620957c9
Print on which host tables are different.
2012-06-05 11:20:18 -07:00
Daniel Nichter
a44a273800
Revert back to ok() for Sandbox::ok() so tests file don't have to be updated. Shorten verify_test_data_integrity() to verify_test_data().
2012-06-05 11:02:48 -07:00
Daniel Nichter
b96e43419f
Merge ~percona-toolkit-dev/percona-toolkit/fix-ptc-checksum-tbl-bug-1008778.
2012-06-05 13:08:21 -04:00
Daniel Nichter
4f83cf4102
Wait for --replicate table to repl on all slaves. Add wait_for arg to PerconaTest::full_output().
2012-06-05 12:29:26 -04:00
Brian Fraser fraserb@gmail.com
345a21a82e
Replace the last instances of MKDEBUG
2012-06-05 12:28:36 -03:00
Brian Fraser fraserb@gmail.com
6b93d51e43
ReadKeyMini: Restore STDIN flags in cooked()
...
This will probably resolve bug #946707 : pt-sift loses STDIN after pt-diskstats
2012-06-05 12:16:49 -03:00
baron
95f7e53feb
simplify and clean up sandbox/test-env a little, also helps prevent error messages like this when running test-env: [Warning] option 'thread_stack': unsigned value 126976 adjusted to 131072
2012-06-05 10:22:04 -04:00