SlideShare a Scribd company logo
1 of 36
Download to read offline
Event :  AIOUG BANGALORE Chapter Monthly
Date   : 12 Oct 2019
MySQL HA Solutions
Presenter
Karthik P R,
CEO Mydbops
Karthik P R 
MySQL Consultant 
Founder / CEO Mydbops
About Me
Around 9+ Years of experience with MySQL. 
Consulted huge MySQL Farms in India and US 
Ex Yahoo! ( MySQL DBA )
Active MySQL Community Contributor
Tech Speaker 
Founder Mydbops ( 2016 )
Founded in 2016
Grown from a  2 Member team to 30 Members ( 2019) 
Consulting and Services on MySQL / MongoDB
Managed Services for MySQL / MongoDB
20+ Certi ed MySQL DBA 
AWS Partner for databases
300+ Clients and 50+ in Managed services
About Mydbops
Mydbops
Scaling Database Operations
 1 | MySQL an overview
 2 | Role of MySQL in Open Source World
4 |  MySQL Native Replication 
5 | MySQL Cluster Solutions
 6 | MySQL HA Solutions on Cloud
8 | Tools for MySQL HA
3 | High Availability  7 | MySQL Load Balancers and HA 
AGENDA
MySQL High Availability Solutions
MySQL an overview
Journey of Most Famous Open Source Database 
Initial Release May 1995 - MySQL AB
Michael Widenius ( Main Author) 
2008 Sun Microsystem Acquired MySQL AB
2010 Jan Oracle acquired Sun Microsystems 
2010 MariaDB was formed
2015 Oct MySQL 5.7 was released 
2018 Apr MySQL 8 was released
Role of MySQL in Open Source World
Widely used open Source RDBMS
Ranks 2nd in DB engine ranking ( Following Oracle) 
Most widely used service in Cloud
Adopted by top tech companies and many startups
Scales well for most work load
Very strong MySQL Open Source Community  
Popularity grows day by day
Role of MySQL in Open Source World
 1 | MySQL an overview
 2 | Role of MySQL in Open Source World
4 |  MySQL Native Replication 
5 | MySQL Cluster Solutions
 6 | MySQL HA Solutions on Cloud
8 | Tools for MySQL HA
3 | High Availability  7 | MySQL Load Balancers and HA 
AGENDA
MySQL High Availability Solutions
High Availability 
Reduced downtime (Zero downtime in ideal world) 
Ensure system performance ( Latency )
Data consistency across nodes
 HA = Redundancy 
Uptime
PercentilePercentile
TargetTarget
Max DowntimeMax Downtime
( in a Year )( in a Year )
99% 3.65 Days
99.5% 1.83 Days
99.9% 8.76 Hours
99.9% 52.56 Minutes
99.999% 5.25 Minutes
99.9999% 31.5 Minutes
High Availability 
Replication is the common Solution in MySQL
Types of Replication 
Async Replication ( Native Replication )
Sync Replication ( Virtually Synchronous )
MySQL Architecture
 1 | MySQL an overview
 2 | Role of MySQL in Open Source World
4 |  MySQL Native Replication 
5 | MySQL Cluster Solutions
 6 | MySQL HA Solutions on Cloud
8 | Tools for MySQL HA
3 | High Availability  7 | MySQL Load Balancers and HA 
AGENDA
MySQL High Availability Solutions
MySQL  Native Replication Architecture
Native MySQL Replication 
Replication is a most notable feature in MySQL 
Native MySQL Replication is logical replication
Binary logs helps in recording changes 
Replication is Asynchronous 
Scale out more with replication 
Row based replication is available from MySQL 5.1
Binlog Co-ordinates or GTID based replication
Master - Slave Architecture
Master - Master ( Active - Active )
Master - Multi Slave 
Master - Master ( Active - Passive )
Advantages of Native Replication
Simple solution and easy to mange .
GTID can make switch over / Fail over easy. 
Multi threaded (Parallel) Replication can make sync faster.
Much reduced latency comparing to other solutions.
Good Solution for WAN based data replication.
Data Filtering can be done.
Huge transactions are supported.
Most widely adapted solution 
Dis Advantages of Native Replication
There is a data lag always.
Data can drift / Manual override can break replication.
Huge transactions can cause heavy lag.
Need tools for Automatic master promotion
 1 | MySQL an overview
 2 | Role of MySQL in Open Source World
4 |  MySQL Native Replication 
5 | MySQL Cluster Solutions
 6 | MySQL HA Solutions on Cloud
8 | Tools for MySQL HA
3 | High Availability  7 | MySQL Load Balancers and HA 
AGENDA
MySQL High Availability Solutions
MySQL Cluster Solutions
Synchronous Replication
Galera Cluster 
Group Replication 
NDB Cluster
MySQL Cluster Solutions
Synchronous Replication using two phase Commit 
Latency at writes 
Read/Writes from any node
Shared Nothing Architecture
Auto master promotion ( Single Writer mode )
 Ensure data consistency 
