SlideShare a Scribd company logo
11th
Central and Eastern European Software
Engineering Conference in Russia - CEE-SECR
2015
October 22 - 24, Moscow
Timofey Turenko
Automatic tool for multi-configuration
environment creation for database server
and database proxy application testing
MariaDB Corporation AB
Kirill Krinkin
St-Petersburg Electrotechnical University
MariaDB & Maxscale
Test environment problem
 Server and proxy application testing:
– backend is needed
– lots of combination of machine configurations and
version of backend servers
 Maxscale example:
– 12 major linux distributions
– MariaDB 5.5, 10.0, 10.1, 10.2
– MySQL 5.1, 5.5, 5.6, 5.7
– different topologies
– Maxscale itself from CI
Requirements
 arbitrary number of backend servers;
 any version of server software can be installed on every
backend server;
 different virtual machine providers have to be supported
(Virtual Box, Qemu, different cloud providers);
 deployment of test environment have to be automated;
 several test round can be executed in parallel;
 test environment description have to be clear and human
readable.
Configuration example
VM managers, SW manager
 Vagrant, Terraform, Ansible
 Chef, Puppet
works? try to
write/read it:
### Import AWS Provider access config ###
require 'yaml'
aws_config = YAML.load_file("../aws-config.yml")['aws']
## of import AWS Provider access config
### Vagrant configuration block ###
####################################
Vagrant.configure(2) do |config|
### AWS Provider config block ###
#############################################
config.vm.box = "dummy"
config.vm.provider :aws do |aws, override|
aws.access_key_id = aws_config["access_key_id"]
aws.secret_access_key = aws_config["secret_access_key"]
aws.keypair_name = aws_config["keypair_name"]
aws.region = aws_config["region"]
aws.security_groups = aws_config["security_groups"]
aws.user_data = aws_config["user_data"]
override.ssh.private_key_path = aws_config["pemfile"]
override.nfs.functional = false
end ## of AWS Provider config block
config.vm.synced_folder "/home/vagrant/build-scripts/test-setup-...
config.vm.define :node0 do |node0|
node0.vm.provider :aws do |aws,override|
aws.ami = "ami-1c2e8b6b"
aws.instance_type = "t1.micro"
override.ssh.username = "ec2-user"
end
##--- Chef binding ---
node0.vm.provision "chef_solo" do |chef|
chef.cookbooks_path = "../recipes/cookbooks/"
chef.roles_path = "."
chef.add_role "node0"
chef.synced_folder_type = "rsync"
end #<-- end of chef binding
end # -> End definition for machine: node0
config.vm.synced_folder "/home/vagrant/build-scripts/test-setup-...
# -> Begin definition for machine: node1
config.vm.define :node1 do |node1|
node1.vm.provider :aws do |aws,override|
aws.ami = "ami-1c2e8b6b"
aws.instance_type = "t1.micro"
override.ssh.username = "ec2-user"
end
##--- Chef binding ---
Make it readable
"node0" :
{
"hostname" : "node0",
"box" : "centos7",
"product" : {
"name": "mariadb",
"version": "10.0",
"cnf_template" : "server1.cnf",
"cnf_template_path": "/home/vagrant/cnf"
}
},
"node1" :
{
"hostname" : "node1",
"box" : "rhel7",
"product" : {
"name": "mysql",
"version": "5.6",
"cnf_template" : "server2.cnf",
"cnf_template_path": "/home/vagrant//cnf"
}
}
"node2" :
{
"hostname" : "node2",
"box" : "centos7",
"product" : {
"name": "galera",
"version": "5.5",
"cnf_template" : "server-galera3.cnf",
"cnf_template_path": "/home/vagrant//cnf"
}
}
boxes.json
{
"ubuntu_precise": {
"provider": "virtualbox",
"box": "chef/ubuntu-12.04",
"platform": "ubuntu",
"platform_version": "precise"
},
"centos7" : {
"provider": "aws",
"ami": "ami-1c2e8b6b",
"user": "ec2-user",
"default_instance_type": "t1.micro",
"platform": "centos",
"platform_version": "7"
}
}
Repository description
{ "product": "mariadb",
"version": "10.0.17",
"repo": "http://yum.mariadb.org/10.0.17/centos5-amd64",
"repo_key": "https://yum.mariadb.org/RPM-GPG-KEY-MariaDB",
"platform": "centos",
"platform_version": 5}
{ "product": "mysql",
"version": "5.6",
"repo": "http://repo.mysql.com/yum/mysql-5.6-community/sles/12/x86_64",
"repo_key": "http://repo.mysql.com/RPM-GPG-KEY-mysql",
"platform": "sles",
"platform_version": 12}
We have a generator for
MariaDB, MariaDB enterprise, MariaDB Galera, Maxscale, MySQL
{ "product": "mariadb",
"version": "10.0",
"repo": "http://yum.mariadb.org/10.0/centos5-amd64",
"repo_key": "https://yum.mariadb.org/RPM-GPG-KEY-MariaDB",
"platform": "centos",
"platform_version": 5}
Workflow
 write template
 './mdbci generate <name>'
 './mdbci up <name>'
 Get all needed info: './mdbci show …'
 Access machines: './mdbci ssh' or directly via 'ssh'
 './mdbci destory <name>'
