MySQL for MongoDB DBAs - Percona€¦ · MySQL for MongoDB DBAs Alexander Rubin Principal...
Transcript of MySQL for MongoDB DBAs - Percona€¦ · MySQL for MongoDB DBAs Alexander Rubin Principal...
MySQL for MongoDB DBAs
Alexander Rubin Principal Architect, Percona May 29, 2015
www.percona.com
About Me
• Working with MySQL for over 10 years – Started at MySQL AB, then Sun Microsystems, then Oracle (MySQL Consulting) – Joined Percona 2 years ago
https://www.linkedin.com/in/alexanderrubin
www.percona.com
My S-Q-L not "My Sequel”Everyone is using MySQL for at least some project?
www.percona.com
/etc/my.cnf• Single config file: /etc/my.cnf or /etc/mysql/my.cnf • https://tools.percona.com/wizard
www.percona.com
“Storage Engines”
••MMAPv1 ••WiredTiger ••TokuMX
••MyISAM •• InnoDB ••TokuDB
Your choice
www.percona.com
HA and Scale-out
••Replication
••Sharding
••Replication/XtraDB cluster
••Sharding* (different solutions)
www.percona.com
MySQL ReplicationSimilar to MongoDB replication
Database
Master Server
Database
Slave Server
MySQL Replication
Search
Reporting
Etc
Database
Slave Server
Database
Slave Server
Database
Slave Servers
Load Balancer
Database
Master Server
Database
Master Server
Database
Slave Server
Database
Slave Server
MySQL Replication
Search
Reporting
Etc
Database
Slave Server
Database
Slave Server
Database
Slave Server
Database
Slave Server
Database
Slave Servers
Database
Slave Servers
Load BalancerLoad Balancer
No automatic failover by default
www.percona.com
Inside MySQL Replication
Web/AppServerWeb/AppServer
Writes & Reads
MySQL Master
I/O Thread
SQL Thread
Writes
relay binlog
MySQL Slave
mysqld
data
index & binlogs
mysqld
databinlogReplication
www.percona.com
MySQL Replication TopologiesMaster > Slave
Masters > Slave (Multi-Source)
Master < > Master (Multi-Master)
Master > Slaves
Circular (Multi-Master)
Master > Slave > Slaves
www.percona.com
Percona XtraDB Cluster
• Scale reads • Provides HA • Does NOT
scale writes
www.percona.com
HA and Scale-out
••w: 1
••~ w: 2
••~ w: 3, j: true (on all nodes)
••Replication (default)
••~ Semi-sync (with 1 slave)
••~ Percona XtraDB Cluster
www.percona.com
MySQL Sharding options
• No default solution everyone is using • Custom solutions • MySQL Fabric, open-source
http://dev.mysql.com/doc/mysql-utilities/1.5/en/fabric.html Beta version
• MaxScale, open-source https://mariadb.com/products/mariadb-maxscale
• Other enterprise Sharding solutions
www.percona.com
More Info
• docs.mongodb.org
• Mtools/mongostat
• MMS
••Dev.mysql.com
••Percona Toolkit (https://www.percona.com/software/percona-toolkit)
••cloud.percona.com
www.percona.com
Thank you!
https://www.linkedin.com/in/alexanderrubin
Alexander Rubin