Galera Cluster 
Third party Replication Plugin
Codership Maintains the code  
Virtually Synchronous 
 Multi Master Cluster
Zero Slave lag
Quorum has to be maintained 
More stable and proven solution 
Galera Cluster 
Need minimum three nodes
Replication is handled wsrep plugin 
Percona Cluster or MariaDB Cluster (Bundled )
 Auto Node Provision 
ProxySQL / Maxscale integration makes it better
Supports MySQL 5.5,5.6,5.7 and 8.0
MySQL Group Replication
Inbuilt within MySQL
Uses MySQL Binary log for replication
Ease deployment with MySQL Shell
 Auto Node Provision with Clone plugin.
ProxySQL  integration makes it better.
MySQL Router can be used too.
Supports MySQL 5.7 and 8.0
MySQL Group Replication
Supports Single writer mode
GTID and INNODB engine only
Works for OLTP work load.
More stable in MySQL 8.0.
Supports all Platforms ( Windows too)
 1 | MySQL an overview
 2 | Role of MySQL in Open Source World
4 |  MySQL Native Replication 
5 | MySQL Cluster Solutions
 6 | MySQL HA Solutions on Cloud
8 | Tools for MySQL HA
3 | High Availability  7 | MySQL Load Balancers and HA 
AGENDA
MySQL High Availability Solutions
MySQL HA Solution on Cloud ( AWS )
DBaaS ( RDS / Aurora )
RDS MySQL inbuilt Multi AZ 
Aurora MySQL is Amazon Proprietary 
Aurora uses storage based replication 
 Good for read scaling   
Single Master & Multi readers ( Single read end points ).
 Maxscale and ProxySQL integration. 
Aurora Supports only MySQL 5.6 & 5.7
 1 | MySQL an overview
 2 | Role of MySQL in Open Source World
4 |  MySQL Native Replication 
5 | MySQL Cluster Solutions
 6 | MySQL HA Solutions on Cloud
8 | Tools for MySQL HA
3 | High Availability  7 | MySQL Load Balancers and HA 
AGENDA
MySQL High Availability Solutions
MySQL Load Balancers and HA
Database Availability is hard 
Seem less switchover needs Load Balancers.
TCP Load balancers
HAProxy
MySQL Router
SQL aware load Balancers 
ProxySQL
Maxscale  
MySQL Load Balancers and HA
SQL Intelligence helps in 
Master switch ( traffic Route )
Read write Balancing 
Query Rewrites
Query Caching
Query Filtering
Support all Architectures 
 1 | MySQL an overview
 2 | Role of MySQL in Open Source World
4 |  MySQL Native Replication 
5 | MySQL Cluster Solutions
 6 | MySQL HA Solutions on Cloud
8 | Tools for MySQL HA
3 | High Availability  7 | MySQL Load Balancers and HA 
AGENDA
MySQL High Availability Solutions
Tools for MySQL HA
Orchestrator
Helps in MySQL Replication topology handling
Smart node picking
GUI Support ,CLI , API
Created and Maintained by Github Engineers
MySQL MHA
Automated Failover for Native replication 
Made by Yoshinori ( Facebook ) 
DO YOU HAVE ANY QUESTIONS?
THANK YOU!

More Related Content

What's hot

MariaDB Galera Cluster
MariaDB Galera ClusterMariaDB Galera Cluster
MariaDB Galera Cluster
Abdul Manaf
 

What's hot (20)

Best practices for MySQL High Availability Tutorial
Best practices for MySQL High Availability TutorialBest practices for MySQL High Availability Tutorial
Best practices for MySQL High Availability Tutorial
 
MariaDB Galera Cluster
MariaDB Galera ClusterMariaDB Galera Cluster
MariaDB Galera Cluster
 
My sql failover test using orchestrator
My sql failover test  using orchestratorMy sql failover test  using orchestrator
My sql failover test using orchestrator
 
Maxscale 소개 1.1.1
Maxscale 소개 1.1.1Maxscale 소개 1.1.1
Maxscale 소개 1.1.1
 
The consequences of sync_binlog != 1
The consequences of sync_binlog != 1The consequences of sync_binlog != 1
The consequences of sync_binlog != 1
 
MariaDB: in-depth (hands on training in Seoul)
MariaDB: in-depth (hands on training in Seoul)MariaDB: in-depth (hands on training in Seoul)
MariaDB: in-depth (hands on training in Seoul)
 
MySQL Advanced Administrator 2021 - 네오클로바
MySQL Advanced Administrator 2021 - 네오클로바MySQL Advanced Administrator 2021 - 네오클로바
MySQL Advanced Administrator 2021 - 네오클로바
 