Does it work?
 9 and 25 machines configurations
 40 test runs every day
 MariaDB, Maxscale, MariaDB enterprise, MariaDB-Galera
 VirtualBox, Amazon EC2, QEMU (plans: Docker, DigitalOcean)
 Developers like it: “use ./mdbci ssh and see all log, states,
core dumps, use my env for debugging”
Source
 https://github.com/OSLL/mdbci
 https://github.com:mariadb-corporation/mdbci-repository-
config
https://github.com/mariadb-corporation/MaxScale
https://mariadb.com/products/mariadb-maxscale
Maxscale

More Related Content

PDF
Introduction to chef framework
PDF
Infrastructure = Code
PDF
Chef or how to make computers do the work for us
ODP
Chef training - Day2
PDF
Local development environment evolution
PDF
docker build with Ansible
PDF
Getting Started with Ansible
PDF
Chef Provisioning a Chef Server Cluster - ChefConf 2015
Introduction to chef framework
Infrastructure = Code
Chef or how to make computers do the work for us
Chef training - Day2
Local development environment evolution
docker build with Ansible
Getting Started with Ansible
Chef Provisioning a Chef Server Cluster - ChefConf 2015

What's hot (20)

PDF
Chef solo the beginning
PDF
DevOpsDaysCPT Ansible Infrastrucutre as Code 2017
PPTX
Orchestration? You Don't Need Orchestration. What You Want is Choreography.
ODP
Chef training - Day3
PPTX
What Makes a Good Chef Cookbook? (May 2014 Edition)
PDF
Introduction to Ansible
ODP
Chef training Day5
PDF
Selenium grid workshop london 2016
PDF
Jenkins and ansible reference
PDF
IT Automation with Ansible
ODP
Chef training Day4
PPTX
Ansible intro
PDF
Test driven infrastructure
PDF
Configuration management and orchestration with Salt
PDF
OpenNebula and SaltStack - OpenNebulaConf 2013
PDF
Introduction to selenium_grid_workshop
PPTX
Free enterpriseloadbalancer
PPTX
Cook Infrastructure with chef -- Justeat.IN
PPT
Learn basic ansible using docker
PDF
#OktoCampus - Workshop : An introduction to Ansible
Chef solo the beginning
DevOpsDaysCPT Ansible Infrastrucutre as Code 2017
Orchestration? You Don't Need Orchestration. What You Want is Choreography.
Chef training - Day3
What Makes a Good Chef Cookbook? (May 2014 Edition)
Introduction to Ansible
Chef training Day5
Selenium grid workshop london 2016
Jenkins and ansible reference
IT Automation with Ansible
Chef training Day4
Ansible intro
Test driven infrastructure
Configuration management and orchestration with Salt
OpenNebula and SaltStack - OpenNebulaConf 2013
Introduction to selenium_grid_workshop
Free enterpriseloadbalancer
Cook Infrastructure with chef -- Justeat.IN
Learn basic ansible using docker
#OktoCampus - Workshop : An introduction to Ansible
Ad

Viewers also liked (20)

