Percona QA is a suite of scripts and utilities that assists in building, continuous integration, automated testing & bug reporting for Percona Server, Percona XtraDB Cluster, Percona Server for MongoDB, as well as other flavors of MySQL (Oracle, Facebook MyQSL, WebScaleSQL, MariaDB) etc.
PLpgSQL Shell Python C C++ Perl
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
TB_XB_test_scripts Removing AutoTokubackup project for issue #52 Feb 20, 2017
audit-log-tests
docker-garbd lp:percona-qa migration to github:/Percona-QA/percona-qa Oct 1, 2015
fuzzer Some KW fixes (old), handy gnu updates Apr 9, 2018
generator Added pwgen random text to generator.sh (PQA-276), Improved generator… May 21, 2018
homedir_scripts pquery-clean-known++.sh minor help text updates, expanded pquery-prep… May 19, 2018
myrocks-tests Preliminary fix for issue #247 (#248) Nov 8, 2017
old_files pquery binary mods Aug 26, 2016
pmm-tests implmeneted client's upgrade Jun 6, 2018
pquery-sb Various updates; build script minor patch, Fuzzer - many updates, han… Mar 22, 2018
pquery mtr_to_sql.sh small improvement, main sql file update with JSON in ME… May 21, 2018
pty Adding pty utility (see https://bitbucket.org/elliottslaughter/pty) b… May 24, 2016
pxc-tests Adding pxc-quick-start.sh script to start PXC with configuration file… May 28, 2018
sample_db Small update Jun 24, 2016
sysbench_scripts
5.6_regression_baseline.txt lp:percona-qa migration to github:/Percona-QA/percona-qa Oct 1, 2015
56_cross_upgrade.sh Big end-spaces code cleanup May 16, 2018
57_cross_upgrade.sh
ASAN_bugs_info.txt
LICENSE.md Update LICENSE.md Sep 30, 2015
MOVED lp:percona-qa migration to github:/Percona-QA/percona-qa Oct 1, 2015
MyRocks.sql Fix newline Jul 28, 2017
MyRocks_TokuDB.sql
PQUERY-HOWTO lp:percona-qa migration to github:/Percona-QA/percona-qa Oct 1, 2015
README.md Update README.md Feb 27, 2018
TokuDB.sql lp:percona-qa migration to github:/Percona-QA/percona-qa Oct 1, 2015
TokuMXse_bug_report.sh Big end-spaces code cleanup May 16, 2018
adding_asserts.txt Adding newly compiled pquery-ws, moving old one, other textual updates Jan 3, 2016
alldiffs.sh Big end-spaces code cleanup May 16, 2018
analyze_subdir_cores.sh Big end-spaces code cleanup May 16, 2018
ansible_info.txt
basedir-create-bundle.sh Big end-spaces code cleanup May 16, 2018
build_5.x_debug.sh Big end-spaces code cleanup May 16, 2018
build_5.x_debug_5.6_for_pxb_tests.sh Preliminary fix for issue #234 (#235) Oct 16, 2017
build_5.x_debug_5.7_for_pxb_tests.sh Preliminary fix for issue #234 (#235) Oct 16, 2017
build_5.x_debug_for_audit_plugin.sh
build_5.x_opt.sh
build_5.x_valgrid.sh Make build scripts bit safer Jul 24, 2017
build_mariadb_debug.sh Big end-spaces code cleanup May 16, 2018
build_postgresql_debug.sh Added build_postgresql_debug.sh for creating Postgres debug build bin… Apr 2, 2018
build_xtrabackup.sh Big end-spaces code cleanup May 16, 2018
check-security.sh Big end-spaces code cleanup May 16, 2018
clean_tree.sh
codership-binary.sh
codership6-binary.sh
deadlocks_vs_hangs.txt Adding deadlocks_vs_hangs.txt Oct 26, 2016
debugging_gdb.txt debugging_gdb.txt added Jun 30, 2017
diffit.sh Changes in diffit.sh script for query correctness testing Oct 13, 2017
docker_info.txt Minor Docker help text update Jan 9, 2017
dockerstop.sh Bugfix for pquery-results.sh to properly scan matching trials with a … Dec 29, 2017
download_launchpad_single_file.sh Big end-spaces code cleanup May 16, 2018
download_rpmdeb.sh Big end-spaces code cleanup May 16, 2018
extract_query.gdb
filter_review_LP.sh Adding filter_review_LP.sh - a script which automatically scans LP bu… Oct 5, 2016
find_testcases.sh Adding find_testcases.sh & bug update Oct 7, 2016
flamegraph.txt Added info on howto create flame graphs Jul 27, 2017
fuzzer-changed-PS-code.patch Improved pquery-run.sh to log disk related errors to output log Feb 16, 2018
fuzzer-crashes.sh analyze_subdir_cores.sh file name fix Feb 7, 2018
fuzzer-run.sh Big end-spaces code cleanup May 16, 2018
fuzzer-sql-now.sh Added fuzzer-crashes.sh and other updates Feb 7, 2018
get_download_link.sh Fix get_download_link.sh for PS 5.5/5.6 May 15, 2018
get_percona.sh
handy_gnu.txt
handy_postgresql.txt
how_to_build_valgrind.txt Adding how_to_build_valgrind.txt Nov 14, 2016
hung_mysqld.gdb lp:percona-qa migration to github:/Percona-QA/percona-qa Oct 1, 2015
hw-info.sh lp:percona-qa migration to github:/Percona-QA/percona-qa Oct 1, 2015
isthisascreen.sh Adding isthisascreen.sh. run it to see if you're in a screen session … May 31, 2016
kill_all_procs.sh More updates/fixes/improvements to multirun_mysqld, small reducer.sh … Jul 21, 2017
kill_mysqld_procs.sh lp:percona-qa migration to github:/Percona-QA/percona-qa Oct 1, 2015
known_bugs.strings Merge branch 'master' of https://github.com/Percona-QA/percona-qa May 21, 2018
known_bugs.strings.notestcase
known_bugs_asan.strings First attempt at ASAN list Oct 8, 2016
known_bugs_fb.strings
known_bugs_pxc.strings PXC bug updates May 30, 2018
known_bugs_tokumxse.strings lp:percona-qa migration to github:/Percona-QA/percona-qa Oct 1, 2015
ldd_files.sh Big end-spaces code cleanup May 16, 2018
lp-bug-add-file.py lp:percona-qa migration to github:/Percona-QA/percona-qa Oct 1, 2015
lp-bug-logger.sh Big end-spaces code cleanup May 16, 2018
maria-galera-startup.sh 10K lines patch to generator.sh! Lots of updates on all fronts. LOAD … Jul 18, 2016
mjr_tag_tokumxse_bugs.sh Some PSDMB testing updates Oct 29, 2015
mongo_js_run.sh Big end-spaces code cleanup May 16, 2018
mongo_kill_procs.sh Renamed mongo scripts from script_mongo -> mongo_script Nov 24, 2017
mongo_kill_procs_safe.sh Big end-spaces code cleanup May 16, 2018
mongo_regression.sh BLNS (blns2.txt) syntax fixes, more mongo script fixes, and removed l… Nov 29, 2017
mongo_regression_multi.sh Big end-spaces code cleanup May 16, 2018
mongo_single_test.sh
mongo_startup.sh
monitor.sh
mtr_binlog-format_issue.txt Adding mtr_binlog-format_issue.txt Dec 16, 2015
mtr_to_sql.sh mtr_to_sql.sh small improvement, main sql file update with JSON in ME… May 21, 2018
multi_tester.sh Big end-spaces code cleanup May 16, 2018
multirun_cli.sh
multirun_mysqld.sh Big end-spaces code cleanup May 16, 2018
myextra.sh Adding pquery-mass-reduce.sh, and other cleanups Jul 25, 2016
myrocks_differences.txt
mysql-dictionary.fuzz Merge fix Apr 9, 2018
parse_general_log.pl Various updates; build script minor patch, Fuzzer - many updates, han… Mar 22, 2018
percona_repo_install.sh lp:percona-qa migration to github:/Percona-QA/percona-qa Oct 1, 2015
performance-new.sh
performance-old.sh Big end-spaces code cleanup May 16, 2018
performance.sh Big end-spaces code cleanup May 16, 2018
pfs.sql Adding pfs.sql Jul 4, 2017
plugins_55.sql Bug update, plugin fixes, MYEXTRA fixes, RocksDB provisioning, pquery… May 12, 2017
plugins_56.sql
plugins_57.sql Added RocksDB plugin installation commands in plugins_57.sql Nov 3, 2017
plugins_80.sql
plugins_MS.sql Many multirun_mysqld.sh fixes and improvements for hang issue, rework… Jul 20, 2017
plugins_not_tested.sql Various updates, including plugin SQL and inc file sql Jan 22, 2016
plugins_pxc_57.sql
pmm-info.sh Update pmm-info.sh Aug 22, 2017
pmm_info.txt
postgres_test_to_sql.sh
pquery-allsubdir-clean-known.sh Minor updates Jan 1, 2018
pquery-auto-clean.sh Big end-spaces code cleanup May 16, 2018
pquery-bundles-doall.sh
pquery-cl.sh lp:percona-qa migration to github:/Percona-QA/percona-qa Oct 1, 2015
pquery-clean-known++.sh pquery-clean-known++.sh minor help text updates, expanded pquery-prep… May 19, 2018
pquery-clean-known.sh Bug updates, various small updates, pquery-shutdown-analysis.sh addition Apr 20, 2018
pquery-create-bundle.sh Big end-spaces code cleanup May 16, 2018
pquery-del-trial.sh Fixed PQA-229 : Bug fix Feb 28, 2018
pquery-eliminate-dups.sh Small patch to pquery-eliminate-dups.sh regex Oct 24, 2016
pquery-failing-sql.sh Fixing some bugs in pquery-prep-red.sh and pquery-failing-sql.sh Sep 30, 2016
pquery-go-expert.sh pquery-clean-known++.sh minor help text updates, expanded pquery-prep… May 19, 2018
pquery-goexp-patch.sh Bug updates + minor changes May 10, 2017
pquery-mass-goexp.sh Various fixes Aug 8, 2017
pquery-mass-reduce.sh Big end-spaces code cleanup May 16, 2018
pquery-multi-results.sh lp:percona-qa migration to github:/Percona-QA/percona-qa Oct 1, 2015
pquery-prep-red.sh pquery-clean-known++.sh minor help text updates, expanded pquery-prep… May 19, 2018
pquery-reach++.sh Rebuild new pquery binaries; PS, MS, PXC Feb 17, 2018
pquery-reach-status.sh lp:percona-qa migration to github:/Percona-QA/percona-qa Oct 1, 2015
pquery-reach.sh Big end-spaces code cleanup May 16, 2018
pquery-recovery.sh Small update Nov 27, 2015
pquery-red-mult-proces.sh Big end-spaces code cleanup May 16, 2018
pquery-results.sh pquery-clean-known++.sh minor help text updates, expanded pquery-prep… May 19, 2018
pquery-run-MS80-dbg.conf MS8.0 debug conf file upd Apr 20, 2018
pquery-run-MS80-gen.conf
pquery-run-MS80.conf Added pwgen random text to generator.sh (PQA-276), Improved generator… May 21, 2018
pquery-run-PS55.conf Changed all configs to use a larger max_allowed_packet to avoid loosi… Feb 2, 2018
pquery-run-PS56.conf Changed all configs to use a larger max_allowed_packet to avoid loosi… Feb 2, 2018
pquery-run-PS57.conf Prepare MYEXTRA in pquery-run-PS57.conf for upcoming run inc --encryp… May 24, 2018
pquery-run-PS80-gen.conf Changed all configs to use a larger max_allowed_packet to avoid loosi… Feb 2, 2018
pquery-run-PS80.conf Added vault server setup code in pquery-run.sh May 16, 2018
pquery-run-RocksDB-QC.conf.old
pquery-run-TokuDB-QC.conf Changed all configs to use a larger max_allowed_packet to avoid loosi… Feb 2, 2018
pquery-run-direct.sh Big end-spaces code cleanup May 16, 2018
pquery-run.conf Changed all configs to use a larger max_allowed_packet to avoid loosi… Feb 2, 2018
pquery-run.sh Big end-spaces code cleanup May 16, 2018
pquery-runs-info.sh Adding pquery-runs-info.sh, bug updates Jan 31, 2017
pquery-screen.sh Adding pquery-screen.sh. To make it even easier, use alias s="/home/<… Jul 25, 2016
pquery-shutdown-analysis.sh Bug updates, various small updates, pquery-shutdown-analysis.sh addition Apr 20, 2018
pquery-todays-runs.sh pquery-todays-runs.sh bug fix for single digit days, handy_gnu.txt up… May 1, 2018
prepared_statements.sql
process_signals.sh Big end-spaces code cleanup May 16, 2018
protractor-install.sh
proxysql-ps-config Bugfix issue200 (#214) Sep 27, 2017
proxysql-pxc-config Adding proxysql-pxc-config Oct 3, 2017
proxysql.cnf Adding PXC proxysql testing script Jun 11, 2016
ps-async-repl-test.sh Big end-spaces code cleanup May 16, 2018
ps-ssl-test.sh Big end-spaces code cleanup May 16, 2018
ps-upgrade-test.sh Big end-spaces code cleanup May 16, 2018
ps56to57.sh
qc-clean-known.sh
qc_filter.sh Added config files for QC testing and updated filters Oct 13, 2017
qpress.zip Adding qpress.zip to remove PXC QA script dependency Apr 26, 2016
querytimeout.sql Migrating reducer from lp:randgen/util/reducer to GitHub https://gith… Oct 5, 2015
randgen_to_sql.sh Updating randgen_to_sql.sh Nov 28, 2015
reducer-STABLE.sh Prepare MYEXTRA in pquery-run-PS57.conf for upcoming run inc --encryp… May 24, 2018
reducer.sh Prepare MYEXTRA in pquery-run-PS57.conf for upcoming run inc --encryp… May 24, 2018
reducer_status.sh Big end-spaces code cleanup May 16, 2018
reproducing_and_simplification.txt Minor update Apr 23, 2018
sequence_match.pl Added usage example, clarifications in description Jan 3, 2016
setup_devtoolset.sh lp:percona-qa migration to github:/Percona-QA/percona-qa Oct 1, 2015
setup_server.sh Added pwgen random text to generator.sh (PQA-276), Improved generator… May 21, 2018
simple.sql Update to simple.sql Dec 5, 2015
simple_3tables.sql Small patch Jun 1, 2016
startup.sh
sysbench.txt
sysbench_test_run.sh
taritgz.sh Adding taritxz.sh and renamed tarit.sh to taritgz.sh Sep 1, 2017
taritxz.sh New main input file (main-ms-ps-md.sql) with RocksDB added. Includes … Sep 6, 2017
test_mysqld_options.sh
text_string.sh Big end-spaces code cleanup May 16, 2018
tmpfs_clean.sh Big end-spaces code cleanup May 16, 2018
tokudb-migration.sh
valgrind-cleanup.sh lp:percona-qa migration to github:/Percona-QA/percona-qa Oct 1, 2015
valgrind_string.sh Upgrading pquery-prep-red.sh to include Valgrind handling Feb 8, 2016
vault_test_setup.sh Updated pxc-async-repl-test_v2.sh with keyring_vault plugin testcase.… May 15, 2018

README.md

Percona QA

Percona QA is a suite of scripts and utilities that assists in building, continuous integration, automated testing & bug reporting for Percona Server, Percona XtraDB Cluster, and Percona Server for MongoDB.

For a video introduction to some of the scripts, see: https://www.percona.com/blog/2015/03/17/free-mysql-qa-and-bash-linux-training-series/

Please Note: For the scripts to run successfully, it is required that sudo is enabled and working and should not request a password.

Files

analyze_crashes.sh

This script iterates through MySQL crash core files and runs analyze_crash.sh on them.

See Also: analyze_crash.sh (calls)

analyze_crash.sh

This script takes a MySQL crash core dump as an argument. It creates a an output file with a full backtrace of all threads associated with the core and the time it them backtrace was generated.

See Also: analyze_crashes.sh (called from)

analyze_subdir_cores.sh

This script will iterate through all core files starting with the current working directory and creates report containing full backtrace of all threads for each in the file gdb__STD/_FULL.txt

ansible_info.txt

Ansible installation/setup information.

build_mysql.sh

Download and build mysql from bzr url.

Example: ./build_mysql.sh lp:mysql-server/5.6

Note: only current cmake builds will work, various compile options can be set by editing the script.

build_percona.sh

Download and build percona server from bzr url. Note: script is outdated and it is preferred to use get_percona.sh (see description)

build_xtrabackup.sh

This script will download and build xtrabackup from a bzr url

Example: ./build_xtrabackup.sh lp:percona-xtrabackup/2.2

cleanup_ALARMs.sh

Deletes ALARM status RQG trials for which there are no errors of any importance in the server log It does so by checking for which trials ALARM.sh does not return any important failures (Whether this is the case or not is determined by the $FINDS and $IGNOR variables in rqg_results.sh)

See Also: rqg_failure_counts.sh, rqg_results.sh

cleanup_failures.sh

For use with lp:randgen combinations.pl results

Use with caution. Removes all established known issues for a given combinations.pl run based on a search string No valid parameters were passed. Need a status (1) and a search string to cleanup on (2). Retry. Example use: $cleanup_failures.sh SERVER_CRASHED 'srv_log_block_size' Note; if you want to delete all items for a given status, use 'a' (or shortly: a) as the search string Note; this script relies on the STATUS ./{status passed as first option} scripts to be present Note; this script relies on the delete_single_trial.sh script to be present in the same directory as this script

See Also: delete_single_trial.sh (calls)

codership6-binary.sh

Build full and package Percona-XtraDB-Cluster-codership.tar.gz binary including the galera engine. Version 5.6

codership-binary.sh

Build full and package Percona-XtraDB-Cluster-codership.tar.gz binary including the galera engine. Version 5.5

COPYING

License (GPL 2)

core_retrieve.sh

For a given trial, this script quickly produces a tarball containing: the core file generated by that trial, the mysqld used by that trial, and the ldd dependency files needed by that This can be used to quickly get a tarball which is ready to be added to a bug report for analysis by developers.

Takes the RQG trial number as a parameter.

See Also: crash_bug_files.sh (called from), ldd_files.sh (calls)

crash_bug_files.sh

This script quickly gathers all files required for logging a crash bug report.

Takes the RQG trial number as a parameter.

See Also: startup.sh (calls), analyze_crash.sh (calls), core_retrieve.sh (calls)

delete_single_trial.sh

For use with lp:randgen combinations.pl results

This script deletes a given trial (from a combinations.pl run) completely. Execute from the combinations.pl workdir"

Example: to delete trial 1000, execute as:

./delete_single_trial.sh 1000"

See Also: cleanup_ALARMs.sh (called from), cleanup_failures.sh (called from), rqg_results.sh (called from)

doall.sh

This script executes startup.sh in manual RQG mode (without extracting mysql build and randgen), then runs the resulting cmdtrace script and finally prepare_reducer.sh. It expects one parameter: the trial number to analyze

See Also: startup.sh (calls), prepare_reducer.sh (calls)

docker/

Previously in directory ./docker, Percona QA PXC Docker (multi-node Docker configurations PXC testing) has been moved to https://github.com/percona/pxc-docker

docker_info.txt

Docker installation/setup information. Includes information on day-to-day tasks, helpful resources etc.

download_launchpad_single_file.sh

This bash script will download a single file from a launchpad project. See the usage in the script for more information. There is a section at the bottom that can be embedded in another script or Jenkins job if it is known that the target machine has 'wget' installed.

download_rpmdeb.sh

This script will download all of the rpm/deb packages from the given web page link. It is designed to easily download Jenkin's package builds for testing. (Requires lynx and wget to be installed)

Example:

download_rpmdeb.sh http://jenkins.percona.com/view/Percona/job/pxc56/999/label_exp=rhel6

ext/twitter/ip_validator.sh

This script will load and test the MySQL stored function check_ip() into a mysql database. The command line for running the mysql client is defined in the environment variable CLI at the top of the script.

check_ip( char(255) ) is an IP address validator.

The function returns:

OK (IPV4)       - Good IPV4 address
OK (IPV6)       - Good IPV6 address
>!FAIL!(x)<     - Fail where 'x' is a-e designating the type of failure
                      (see function for more info)
NOT_AN_IP       - Input does not resemble an IPV4 or IPV6 address.

The stored function uses the underlying IS_IPV4(), INET_ATON(), INET_NTOA(), INET6_ATON() and INET6_NTOA() functions in order to validate the given ip address.

extract_query.gdb

This is a gdb script which is called from prepare_reducer.sh and helps extract queries that were running from a mysqld core dump.

See Also: prepare_reducer.sh (called from)

get_percona.sh

This script downloads recent binaries from the Jenkins CI server (optimized, with debug symbols and valgrind) and extracts them onto the local system for testing. This avoids the time required for local builds and issues with toolchain variations. Examine the script to determine or change which OS/target binaries are being downloaded (i.e. centos6-64).

handy_gnu.txt

Various shell and command line tips and tricks.

hung_mysqld.gdb

This small gdb command script allows you to analyze the state of a currently running but hung process. It will dump all thread backtrace call stacks for the given process id.

Example:

gdb mysqld {pid} < hung_mysqld.gdb

keep_single_trial.sh

This script keeps a given RQG trial (from a combinations.pl run) completely (i.e. all files included) in the KEEP directory within a given combinations.pl workdir. Execute this script directly from within the combinations.pl workdir. Example: to keep trial 1000, execute as:

./keep_single_trial.sh 1000

ldd_files.sh

This script quickly gathers all shared library dependencies for mysqld and xtrabackup in the current working directory the script is run from. The shared libraries are copied into a lib64 subdirectory of the current working directory.

See Also: core_retrieve.sh (called from)

lp-bug-add-file.py

This script will add a attached file to an existing launchpad bug report.

This script needs three parameters; the Launchpad bug number, the file to upload and the file's description.

Usage: ./lp-bug-logger.py -b <bugno> -f <file> -d '<description>'

This script is usually not executed directly, but is instead used by lp-bug-logger.sh However, if you use it directly, a 'None' output means there were no errors/that the upload was successful.

You will need to install python-launchpadlib for the proper operation of this script.

Ubuntu:

$sudo apt-get install python-launchpadlib

Others:

$sudo pip install launchpadlib

Some important information on interaction with Launchpad via the Python Launchpad API used by this script: The first time you run this script, you will see something like this (after quite some time):

The authorization page:

(https://launchpad.net/+authorize-token?oauth_token=xxxxxxxxxxxxxx&allow_permission=DESKTOP_INTEGRATION)

should be opening in your browser. Use your browser to authorize this
program to access LP on your behalf Waiting to hear from Launchpad about
your decision...

When you see this (and assuming you're working in a text-only ssh connection; otherwise a browser may have already automatically opened for you), copy and paste the URL shown into any browser and authorize the app (for example, until revoked) after logging into LP. This only has to be done once (if you chose an indefinite until revoked authorization), and it can be done from any machine (provided you login to LP). If you run into any issues, also review Unrecoverable error when authorization fails if applicable. And, authorized applications can be viewed (and revoked) at: https://launchpad.net/~<your_lp_user_id>/+oauth-tokens

See Also: lp-bug-logger.sh (called from)

lp-bug-logger.sh

This script uploads, for a given trial, all files in the directory ./BUNDLE_/* to a given Launchpad bug report. It expects two parameters; the trial number & the bug number. For Example, to action trial 1000, and upload to bug report 1259034 use:

$./lp-bug-logger.sh 1000 1259034

Note: to generate a BUNDLE_ directory, use crash_bug_files.sh

Note: This script calls lp-bug-add-file.py, please review the description of that script for other important information.

See Also: lp-bug-add-file.py (calls)

mtr_to_sql.sh

Scans all MTR testcase commands & generates bughunt RQG grammar/SQL

multirun_cli.sh

Run multiple mysql clients executing the given input SQL multiple times each.

This script expects exactly 5 options. Execute as follows:

$ multirun_cli.sh threads repetitions input.sql cli_binary socket
Where Description
threads is the number of simultaneously started cli threads
repetitions the number of repetitions per individual thread
input.sql is the input SQL file executed by the clients
cli_binary is the location of the mysql binary
socket is the location of the socket file for connection to mysqld

Example:

$ multirun_cli.sh 10 5 bug.sql /ssd/pxc-5.5/bin/mysql /ssd/test/mysql.sock

Cautionary Notes:

  • Script does not check yet if options passed are all valid/present, make sure you get it right
  • If root user uses a password, a script hack is suggested ftm
  • This script may cause very significant server load if used with many threads
  • This script expects write permissions in the current directory (ex. /home/{user}/percona-qa)
  • Output files for each thread are written as: multi.. (e.g. multi.1.1 etc.)

multirun_mysqld.sh

This script will execute a given saved RQG trial against multiple instances of a given mysql installation.

This script expects 3 parameters to test server crash with multiple mysqld processes.

Parameters:

  1. mysql base directory
  2. RQG trial number
  3. crashed SQL file name.

Example:

$ multirun_mysqld.sh /ssd/ramesh/pxc-5.6.20-x64 36 in.sql

*See Also:$ myextra.sh (calls)

myextra.sh

This script outputs the extra mysqld options used in a given RQG trial. It expects one parameter: the trial number to analyze. Ensure that startup.sh has already been executed for this trial.

See Also: multirun_mysqld.sh (called from), prepare_reducer.sh (called from)

packaging_testing/

The scripts in this directory will test packaging across supported OS distributions.

parse_general_log.pl

This script can be used to extract SQL from a MySQL general-log.

Usage:

[perl] ./parse_general_log.pl -i infile -o outfile

Where:

  • infile is a standard mysqld general query log
  • outfile is the SQL output extracted from the log.

General mysqld logs can be generated with these options to MTR (or RQG):

--mysqld=--log-output=FILE --mysqld=--general_log --mysqld=--general_log_file=out.sql

WARNING: by default this script eliminates a number of statements which may cause replay issues (KILL, RELEASE) This may lead to non-reproducibility for certain bugs. Check the script's source for specifics

percona_repo_install.sh

This script will enable the Percona apt/yum repository on a RHEL,Centos, Debian or Ubuntu server. The script must be run with root permissions.

If the script is hosted at a public URL then it can install the Percona apt/yum repo with a single command:

# curl -s {url}/percona_repo_install.sh | bash /dev/stdin

performance.sh

Note: Jenkins CI script

This is a performance testing script that is designed to be run from the Jenkins Continuous Integration system. It will run a series of tests with the MySQL Test Suite and Sysbench both with default and tuned settings.

It requires two parameters.

  1. relative workdir
  2. relative basedir

Usage example:

$./performance.sh 100 Percona-Server-5.5.28-rel29.3-435.Linux.x86_64

This would lead to /data/bench/qa/100 being created, in which testing takes /place and data/bench/qa/Percona-Server-5.5.28-rel29.3-435.Linux.x86_64 would /be used to test. The fixed root workdir to which all options are relative is /set to /data/bench/qa in the script.

performance-old.sh

Note: Jenkins CI script

This is an older version of the performance.sh script. It takes the same parameters.

See: performance.pl

pquery/

A multi-threaded stress test for mysqld. This utility will read SQL queries from a file (one per line) and spawn a given number of threads that will execute the queries from the list in random order. The number of queries each thread will execute is equal to the SQL input line count but it is not guaranteed that all queries will run as they are selected at random, some queries may be run multiple times and others not at all.

Also included is a generator script which maybe used to generate queries for pquery. Other tools such as randgen can also be used to generate random query data for pquery input.

See Also: pquery-sb/

pquery-sb/

pquery-sb is a lua script to be used with the sysbench application. It performs the same function as the C++ based pquery utility.

See Also: pquery/

prepare_reducer.sh

A wrapper for /util/reducer/reducer.sh in the lp:randgen source tree.

This script creates a local run script for reducer. It expects one parameter: the trial number to analyze.

To aid with correct bug to testcase generation, this script creates a local run script for reducer and sets #VARMOD#. This handles crashes/asserts for the moment only. Could be expanded later for other cases, and to handle more unforeseen situations.

process_signals.sh

script which displays process info for pid along with information on which signals are pending, blocked, ignored and caught by the process.

ps-async-repl-test.sh

Note: Jenkins CI script

This script will help us to test different asynchronous replication methods like master slave, master multi slave, master master, multi source replication, multi thread replication etc

pxc56-mtr.sh

This script is designed to run from the Percona Jenkins job named 'pxc56-mtr'. It runs selected MTR tests on a recent PXC 5.6 build.

pxc55to56.sh

Note: Jenkins CI script

2 node cluster testing script, also tests upgrade from 5.5 to 5.6

This script tests a two node PXC 5.5 cluster, runs the mysql test suite and sysbench against it, then upgrades the cluster to 5.6 and re-runs the MySQL test suite with and without compatibility options, runs sysbench under 5.6 and then outputs the versions and row count of the test table on both nodes.

pxc56to56.sh

Note: Jenkins CI script

Tests cluster combining 5.6 release with 5.6 latest.

Tests cluster SST and IST using Mysql test suite and multi-table sysbench from both nodes, performs an mysql_upgrade retests. Reports versions and row counts at the end.

pxc56to56-t2.sh (take 2?)

Alternative version of pxc56to56.sh testing from one release version to another automatically downloads and builds sysbench if not found, wsrep debugging disabled, common parameter ordering changed.

pxc6-bench.sh

Note: Jenkins CI script

This is a benchmark script for Percona XtraDB Cluster 5.6. It benchmarks using MySQL Test Suite, sysbench and has support for dual node cluster testing.

pxc6-rqg.sh

Note: Jenkins CI script

This is an automated randgen testing script for PXC 5.6. Resulting randgen trials are stored for later analysis.

pxc6-sst-test.sh

Note: Jenkins CI script

This script tests Galera snapshot transfer between nodes in a cluster configuration. For PXC 5.6.

pxc-bench.sh

Note: Jenkins CI script

Earlier version of the PXC benchmarking script.

See: pxc6-bench.sh

pxc-failure-test.sh

This script is for PXC Testing ChaosMonkey Style Please go through the tutorial to install PXC on your machine and execute this script from node1 Analyze script_out.log file from workdir to get the PXC testcase output

pxc-replication-check.pl

This script is designed to monitor IST replication state between PXC wsrep nodes for various SQL instructions. An example of a bug this will test is for is lp1421360. For a reliable test please make sure there is no other traffic on the test cluster.

pxc-prepared-stmnt-test.sh.sh

This script is made for PXC Prepared SQL Statement test

pxc-rqg.sh

Note: Jenkins CI script

Earlier version of the pxc6-rqg.sh randgen script.

See: pxc6-rqg.sh

pxc-sst-test.sh

Note: Jenkins CI script

Earlier version of the pxc6-sst=test.sh

See: pxc6-sst-test.sh

reducer.sh

reducer.sh - the best mysql testcase reduction program

For more info, search Google for: reducer.sh

rqg_failure_counts.sh

Note: Jenkins CI script

Jenkins CI script to check randgen failure counts.

rqg_results.sh

This script handles various trial outcomes for a given RQG run (run from the RQG combinations.pl workdir containing all trialx.log files)

Note: this script relies on the delete_single_trial.sh script to be present in the same directory as this script

If you start rqg_results.sh with WIPE as the first option ($./rqg_results.sh WIPE) it will wipe all STATUS_ENVIRONMENT_FAILURE, all STATUS_INTERNAL_ERROR, and all STATUS_PERL_FAILURE failed trials by default

run_times_parse.sh

parse_times.sh allows one to check the start and end times for all trials within a RQG combinations.pl run direct This allows for quick analysis to see if any of the trials stalled/hanged/locked up by reviewing the durations

setup_devtoolset.sh

Deprecated

This script does not work, leaving here for future work or future deletion

setup_server.sh

This script makes major changes to any machine it is executed on (installs packages, enables core files, changes significant security settings etc.). Please review the planned changes by reviewing the script contents. All of the changes in the script prepare this machine to be a proper QA server. This script is meant for use on Centos (6.x mainly). Make sure that you want to continue.

Note: this script removes pulseaudio drivers. If you are using a desktop/would like to keep pulseaudio, please remark the line in the script first. Finally, this script can be executed multiple times without doubling up configurations/without messing up anything. It was specifically coded for this. This script requires sudo and su commands to be available already. Use visudo as described above (in 'Sudo:') to add yourself to sudo list (faster run). This script is provided AS-IS with no warranty of any kind. Do NOT run on production machines. This script lowers the servers security. Use at own risk.

sequence_match.pl

This script will search through the standard input for a sequence of lines that match a sequence of regular expressions and report when a match is found.

This can be used to find blocks of matching code within a project.

startup.sh

Generate cmd startup scripts used in an RQG trial.

This script expects the trial number to be passed - e.g. 'startup 10' for actioning trial 10 (trial10.log) Other uses: 'startup 10 man': actions trial 10 as found in the RQG run without attempting to extract any tars Other uses: 'startup 0': local build mode (create scripts for a standard server setup without reference to RQG)

In other words, use:

$ startup.sh <trialno>         When analyzing automated Percona Jenkins RQG runs
$ startup.sh <trialno> man     When analyzing manually executed RQG runs
$ startup.sh <trialno> man2    Like man option above, but do not attempt to untar tarball again
$ startup.sh 0                 When having extracted a binary tar build with ./build/build-binary.sh (no RQG)

test_mysqld_options.sh

This script quickly tests all mysqld options. Note it expects cores to be written to /cores/core.pid. Location can be changed in-script, but not filename To set your server up in this way (in terms of corefile generation), see core file setting part of setup_server.sh, available at lp:percona-qa