MariaDB 마이그레이션 - 네오클로바
MariaDB 마이그레이션 - 네오클로바MariaDB 마이그레이션 - 네오클로바
MariaDB 마이그레이션 - 네오클로바
 
Maxscale_메뉴얼
Maxscale_메뉴얼Maxscale_메뉴얼
Maxscale_메뉴얼
 
What is new in MariaDB 10.6?
What is new in MariaDB 10.6?What is new in MariaDB 10.6?
What is new in MariaDB 10.6?
 
Using galera replication to create geo distributed clusters on the wan
Using galera replication to create geo distributed clusters on the wanUsing galera replication to create geo distributed clusters on the wan
Using galera replication to create geo distributed clusters on the wan
 
MariaDB Performance Tuning and Optimization
MariaDB Performance Tuning and OptimizationMariaDB Performance Tuning and Optimization
MariaDB Performance Tuning and Optimization
 
MySQL Group Replication
MySQL Group ReplicationMySQL Group Replication
MySQL Group Replication
 
Maxscale switchover, failover, and auto rejoin
Maxscale switchover, failover, and auto rejoinMaxscale switchover, failover, and auto rejoin
Maxscale switchover, failover, and auto rejoin
 
Query logging with proxysql
Query logging with proxysqlQuery logging with proxysql
Query logging with proxysql
 
Oracle RAC 19c: Best Practices and Secret Internals
Oracle RAC 19c: Best Practices and Secret InternalsOracle RAC 19c: Best Practices and Secret Internals
Oracle RAC 19c: Best Practices and Secret Internals
 
MySQL Parallel Replication: All the 5.7 and 8.0 Details (LOGICAL_CLOCK)
MySQL Parallel Replication: All the 5.7 and 8.0 Details (LOGICAL_CLOCK)MySQL Parallel Replication: All the 5.7 and 8.0 Details (LOGICAL_CLOCK)
MySQL Parallel Replication: All the 5.7 and 8.0 Details (LOGICAL_CLOCK)
 
MySQL Database Architectures - InnoDB ReplicaSet & Cluster
MySQL Database Architectures - InnoDB ReplicaSet & ClusterMySQL Database Architectures - InnoDB ReplicaSet & Cluster
MySQL Database Architectures - InnoDB ReplicaSet & Cluster
 
Migration to Oracle Multitenant
Migration to Oracle MultitenantMigration to Oracle Multitenant
Migration to Oracle Multitenant
 
High Availability for Oracle SE2
High Availability for Oracle SE2High Availability for Oracle SE2
High Availability for Oracle SE2
 

Similar to MySQL High Availability Solutions

Webinar Slides: MySQL HA/DR/Geo-Scale - High Noon #5: Oracle’s InnoDB Cluster
Webinar Slides: MySQL HA/DR/Geo-Scale - High Noon #5: Oracle’s InnoDB ClusterWebinar Slides: MySQL HA/DR/Geo-Scale - High Noon #5: Oracle’s InnoDB Cluster
Webinar Slides: MySQL HA/DR/Geo-Scale - High Noon #5: Oracle’s InnoDB Cluster
Continuent
 
Webinar Slides: MySQL HA/DR/Geo-Scale - High Noon #7: ClusterControl
Webinar Slides: MySQL HA/DR/Geo-Scale - High Noon #7: ClusterControlWebinar Slides: MySQL HA/DR/Geo-Scale - High Noon #7: ClusterControl
Webinar Slides: MySQL HA/DR/Geo-Scale - High Noon #7: ClusterControl
Continuent
 
Webinar Slides: MySQL HA/DR/Geo-Scale - High Noon #4: MS Azure Database MySQL
Webinar Slides: MySQL HA/DR/Geo-Scale - High Noon #4: MS Azure Database MySQLWebinar Slides: MySQL HA/DR/Geo-Scale - High Noon #4: MS Azure Database MySQL
Webinar Slides: MySQL HA/DR/Geo-Scale - High Noon #4: MS Azure Database MySQL
Continuent
 
Mysql User Camp : 20th June - Mysql New Features
Mysql User Camp : 20th June - Mysql New FeaturesMysql User Camp : 20th June - Mysql New Features
Mysql User Camp : 20th June - Mysql New Features
Tarique Saleem
 

Similar to MySQL High Availability Solutions (20)

MySQL InnoDB Cluster - Meetup Oracle MySQL / AFUP Paris
MySQL InnoDB Cluster - Meetup Oracle MySQL / AFUP ParisMySQL InnoDB Cluster - Meetup Oracle MySQL / AFUP Paris
MySQL InnoDB Cluster - Meetup Oracle MySQL / AFUP Paris
 