PDF
Implementation of the new REST API for Open Source LBS-platform Geo2Tag
PDF
Testing with Selenium
PDF
Обзор Btrfs
ODP
OLPC Mesh networking improvements
PDF
N8xx olpc connectivity
PDF
MOOCs Virtual Lab in Modern Education
PDF
Обзор файловой системы GlusterFS
ODP
SVG-player plugin for ns2 simulations
PDF
E.Kalishenko, K.Krinkin, S.P.Shiva Prakash. Process Mining Approach for Traff...
PPT
Fruct4 n8xx olpc-connectivity
PDF
Full Automated Continuous Integration and Testing Infrastructure for Maxscale...
PDF
Обзор архитектуры [файловой] системы Ceph
PDF
Работа с геоданными в MongoDb
PDF
Обзор Linux Control Groups
PPT
Open Source implementation of ZigBee
PDF
Пространства имен Linux (linux namespaces)
PDF
Virtual-HSM: Virtualization of Hardware Security Modules in Linux Containers
PDF
Кратчайшее введение в docker по-русски
PDF
Block-level compression in Linux. Pro et contra
PDF
Студентам и не только. Как выступить с докладом по своей научной работе
Implementation of the new REST API for Open Source LBS-platform Geo2Tag
Testing with Selenium
Обзор Btrfs
OLPC Mesh networking improvements
N8xx olpc connectivity
MOOCs Virtual Lab in Modern Education
Обзор файловой системы GlusterFS
SVG-player plugin for ns2 simulations
E.Kalishenko, K.Krinkin, S.P.Shiva Prakash. Process Mining Approach for Traff...
Fruct4 n8xx olpc-connectivity
Full Automated Continuous Integration and Testing Infrastructure for Maxscale...
Обзор архитектуры [файловой] системы Ceph
Работа с геоданными в MongoDb
Обзор Linux Control Groups
Open Source implementation of ZigBee
Пространства имен Linux (linux namespaces)
Virtual-HSM: Virtualization of Hardware Security Modules in Linux Containers
Кратчайшее введение в docker по-русски
Block-level compression in Linux. Pro et contra
Студентам и не только. Как выступить с докладом по своей научной работе
Ad

Similar to [MDBCI] Mariadb continuous integration tool (20)

PDF
Introduction to Chef
PDF
SCALE 2011 Deploying OpenStack with Chef
KEY
Chef meetup presentation
PDF
Chef: Smart infrastructure automation
KEY
Automate or Die
PDF
EC2 AMI Factory with Chef, Berkshelf, and Packer
ODP
DB proxy server test: run tests on tens of virtual machines with Jenkins, Vag...
PDF
PDF
PDF
Automating your infrastructure with Chef
PPTX
A Groovy Kind of Java (San Francisco Java User Group)
PDF
Build your own clouds with Chef and MCollective
PDF
Achieving Infrastructure Portability with Chef
PDF
under the covers -- chef in 20 minutes or less
PDF
Chef Fundamentals Training Series Module 3: Setting up Nodes and Cookbook Aut...
PDF
GeekAustin DevOps
PDF
Automated infrastructure is on the menu
PDF
Chef for OpenStack - OpenStack Fall 2012 Summit
PDF
Chef for OpenStack- Fall 2012.pdf
PPT
vBACD - Introduction to Opscode Chef - 2/29
Introduction to Chef
SCALE 2011 Deploying OpenStack with Chef
Chef meetup presentation
Chef: Smart infrastructure automation
Automate or Die
EC2 AMI Factory with Chef, Berkshelf, and Packer
DB proxy server test: run tests on tens of virtual machines with Jenkins, Vag...
Automating your infrastructure with Chef
A Groovy Kind of Java (San Francisco Java User Group)
Build your own clouds with Chef and MCollective
Achieving Infrastructure Portability with Chef
under the covers -- chef in 20 minutes or less
Chef Fundamentals Training Series Module 3: Setting up Nodes and Cookbook Aut...
GeekAustin DevOps
Automated infrastructure is on the menu
Chef for OpenStack - OpenStack Fall 2012 Summit
Chef for OpenStack- Fall 2012.pdf
vBACD - Introduction to Opscode Chef - 2/29

More from OSLL (16)

