Skip to content

Commit

Permalink
Added download and extract of world database
Browse files Browse the repository at this point in the history
Fixed apt/yum throttling
  • Loading branch information
tplavcic committed Jul 1, 2016
1 parent ed2ef19 commit 9fb1ab9
Show file tree
Hide file tree
Showing 6 changed files with 19 additions and 11 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
.vagrant
world_innodb.sql
world.sql
2 changes: 1 addition & 1 deletion templates/apt.throttling → apt-throttling
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,6 @@ Acquire
Queue-mode "access";
http
{
Dl-Limit "1000";
Dl-Limit "200";
};
};
2 changes: 1 addition & 1 deletion plugins_test_55.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,4 @@ mysql -e "INSTALL PLUGIN audit_log SONAME 'audit_log.so';"
mysql -e "INSTALL PLUGIN handlersocket SONAME 'handlersocket.so';"
mysql -e "SHOW PLUGINS;"
mysql -e "CREATE DATABASE world;"
pv /vagrant/world_innodb.sql | mysql -D world
pv /package-testing/world.sql | mysql -D world
4 changes: 2 additions & 2 deletions plugins_test_56.sh
Original file line number Diff line number Diff line change
Expand Up @@ -13,5 +13,5 @@ mysql -e "INSTALL PLUGIN QUERY_RESPONSE_TIME_WRITE SONAME 'query_response_time.s
mysql -e "SHOW PLUGINS;"
mysql -e "CREATE DATABASE world;"
mysql -e "CREATE DATABASE world2;"
pv /vagrant/world_innodb.sql | mysql -D world
pv /vagrant/world_innodb.sql | mysql -D world2
pv /package-testing/world.sql | mysql -D world
pv /package-testing/world.sql | mysql -D world2
6 changes: 3 additions & 3 deletions plugins_test_57.sh
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,6 @@ mysql -e "INSTALL PLUGIN mysqlx SONAME 'mysqlx.so';"
mysql -e "SHOW PLUGINS;"
mysql -e "CREATE DATABASE world;"
mysql -e "CREATE DATABASE world2;"
pv /vagrant/world_innodb.sql | mysql -D world
pv /vagrant/world_innodb.sql | mysql -D world2
mysql < /vagrant/tokudb_compression.sql
pv /package-testing/world.sql | mysql -D world
pv /package-testing/world.sql | mysql -D world2
mysql < /package-testing/tokudb_compression.sql
15 changes: 11 additions & 4 deletions tasks/test_prep.yml
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@

- name: setup throttling for yum
command: echo "throttle=1M" >> /etc/yum.conf
command: echo "throttle=200k" >> /etc/yum.conf
when: ansible_os_family == "RedHat"

- name: setup throttling for apt
template: src=../templates/apt.throttling
dest=/etc/apt/apt.conf.d/lowerspeed
mode=0640 owner=root group=root
copy: src=../apt-throttling
dest=/etc/apt/apt.conf.d/
mode=0640 owner=root group=root
when: ansible_os_family == "Debian"

- name: install git with apt
Expand All @@ -24,3 +24,10 @@
- git: repo=https://github.com/Percona-QA/package-testing
dest=/package-testing
depth=1

- name: download and extract world database
command: "{{ item }} chdir=/package-testing/"
with_items:
- wget --limit-rate=200k --directory-prefix=/package-testing http://downloads.mysql.com/docs/world.sql.gz
- gunzip world.sql.gz

0 comments on commit 9fb1ab9

Please sign in to comment.