Webinar Slides: MySQL HA/DR/Geo-Scale - High Noon #5: Oracle’s InnoDB Cluster
Webinar Slides: MySQL HA/DR/Geo-Scale - High Noon #5: Oracle’s InnoDB ClusterWebinar Slides: MySQL HA/DR/Geo-Scale - High Noon #5: Oracle’s InnoDB Cluster
Webinar Slides: MySQL HA/DR/Geo-Scale - High Noon #5: Oracle’s InnoDB Cluster
 
MySQL Day Paris 2016 - MySQL HA: InnoDB Cluster and NDB Cluster
MySQL Day Paris 2016 - MySQL HA: InnoDB Cluster and NDB ClusterMySQL Day Paris 2016 - MySQL HA: InnoDB Cluster and NDB Cluster
MySQL Day Paris 2016 - MySQL HA: InnoDB Cluster and NDB Cluster
 
MySQL InnoDB Cluster and NDB Cluster
MySQL InnoDB Cluster and NDB ClusterMySQL InnoDB Cluster and NDB Cluster
MySQL InnoDB Cluster and NDB Cluster
 
MySQL 5.7 InnoDB Cluster (Jan 2018)
MySQL 5.7 InnoDB Cluster (Jan 2018)MySQL 5.7 InnoDB Cluster (Jan 2018)
MySQL 5.7 InnoDB Cluster (Jan 2018)
 
MySQL
MySQLMySQL
MySQL
 
MySQL High Availability -- InnoDB Clusters
MySQL High Availability -- InnoDB ClustersMySQL High Availability -- InnoDB Clusters
MySQL High Availability -- InnoDB Clusters
 
Scaling MySQL -- Swanseacon.co.uk
Scaling MySQL -- Swanseacon.co.uk Scaling MySQL -- Swanseacon.co.uk
Scaling MySQL -- Swanseacon.co.uk
 
Webinar Slides: MySQL HA/DR/Geo-Scale - High Noon #7: ClusterControl
Webinar Slides: MySQL HA/DR/Geo-Scale - High Noon #7: ClusterControlWebinar Slides: MySQL HA/DR/Geo-Scale - High Noon #7: ClusterControl
Webinar Slides: MySQL HA/DR/Geo-Scale - High Noon #7: ClusterControl
 
My sql indo_comm
My sql indo_commMy sql indo_comm
My sql indo_comm
 
MySQL InnoDB Cluster and MySQL Group Replication @HKOSC 2017
MySQL InnoDB Cluster and MySQL Group Replication @HKOSC 2017MySQL InnoDB Cluster and MySQL Group Replication @HKOSC 2017
MySQL InnoDB Cluster and MySQL Group Replication @HKOSC 2017
 
MySQL no Paypal Tesla e Uber
MySQL no Paypal Tesla e UberMySQL no Paypal Tesla e Uber
MySQL no Paypal Tesla e Uber
 
Webinar Slides: MySQL HA/DR/Geo-Scale - High Noon #4: MS Azure Database MySQL
Webinar Slides: MySQL HA/DR/Geo-Scale - High Noon #4: MS Azure Database MySQLWebinar Slides: MySQL HA/DR/Geo-Scale - High Noon #4: MS Azure Database MySQL
Webinar Slides: MySQL HA/DR/Geo-Scale - High Noon #4: MS Azure Database MySQL
 
Sunshine php my sql 8.0 v2
Sunshine php my sql 8.0 v2Sunshine php my sql 8.0 v2
Sunshine php my sql 8.0 v2
 
MySQL Options in OpenStack
MySQL Options in OpenStackMySQL Options in OpenStack
MySQL Options in OpenStack
 
OpenStack Days East -- MySQL Options in OpenStack
OpenStack Days East -- MySQL Options in OpenStackOpenStack Days East -- MySQL Options in OpenStack
OpenStack Days East -- MySQL Options in OpenStack
 
MySQL for Oracle DBA -- Rocky Mountain Oracle User Group Training Days '15
MySQL for Oracle DBA -- Rocky Mountain Oracle User Group Training Days '15MySQL for Oracle DBA -- Rocky Mountain Oracle User Group Training Days '15
MySQL for Oracle DBA -- Rocky Mountain Oracle User Group Training Days '15
 
MySQL Innovation from 5.7 to 8.0
MySQL Innovation from 5.7 to 8.0MySQL Innovation from 5.7 to 8.0
MySQL Innovation from 5.7 to 8.0
 
MySQL Innovation: from 5.7 to 8.0
MySQL Innovation:  from 5.7 to 8.0MySQL Innovation:  from 5.7 to 8.0
MySQL Innovation: from 5.7 to 8.0
 
Mysql User Camp : 20th June - Mysql New Features
Mysql User Camp : 20th June - Mysql New FeaturesMysql User Camp : 20th June - Mysql New Features
Mysql User Camp : 20th June - Mysql New Features
 

More from Mydbops