PDF
SLAM Constructor Framework for ROS
PDF
Microservice architecture for Geo2Tag
PDF
Fast Artificial Landmark Detection for indoor mobile robots AIMAVIG'2015
PDF
Linuxvirt seminar-csc-2015
PDF
Raspberry Pi robot with ROS
PDF
Source code analyzer
PPTX
Fruct14 sholokhova
PPTX
SECR'13 Lightweight linux shared libraries profiling
PDF
Smart-M3 and Geo2Tag integration
ODP
HTML5 Intro and Tizen Web API
ODP
Fruct13 geo2tag-training
PDF
Json protocol, Geo2tag REST API fundamentals
PDF
Introduction to geo-tagging and geo2tag platform
PPTX
Detection pulse by video
PPT
Using Intel NAS-PT for testing NAS disks
ODP
Geo2Tag LBS Platform Architecture Overview
SLAM Constructor Framework for ROS
Microservice architecture for Geo2Tag
Fast Artificial Landmark Detection for indoor mobile robots AIMAVIG'2015
Linuxvirt seminar-csc-2015
Raspberry Pi robot with ROS
Source code analyzer
Fruct14 sholokhova
SECR'13 Lightweight linux shared libraries profiling
Smart-M3 and Geo2Tag integration
HTML5 Intro and Tizen Web API
Fruct13 geo2tag-training
Json protocol, Geo2tag REST API fundamentals
Introduction to geo-tagging and geo2tag platform
Detection pulse by video
Using Intel NAS-PT for testing NAS disks
Geo2Tag LBS Platform Architecture Overview

Recently uploaded (20)

PPTX
Cloud computing and distributed systems.
PPTX
ACSFv1EN-58255 AWS Academy Cloud Security Foundations.pptx
PDF
Profit Center Accounting in SAP S/4HANA, S4F28 Col11
PDF
Network Security Unit 5.pdf for BCA BBA.
PDF
Electronic commerce courselecture one. Pdf
PDF
Agricultural_Statistics_at_a_Glance_2022_0.pdf
PDF
Approach and Philosophy of On baking technology
PPTX
sap open course for s4hana steps from ECC to s4
PDF
The Rise and Fall of 3GPP – Time for a Sabbatical?
PDF
Machine learning based COVID-19 study performance prediction
PPTX
KOM of Painting work and Equipment Insulation REV00 update 25-dec.pptx
PDF
Unlocking AI with Model Context Protocol (MCP)
PPTX
Digital-Transformation-Roadmap-for-Companies.pptx
PPTX
Spectroscopy.pptx food analysis technology
PPTX
Programs and apps: productivity, graphics, security and other tools
PDF
Chapter 3 Spatial Domain Image Processing.pdf
PDF
Per capita expenditure prediction using model stacking based on satellite ima...
PDF
Encapsulation_ Review paper, used for researhc scholars
PDF
Architecting across the Boundaries of two Complex Domains - Healthcare & Tech...
PDF
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...
Cloud computing and distributed systems.
ACSFv1EN-58255 AWS Academy Cloud Security Foundations.pptx
Profit Center Accounting in SAP S/4HANA, S4F28 Col11
Network Security Unit 5.pdf for BCA BBA.
Electronic commerce courselecture one. Pdf
Agricultural_Statistics_at_a_Glance_2022_0.pdf
Approach and Philosophy of On baking technology
sap open course for s4hana steps from ECC to s4
The Rise and Fall of 3GPP – Time for a Sabbatical?
Machine learning based COVID-19 study performance prediction
KOM of Painting work and Equipment Insulation REV00 update 25-dec.pptx
Unlocking AI with Model Context Protocol (MCP)
Digital-Transformation-Roadmap-for-Companies.pptx
Spectroscopy.pptx food analysis technology
Programs and apps: productivity, graphics, security and other tools
Chapter 3 Spatial Domain Image Processing.pdf
Per capita expenditure prediction using model stacking based on satellite ima...
Encapsulation_ Review paper, used for researhc scholars
Architecting across the Boundaries of two Complex Domains - Healthcare & Tech...
TokAI - TikTok AI Agent : The First AI Application That Analyzes 10,000+ Vira...