Efficient MySQL Indexing and what's new in MySQL Explain
Efficient MySQL Indexing and what's new in MySQL ExplainEfficient MySQL Indexing and what's new in MySQL Explain
Efficient MySQL Indexing and what's new in MySQL Explain
Mydbops
 

More from Mydbops (20)

Efficient MySQL Indexing and what's new in MySQL Explain
Efficient MySQL Indexing and what's new in MySQL ExplainEfficient MySQL Indexing and what's new in MySQL Explain
Efficient MySQL Indexing and what's new in MySQL Explain
 
Scale your database traffic with Read & Write split using MySQL Router
Scale your database traffic with Read & Write split using MySQL RouterScale your database traffic with Read & Write split using MySQL Router
Scale your database traffic with Read & Write split using MySQL Router
 
PostgreSQL Schema Changes with pg-osc - Mydbops @ PGConf India 2024
PostgreSQL Schema Changes with pg-osc - Mydbops @ PGConf India 2024PostgreSQL Schema Changes with pg-osc - Mydbops @ PGConf India 2024
PostgreSQL Schema Changes with pg-osc - Mydbops @ PGConf India 2024
 
Choosing the Right Database: Exploring MySQL Alternatives for Modern Applicat...
Choosing the Right Database: Exploring MySQL Alternatives for Modern Applicat...Choosing the Right Database: Exploring MySQL Alternatives for Modern Applicat...
Choosing the Right Database: Exploring MySQL Alternatives for Modern Applicat...
 
Mastering Aurora PostgreSQL Clusters for Disaster Recovery
Mastering Aurora PostgreSQL Clusters for Disaster RecoveryMastering Aurora PostgreSQL Clusters for Disaster Recovery
Mastering Aurora PostgreSQL Clusters for Disaster Recovery
 
Navigating Transactions: ACID Complexity in Modern Databases- Mydbops Open So...
Navigating Transactions: ACID Complexity in Modern Databases- Mydbops Open So...Navigating Transactions: ACID Complexity in Modern Databases- Mydbops Open So...
Navigating Transactions: ACID Complexity in Modern Databases- Mydbops Open So...
 
AWS RDS in MySQL 2023 Vinoth Kanna @ Mydbops OpenSource Database Meetup 15
AWS RDS in MySQL 2023 Vinoth Kanna @ Mydbops OpenSource Database Meetup 15AWS RDS in MySQL 2023 Vinoth Kanna @ Mydbops OpenSource Database Meetup 15
AWS RDS in MySQL 2023 Vinoth Kanna @ Mydbops OpenSource Database Meetup 15
 
Data-at-scale-with-TIDB Mydbops Co-Founder Kabilesh PR at LSPE Event
Data-at-scale-with-TIDB Mydbops Co-Founder Kabilesh PR at LSPE EventData-at-scale-with-TIDB Mydbops Co-Founder Kabilesh PR at LSPE Event
Data-at-scale-with-TIDB Mydbops Co-Founder Kabilesh PR at LSPE Event
 
MySQL Transformation Case Study: 80% Cost Savings & Uninterrupted Availabilit...
MySQL Transformation Case Study: 80% Cost Savings & Uninterrupted Availabilit...MySQL Transformation Case Study: 80% Cost Savings & Uninterrupted Availabilit...
MySQL Transformation Case Study: 80% Cost Savings & Uninterrupted Availabilit...
 
Scaling-MongoDB-with-Horizontal-and-Vertical-Sharding Mydbops Opensource Data...
Scaling-MongoDB-with-Horizontal-and-Vertical-Sharding Mydbops Opensource Data...Scaling-MongoDB-with-Horizontal-and-Vertical-Sharding Mydbops Opensource Data...
Scaling-MongoDB-with-Horizontal-and-Vertical-Sharding Mydbops Opensource Data...
 
Mastering MongoDB Atlas: Essentials of Diagnostics and Debugging in the Cloud...
Mastering MongoDB Atlas: Essentials of Diagnostics and Debugging in the Cloud...Mastering MongoDB Atlas: Essentials of Diagnostics and Debugging in the Cloud...
Mastering MongoDB Atlas: Essentials of Diagnostics and Debugging in the Cloud...
 
Data Organisation: Table Partitioning in PostgreSQL
Data Organisation: Table Partitioning in PostgreSQLData Organisation: Table Partitioning in PostgreSQL
Data Organisation: Table Partitioning in PostgreSQL
 
Navigating MongoDB's Queryable Encryption for Ultimate Security - Mydbops
Navigating MongoDB's Queryable Encryption for Ultimate Security - MydbopsNavigating MongoDB's Queryable Encryption for Ultimate Security - Mydbops
Navigating MongoDB's Queryable Encryption for Ultimate Security - Mydbops
 
Data High Availability With TIDB
Data High Availability With TIDBData High Availability With TIDB
Data High Availability With TIDB
 