[MDBCI] Mariadb continuous integration tool

  • 1. 11th Central and Eastern European Software Engineering Conference in Russia - CEE-SECR 2015 October 22 - 24, Moscow Timofey Turenko Automatic tool for multi-configuration environment creation for database server and database proxy application testing MariaDB Corporation AB Kirill Krinkin St-Petersburg Electrotechnical University
  • 3. Test environment problem  Server and proxy application testing: – backend is needed – lots of combination of machine configurations and version of backend servers  Maxscale example: – 12 major linux distributions – MariaDB 5.5, 10.0, 10.1, 10.2 – MySQL 5.1, 5.5, 5.6, 5.7 – different topologies – Maxscale itself from CI
  • 4. Requirements  arbitrary number of backend servers;  any version of server software can be installed on every backend server;  different virtual machine providers have to be supported (Virtual Box, Qemu, different cloud providers);  deployment of test environment have to be automated;  several test round can be executed in parallel;  test environment description have to be clear and human readable.
  • 6. VM managers, SW manager  Vagrant, Terraform, Ansible  Chef, Puppet works? try to write/read it: ### Import AWS Provider access config ### require 'yaml' aws_config = YAML.load_file("../aws-config.yml")['aws'] ## of import AWS Provider access config ### Vagrant configuration block ### #################################### Vagrant.configure(2) do |config| ### AWS Provider config block ### ############################################# config.vm.box = "dummy" config.vm.provider :aws do |aws, override| aws.access_key_id = aws_config["access_key_id"] aws.secret_access_key = aws_config["secret_access_key"] aws.keypair_name = aws_config["keypair_name"] aws.region = aws_config["region"] aws.security_groups = aws_config["security_groups"] aws.user_data = aws_config["user_data"] override.ssh.private_key_path = aws_config["pemfile"] override.nfs.functional = false end ## of AWS Provider config block config.vm.synced_folder "/home/vagrant/build-scripts/test-setup-... config.vm.define :node0 do |node0| node0.vm.provider :aws do |aws,override| aws.ami = "ami-1c2e8b6b" aws.instance_type = "t1.micro" override.ssh.username = "ec2-user" end ##--- Chef binding --- node0.vm.provision "chef_solo" do |chef| chef.cookbooks_path = "../recipes/cookbooks/" chef.roles_path = "." chef.add_role "node0" chef.synced_folder_type = "rsync" end #<-- end of chef binding end # -> End definition for machine: node0 config.vm.synced_folder "/home/vagrant/build-scripts/test-setup-... # -> Begin definition for machine: node1 config.vm.define :node1 do |node1| node1.vm.provider :aws do |aws,override| aws.ami = "ami-1c2e8b6b" aws.instance_type = "t1.micro" override.ssh.username = "ec2-user" end ##--- Chef binding ---
  • 7. Make it readable "node0" : { "hostname" : "node0", "box" : "centos7", "product" : { "name": "mariadb", "version": "10.0", "cnf_template" : "server1.cnf", "cnf_template_path": "/home/vagrant/cnf" } }, "node1" : { "hostname" : "node1", "box" : "rhel7", "product" : { "name": "mysql", "version": "5.6", "cnf_template" : "server2.cnf", "cnf_template_path": "/home/vagrant//cnf" } } "node2" : { "hostname" : "node2", "box" : "centos7", "product" : { "name": "galera", "version": "5.5", "cnf_template" : "server-galera3.cnf", "cnf_template_path": "/home/vagrant//cnf" } }
  • 8. boxes.json { "ubuntu_precise": { "provider": "virtualbox", "box": "chef/ubuntu-12.04", "platform": "ubuntu", "platform_version": "precise" }, "centos7" : { "provider": "aws", "ami": "ami-1c2e8b6b", "user": "ec2-user", "default_instance_type": "t1.micro", "platform": "centos", "platform_version": "7" } }
  • 9. Repository description { "product": "mariadb", "version": "10.0.17", "repo": "http://yum.mariadb.org/10.0.17/centos5-amd64", "repo_key": "https://yum.mariadb.org/RPM-GPG-KEY-MariaDB", "platform": "centos", "platform_version": 5} { "product": "mysql", "version": "5.6", "repo": "http://repo.mysql.com/yum/mysql-5.6-community/sles/12/x86_64", "repo_key": "http://repo.mysql.com/RPM-GPG-KEY-mysql", "platform": "sles", "platform_version": 12} We have a generator for MariaDB, MariaDB enterprise, MariaDB Galera, Maxscale, MySQL { "product": "mariadb", "version": "10.0", "repo": "http://yum.mariadb.org/10.0/centos5-amd64", "repo_key": "https://yum.mariadb.org/RPM-GPG-KEY-MariaDB", "platform": "centos", "platform_version": 5}
  • 10. Workflow  write template  './mdbci generate <name>'  './mdbci up <name>'  Get all needed info: './mdbci show …'  Access machines: './mdbci ssh' or directly via 'ssh'  './mdbci destory <name>'
  • 11. Does it work?  9 and 25 machines configurations  40 test runs every day  MariaDB, Maxscale, MariaDB enterprise, MariaDB-Galera  VirtualBox, Amazon EC2, QEMU (plans: Docker, DigitalOcean)  Developers like it: “use ./mdbci ssh and see all log, states, core dumps, use my env for debugging”