Mastering Database Migration_ Native replication (8.0) to InnoDB Cluster (8.0...
Mastering Database Migration_ Native replication (8.0) to InnoDB Cluster (8.0...Mastering Database Migration_ Native replication (8.0) to InnoDB Cluster (8.0...
Mastering Database Migration_ Native replication (8.0) to InnoDB Cluster (8.0...
 
Enhancing Security of MySQL Connections using SSL certificates
Enhancing Security of MySQL Connections using SSL certificatesEnhancing Security of MySQL Connections using SSL certificates
Enhancing Security of MySQL Connections using SSL certificates
 
Exploring the Fundamentals of YugabyteDB - Mydbops
Exploring the Fundamentals of YugabyteDB - Mydbops Exploring the Fundamentals of YugabyteDB - Mydbops
Exploring the Fundamentals of YugabyteDB - Mydbops
 
Time series in MongoDB - Mydbops
Time series in MongoDB - Mydbops Time series in MongoDB - Mydbops
Time series in MongoDB - Mydbops
 
TiDB in a Nutshell - Power of Open-Source Distributed SQL Database - Mydbops
TiDB in a Nutshell - Power of Open-Source Distributed SQL Database - MydbopsTiDB in a Nutshell - Power of Open-Source Distributed SQL Database - Mydbops
TiDB in a Nutshell - Power of Open-Source Distributed SQL Database - Mydbops
 
Achieving High Availability in PostgreSQL
Achieving High Availability in PostgreSQLAchieving High Availability in PostgreSQL
Achieving High Availability in PostgreSQL
 

Recently uploaded

audience research (emma) 1.pptxkkkkkkkkkkkkkkkkk
audience research (emma) 1.pptxkkkkkkkkkkkkkkkkkaudience research (emma) 1.pptxkkkkkkkkkkkkkkkkk
audience research (emma) 1.pptxkkkkkkkkkkkkkkkkk
lolsDocherty
 
Production 2024 sunderland culture final - Copy.pptx
Production 2024 sunderland culture final - Copy.pptxProduction 2024 sunderland culture final - Copy.pptx
Production 2024 sunderland culture final - Copy.pptx
ChloeMeadows1
 

Recently uploaded (16)

iThome_CYBERSEC2024_Drive_Into_the_DarkWeb
iThome_CYBERSEC2024_Drive_Into_the_DarkWebiThome_CYBERSEC2024_Drive_Into_the_DarkWeb
iThome_CYBERSEC2024_Drive_Into_the_DarkWeb
 
I’ll See Y’All Motherfuckers In Game 7 Shirt
I’ll See Y’All Motherfuckers In Game 7 ShirtI’ll See Y’All Motherfuckers In Game 7 Shirt
I’ll See Y’All Motherfuckers In Game 7 Shirt
 
Reggie miller choke t shirtsReggie miller choke t shirts
Reggie miller choke t shirtsReggie miller choke t shirtsReggie miller choke t shirtsReggie miller choke t shirts
Reggie miller choke t shirtsReggie miller choke t shirts
 
Cyber Security Services Unveiled: Strategies to Secure Your Digital Presence
Cyber Security Services Unveiled: Strategies to Secure Your Digital PresenceCyber Security Services Unveiled: Strategies to Secure Your Digital Presence
Cyber Security Services Unveiled: Strategies to Secure Your Digital Presence
 
audience research (emma) 1.pptxkkkkkkkkkkkkkkkkk
audience research (emma) 1.pptxkkkkkkkkkkkkkkkkkaudience research (emma) 1.pptxkkkkkkkkkkkkkkkkk
audience research (emma) 1.pptxkkkkkkkkkkkkkkkkk
 
Production 2024 sunderland culture final - Copy.pptx
Production 2024 sunderland culture final - Copy.pptxProduction 2024 sunderland culture final - Copy.pptx
Production 2024 sunderland culture final - Copy.pptx
 
Bug Bounty Blueprint : A Beginner's Guide
Bug Bounty Blueprint : A Beginner's GuideBug Bounty Blueprint : A Beginner's Guide
Bug Bounty Blueprint : A Beginner's Guide
 
Development Lifecycle.pptx for the secure development of apps
Development Lifecycle.pptx for the secure development of appsDevelopment Lifecycle.pptx for the secure development of apps
Development Lifecycle.pptx for the secure development of apps
 
Statistical Analysis of DNS Latencies.pdf
Statistical Analysis of DNS Latencies.pdfStatistical Analysis of DNS Latencies.pdf
Statistical Analysis of DNS Latencies.pdf
 
The Use of AI in Indonesia Election 2024: A Case Study
The Use of AI in Indonesia Election 2024: A Case StudyThe Use of AI in Indonesia Election 2024: A Case Study
The Use of AI in Indonesia Election 2024: A Case Study
 
Premier Mobile App Development Agency in USA.pdf
Premier Mobile App Development Agency in USA.pdfPremier Mobile App Development Agency in USA.pdf
Premier Mobile App Development Agency in USA.pdf
 
TORTOGEL TELAH MENJADI SALAH SATU PLATFORM PERMAINAN PALING FAVORIT.
TORTOGEL TELAH MENJADI SALAH SATU PLATFORM PERMAINAN PALING FAVORIT.TORTOGEL TELAH MENJADI SALAH SATU PLATFORM PERMAINAN PALING FAVORIT.
TORTOGEL TELAH MENJADI SALAH SATU PLATFORM PERMAINAN PALING FAVORIT.
 
How Do I Begin the Linksys Velop Setup Process?
How Do I Begin the Linksys Velop Setup Process?How Do I Begin the Linksys Velop Setup Process?
How Do I Begin the Linksys Velop Setup Process?
 
Thank You Luv I’ll Never Walk Alone Again T shirts
Thank You Luv I’ll Never Walk Alone Again T shirtsThank You Luv I’ll Never Walk Alone Again T shirts
Thank You Luv I’ll Never Walk Alone Again T shirts
 
Pvtaan Social media marketing proposal.pdf
Pvtaan Social media marketing proposal.pdfPvtaan Social media marketing proposal.pdf
Pvtaan Social media marketing proposal.pdf
 
GOOGLE Io 2024 At takes center stage.pdf
GOOGLE Io 2024 At takes center stage.pdfGOOGLE Io 2024 At takes center stage.pdf
GOOGLE Io 2024 At takes center stage.pdf
 

MySQL High Availability Solutions

  • 1. Event :  AIOUG BANGALORE Chapter Monthly Date   : 12 Oct 2019 MySQL HA Solutions Presenter Karthik P R, CEO Mydbops
  • 2. Karthik P R  MySQL Consultant  Founder / CEO Mydbops About Me Around 9+ Years of experience with MySQL.  Consulted huge MySQL Farms in India and US  Ex Yahoo! ( MySQL DBA ) Active MySQL Community Contributor Tech Speaker  Founder Mydbops ( 2016 )
  • 3. Founded in 2016 Grown from a  2 Member team to 30 Members ( 2019)  Consulting and Services on MySQL / MongoDB Managed Services for MySQL / MongoDB 20+ Certi ed MySQL DBA  AWS Partner for databases 300+ Clients and 50+ in Managed services About Mydbops Mydbops Scaling Database Operations
  • 4.  1 | MySQL an overview  2 | Role of MySQL in Open Source World 4 |  MySQL Native Replication  5 | MySQL Cluster Solutions  6 | MySQL HA Solutions on Cloud 8 | Tools for MySQL HA 3 | High Availability  7 | MySQL Load Balancers and HA  AGENDA MySQL High Availability Solutions
  • 5. MySQL an overview Journey of Most Famous Open Source Database  Initial Release May 1995 - MySQL AB Michael Widenius ( Main Author)  2008 Sun Microsystem Acquired MySQL AB 2010 Jan Oracle acquired Sun Microsystems  2010 MariaDB was formed 2015 Oct MySQL 5.7 was released  2018 Apr MySQL 8 was released
  • 6. Role of MySQL in Open Source World Widely used open Source RDBMS Ranks 2nd in DB engine ranking ( Following Oracle)  Most widely used service in Cloud Adopted by top tech companies and many startups Scales well for most work load Very strong MySQL Open Source Community   Popularity grows day by day
  • 7. Role of MySQL in Open Source World
  • 8.  1 | MySQL an overview  2 | Role of MySQL in Open Source World 4 |  MySQL Native Replication  5 | MySQL Cluster Solutions  6 | MySQL HA Solutions on Cloud 8 | Tools for MySQL HA 3 | High Availability  7 | MySQL Load Balancers and HA  AGENDA MySQL High Availability Solutions
  • 9. High Availability  Reduced downtime (Zero downtime in ideal world)  Ensure system performance ( Latency ) Data consistency across nodes  HA = Redundancy 
  • 10. Uptime PercentilePercentile TargetTarget Max DowntimeMax Downtime ( in a Year )( in a Year ) 99% 3.65 Days 99.5% 1.83 Days 99.9% 8.76 Hours 99.9% 52.56 Minutes 99.999% 5.25 Minutes 99.9999% 31.5 Minutes
  • 11. High Availability  Replication is the common Solution in MySQL Types of Replication  Async Replication ( Native Replication ) Sync Replication ( Virtually Synchronous )
  • 13.  1 | MySQL an overview  2 | Role of MySQL in Open Source World 4 |  MySQL Native Replication  5 | MySQL Cluster Solutions  6 | MySQL HA Solutions on Cloud 8 | Tools for MySQL HA 3 | High Availability  7 | MySQL Load Balancers and HA  AGENDA MySQL High Availability Solutions
  • 15. Native MySQL Replication  Replication is a most notable feature in MySQL  Native MySQL Replication is logical replication Binary logs helps in recording changes  Replication is Asynchronous  Scale out more with replication  Row based replication is available from MySQL 5.1 Binlog Co-ordinates or GTID based replication
  • 16. Master - Slave Architecture
  • 17. Master - Master ( Active - Active )
  • 18. Master - Multi Slave 
  • 19. Master - Master ( Active - Passive )
  • 20. Advantages of Native Replication Simple solution and easy to mange . GTID can make switch over / Fail over easy.  Multi threaded (Parallel) Replication can make sync faster. Much reduced latency comparing to other solutions. Good Solution for WAN based data replication. Data Filtering can be done. Huge transactions are supported. Most widely adapted solution 
  • 21. Dis Advantages of Native Replication There is a data lag always. Data can drift / Manual override can break replication. Huge transactions can cause heavy lag. Need tools for Automatic master promotion
  • 22.  1 | MySQL an overview  2 | Role of MySQL in Open Source World 4 |  MySQL Native Replication  5 | MySQL Cluster Solutions  6 | MySQL HA Solutions on Cloud 8 | Tools for MySQL HA 3 | High Availability  7 | MySQL Load Balancers and HA  AGENDA MySQL High Availability Solutions
  • 23. MySQL Cluster Solutions Synchronous Replication Galera Cluster  Group Replication  NDB Cluster
  • 24. MySQL Cluster Solutions Synchronous Replication using two phase Commit  Latency at writes  Read/Writes from any node Shared Nothing Architecture Auto master promotion ( Single Writer mode )  Ensure data consistency 
  • 25. Galera Cluster  Third party Replication Plugin Codership Maintains the code   Virtually Synchronous   Multi Master Cluster Zero Slave lag Quorum has to be maintained  More stable and proven solution 
  • 26. Galera Cluster  Need minimum three nodes Replication is handled wsrep plugin  Percona Cluster or MariaDB Cluster (Bundled )  Auto Node Provision  ProxySQL / Maxscale integration makes it better Supports MySQL 5.5,5.6,5.7 and 8.0
  • 27. MySQL Group Replication Inbuilt within MySQL Uses MySQL Binary log for replication Ease deployment with MySQL Shell  Auto Node Provision with Clone plugin. ProxySQL  integration makes it better. MySQL Router can be used too. Supports MySQL 5.7 and 8.0
  • 28. MySQL Group Replication Supports Single writer mode GTID and INNODB engine only Works for OLTP work load. More stable in MySQL 8.0. Supports all Platforms ( Windows too)
  • 29.  1 | MySQL an overview  2 | Role of MySQL in Open Source World 4 |  MySQL Native Replication  5 | MySQL Cluster Solutions  6 | MySQL HA Solutions on Cloud 8 | Tools for MySQL HA 3 | High Availability  7 | MySQL Load Balancers and HA  AGENDA MySQL High Availability Solutions
  • 30. MySQL HA Solution on Cloud ( AWS ) DBaaS ( RDS / Aurora ) RDS MySQL inbuilt Multi AZ  Aurora MySQL is Amazon Proprietary  Aurora uses storage based replication   Good for read scaling    Single Master & Multi readers ( Single read end points ).  Maxscale and ProxySQL integration.  Aurora Supports only MySQL 5.6 & 5.7
  • 31.  1 | MySQL an overview  2 | Role of MySQL in Open Source World 4 |  MySQL Native Replication  5 | MySQL Cluster Solutions  6 | MySQL HA Solutions on Cloud 8 | Tools for MySQL HA 3 | High Availability  7 | MySQL Load Balancers and HA  AGENDA MySQL High Availability Solutions
  • 32. MySQL Load Balancers and HA Database Availability is hard  Seem less switchover needs Load Balancers. TCP Load balancers HAProxy MySQL Router SQL aware load Balancers  ProxySQL Maxscale  
  • 33. MySQL Load Balancers and HA SQL Intelligence helps in  Master switch ( traffic Route ) Read write Balancing  Query Rewrites Query Caching Query Filtering Support all Architectures 
  • 34.  1 | MySQL an overview  2 | Role of MySQL in Open Source World 4 |  MySQL Native Replication  5 | MySQL Cluster Solutions  6 | MySQL HA Solutions on Cloud 8 | Tools for MySQL HA 3 | High Availability  7 | MySQL Load Balancers and HA  AGENDA MySQL High Availability Solutions
  • 35. Tools for MySQL HA Orchestrator Helps in MySQL Replication topology handling Smart node picking GUI Support ,CLI , API Created and Maintained by Github Engineers MySQL MHA Automated Failover for Native replication  Made by Yoshinori ( Facebook ) 
  • 36. DO YOU HAVE ANY QUESTIONS? THANK YOU!