SlideShare a Scribd company logo
1 of 25
© SkySQL Corporation Ab. Company Confidential.09/06/2014
© SkySQL Corporation Ab. Company Confidential.
High Availability with MariaDB Enterprise
Stephane Varoqui
Professional Services, SkySQL
* *09/06/2014
© SkySQL Corporation Ab. Company Confidential.
Agenda
❏ Introduction to High Availability
❏ Different services that need HA
❏ Different components of High Availability
❏ Different MariaDB HA Solutions
❏ HA using MariaDB Replication
❏ HA using MariaDB Galera Cluster
09/06/2014
© SkySQL Corporation Ab. Company Confidential.
Introduction to High Availability
High availability is a system design
protocol and associated
implementation that ensures a certain
degree of operational continuity during
a given measurement period
09/06/2014
© SkySQL Corporation Ab. Company Confidential.
Introduction to High Availability
09/06/2014
❏ High Availability != Long Uptime
“up” might still not be accessible
“down” just once, but for a long time
❏ High Availability rather means
Long Mean Time Between Failures (MTBF)
Short Mean Time To Recover (MTTR)
© SkySQL Corporation Ab. Company Confidential.
Introduction to High Availability
❏ Availability level is measured as the ratio of time
the system is available over a year, expressed as a
percentage
❏ 99.9% availability means that the system is available
at least 8751 of 8760 hours in a year, or that it is
unavailable at the most 9 hours per year
❏ 99.999% availability means that the system is
available at least 525595 or 525600 minutes in a
year, or that it is unavailable at the most 5 minutes
per year
09/06/2014
© SkySQL Corporation Ab. Company Confidential.
Maintaining High Availability
❏ There are two common situations that we try to
protect ourselves from using an HA solution
❏ Datacenter failure – A whole datacenter
becomes unavailable for some reason, like
power failure, network failure, a virus or similar
situations
❏ Server failure – An individual
server fails because of a
hardware failure or something
similar
09/06/2014
© SkySQL Corporation Ab. Company Confidential.
Layers in HA Solution
❏ All services that make up the application stack
needs HA for the system to achieve HA
Web servers
Application servers
Applications
Database servers
Storage
Network
09/06/2014
TCO for
Unbreakable
Hardware
© SkySQL Corporation Ab. Company Confidential.
Services in an HA Solution
❏ Of the different types of services, there are
two types
Stateless services
These servers has no state beyond the current operation. If such a
server fails, another server of the same type can replace it without
having to transfer any set of data. Webservers and application
servers are typical stateless services
Stateful services
These services maintains a state, and that state needs to be
preserved if a server fails, and has to be made available to any
other server that takes it place. A database service such as a
MariaDB server is a typical stateful service
09/06/2014
© SkySQL Corporation Ab. Company Confidential.
Components of High Availability
❏ Monitoring and Management
Availability of the services needs to be monitored, to be able
to take action when there is a failure.
A failover can be manual or automatic, but it has to be
managed
❏ Failover / Load Balancing mechanism
Some mechanism to redirect traffic from the failed server or
Datacenter and to a working one
❏ Data redundancy
For stateful services, we need to make sure that data is
somehow made redundant
09/06/2014
© SkySQL Corporation Ab. Company Confidential.
Monitoring and Management
❏ There are many different solutions here, some
focused on specific services (in particular
database), some as part of a Load Balancing
software solution of an Appliance or a pure
software based solution such as LinuxHA,
HaProxy, MaxScale, Mha
09/06/2014
© SkySQL Corporation Ab. Company Confidential.
Failover mechanism
❏ There is a wide range of options here too, in
particular when it comes to Datacenter
failover, which can be more complicated
❏ Common mechanisms range from application
based failover and DNS failover to Load
Balancing and Network Failover
09/06/2014
© SkySQL Corporation Ab. Company Confidential.
Data Redundancy
❏ Providing Data Redundancy is complex, error
prone and takes a toll on performance
❏ It also has to be mentioned that a SAN does
not provide redundancy just because a disk
set can be failed over from one server to
another. A SAN might be a SPOF, but in some
cases that is a risk that some customers is
willing to take
09/06/2014
© SkySQL Corporation Ab. Company Confidential.
Data Redundancy with MariaDB
❏ MariaDB Internal Replication
❏ Assync
❏ Semi-sync
❏ Sync per table with spider
❏ MariaDB Galera Cluster
❏ Storage based redundancy (Active / Passive setups)
❏ DRBD (Distributed Replicated Block Device)
❏ SAN (Storage Area Network)
❏ VMWare replication
09/06/2014
© SkySQL Corporation Ab. Company Confidential.
HA using MariaDB Replication
❏ In many cases best solution
❏ Well known and easy to use technology
❏ The cluster is very loosely coupled, not all nodes are
aware of all the other nodes for example it’s self healing
solution, no sensibility to network latency, and
replication node speed (hardware variability)
❏ Offer the lowest master performance impact so far
❏ Multi node read scalability with best possible query
latency, network data distribution still slow vs in memory
scale up (photonic bus & memory is for 2020)
09/06/2014
© SkySQL Corporation Ab. Company Confidential.
HA using MariaDB Replication
❏ In many cases the best solution
❏ Logical replication no corruption propagated
❏ Various topologies using multi source , storage engine
switching, multi master , peer to peer
❏ Row vs Statement for strong network compression
❏ MariaDB fixing the gotcha
❏ Parallel replication , group commit, checksum, heartbeat
❏ Can be extended with per session consistency using
GTID_POS_WAIT
09/06/2014
© SkySQL Corporation Ab. Company Confidential.
HA MariaDB Replication GTID
SET GLOBAL GTID_SLAVE_POS = BINLOG_GTID_POS("master-bin.00024", 1600);
CHANGE MASTER TO master_host="10.2.3.4", master_use_gtid=slave_pos; START SLAVE;
CHANGE MASTER TO master_host="10.2.3.5";
© SkySQL Corporation Ab. Company Confidential.
HA using MariaDB Replication
❏ Replication gotcha
❏ Can lose data on master crash without semi-sync and
semi sync performance should be address in next release
❏ Adding a slave stay manual and complex (MyISAM)
❏ Failover is more complex, found the most up to date
slave, depends external product like MHA and scripting
to LB or HA solutions (maxscale can fix)
❏ Automatic Strong consistency (maxscale can fix)
❏ No map reduce queries (spider temporary table can fix)
09/06/2014
© SkySQL Corporation Ab. Company Confidential.
HA using MariaDB
❏ This a software-only solution
09/06/2014
MariaDB Server MariaDB Server MariaDB Server
Galera wsrep Library Galera wsrep Library Galera wsrep Library
Synchronous Replication
Load Balancer / Failover
Application / Application server
© SkySQL Corporation Ab. Company Confidential.
Installing MariaDB
❏ MariaDB Galera Cluster consists of separate MariaDB binary
that in turns talks to the Galera wsrep library
❏ Once set up, Galera is configured using the usual my.cnf file,
and is monitored using the SHOW GLOBAL STATUS
command
09/06/2014
© SkySQL Corporation Ab. Company Confidential.
HA using MariaDB
09/06/2014
❏ Scales reads
❏ Limited impact on concurrent writes, despite long
distance network latency
❏ Proper Cluster with easy failover, optimistic locking, split-
brain protection, no possible data lost on failover
❏ Synchronous replication with low overhead due to
optimistic locking , paxos queue, parallel event replication
❏ Transparent provisioning
❏ Galera best point
© SkySQL Corporation Ab. Company Confidential.
HA using MariaDB
09/06/2014
❏ InnoDB only solution
❏ Network architecture reliability
❏ Local Committed Read only (select for update)
❏ Deadlock error prone
❏ Galera dark side
For transactional scenarios it may still
need read write splitting !
© SkySQL Corporation Ab. Company Confidential.
Failover with MariaDB
❏ MariaDB Galera Cluster handles failed servers internally
provide a status, that tells about membership of the cluster
❏ MariaDB Galera Cluster also handles split-brain protection
and this requires at least 3 servers
❏ MariaDB Galera Cluster can also be configured without
split-brain protection, for example when failover is manual
or is handled in some other way
09/06/2014
© SkySQL Corporation Ab. Company Confidential.
Setting up MariaDB
❏ Necessary to allow for protection against split-brain
scenarios, but only using 2 database servers, a third server
can be set up with a Galera specific arbitration agent (grbd)
❏ Galera also can be used with it’s own simple Load Balancer,
(glb) , auto detect new nodes, although it is much more
common that other technologies are used, such as HA aware
Connectors or a Load Balancer, in this case use a backup
policy and no load balancing for write
❏ For advance setup without application control, auto
balancing reads and write to a single node we advise you to
try out our maxscale proxy
09/06/2014
© SkySQL Corporation Ab. Company Confidential.
Questions?
09/06/2014

More Related Content

What's hot

Webseminar: MariaDB Enterprise und MariaDB Enterprise Cluster
Webseminar: MariaDB Enterprise und MariaDB Enterprise ClusterWebseminar: MariaDB Enterprise und MariaDB Enterprise Cluster
Webseminar: MariaDB Enterprise und MariaDB Enterprise Cluster
MariaDB Corporation
 
Methods of Sharding MySQL
Methods of Sharding MySQLMethods of Sharding MySQL
Methods of Sharding MySQL
Laine Campbell
 
Mysql User Camp : 20-June-14 : Mysql Fabric
Mysql User Camp : 20-June-14 : Mysql FabricMysql User Camp : 20-June-14 : Mysql Fabric
Mysql User Camp : 20-June-14 : Mysql Fabric
Mysql User Camp
 

What's hot (20)

Tips to drive maria db cluster performance for nextcloud
Tips to drive maria db cluster performance for nextcloudTips to drive maria db cluster performance for nextcloud
Tips to drive maria db cluster performance for nextcloud
 
Running MariaDB in multiple data centers
Running MariaDB in multiple data centersRunning MariaDB in multiple data centers
Running MariaDB in multiple data centers
 
Webseminar: MariaDB Enterprise und MariaDB Enterprise Cluster
Webseminar: MariaDB Enterprise und MariaDB Enterprise ClusterWebseminar: MariaDB Enterprise und MariaDB Enterprise Cluster
Webseminar: MariaDB Enterprise und MariaDB Enterprise Cluster
 
MariaDB Galera Cluster - Simple, Transparent, Highly Available
MariaDB Galera Cluster - Simple, Transparent, Highly AvailableMariaDB Galera Cluster - Simple, Transparent, Highly Available
MariaDB Galera Cluster - Simple, Transparent, Highly Available
 
Webinar slides: Introduction to Database Proxies (for MySQL)
Webinar slides: Introduction to Database Proxies (for MySQL)Webinar slides: Introduction to Database Proxies (for MySQL)
Webinar slides: Introduction to Database Proxies (for MySQL)
 
MySQL Multi Master Replication
MySQL Multi Master ReplicationMySQL Multi Master Replication
MySQL Multi Master Replication
 
MySQL Options in OpenStack
MySQL Options in OpenStackMySQL Options in OpenStack
MySQL Options in OpenStack
 
Running Galera Cluster on Microsoft Azure
Running Galera Cluster on Microsoft AzureRunning Galera Cluster on Microsoft Azure
Running Galera Cluster on Microsoft Azure
 
MariaDB on Docker
MariaDB on DockerMariaDB on Docker
MariaDB on Docker
 
Methods of Sharding MySQL
Methods of Sharding MySQLMethods of Sharding MySQL
Methods of Sharding MySQL
 
Using and Benchmarking Galera in different architectures (PLUK 2012)
Using and Benchmarking Galera in different architectures (PLUK 2012)Using and Benchmarking Galera in different architectures (PLUK 2012)
Using and Benchmarking Galera in different architectures (PLUK 2012)
 
Galera Cluster 4 for MySQL 8 Release Webinar slides
Galera Cluster 4 for MySQL 8 Release Webinar slidesGalera Cluster 4 for MySQL 8 Release Webinar slides
Galera Cluster 4 for MySQL 8 Release Webinar slides
 
9 DevOps Tips for Going in Production with Galera Cluster for MySQL - Slides
9 DevOps Tips for Going in Production with Galera Cluster for MySQL - Slides9 DevOps Tips for Going in Production with Galera Cluster for MySQL - Slides
9 DevOps Tips for Going in Production with Galera Cluster for MySQL - Slides
 
Deploying MariaDB databases with containers at Nokia Networks
Deploying MariaDB databases with containers at Nokia NetworksDeploying MariaDB databases with containers at Nokia Networks
Deploying MariaDB databases with containers at Nokia Networks
 
MySQL InnoDB Cluster and NDB Cluster
MySQL InnoDB Cluster and NDB ClusterMySQL InnoDB Cluster and NDB Cluster
MySQL InnoDB Cluster and NDB Cluster
 
High Performance Drupal with MariaDB
High Performance Drupal with MariaDBHigh Performance Drupal with MariaDB
High Performance Drupal with MariaDB
 
Skalierbarkeit mit MariaDB und MaxScale - MariaDB Roadshow Summer 2014 Hambur...
Skalierbarkeit mit MariaDB und MaxScale - MariaDB Roadshow Summer 2014 Hambur...Skalierbarkeit mit MariaDB und MaxScale - MariaDB Roadshow Summer 2014 Hambur...
Skalierbarkeit mit MariaDB und MaxScale - MariaDB Roadshow Summer 2014 Hambur...
 
Galera Cluster 4 presentation at Percona Live Austin 2019
Galera Cluster 4 presentation at Percona Live Austin 2019 Galera Cluster 4 presentation at Percona Live Austin 2019
Galera Cluster 4 presentation at Percona Live Austin 2019
 
MariaDB High Availability
MariaDB High AvailabilityMariaDB High Availability
MariaDB High Availability
 
Mysql User Camp : 20-June-14 : Mysql Fabric
Mysql User Camp : 20-June-14 : Mysql FabricMysql User Camp : 20-June-14 : Mysql Fabric
Mysql User Camp : 20-June-14 : Mysql Fabric
 

Similar to High Availability with MariaDB Enterprise

Giga spaces value prop - afas - cloud practices
Giga spaces value prop - afas - cloud practicesGiga spaces value prop - afas - cloud practices
Giga spaces value prop - afas - cloud practices
Tricode (part of Dept)
 
Best Practices of HA and Replication of PostgreSQL in Virtualized Environments
Best Practices of HA and Replication of PostgreSQL in Virtualized EnvironmentsBest Practices of HA and Replication of PostgreSQL in Virtualized Environments
Best Practices of HA and Replication of PostgreSQL in Virtualized Environments
Jignesh Shah
 

Similar to High Availability with MariaDB Enterprise (20)

High Availability with MariaDB Enterprise
High Availability with MariaDB EnterpriseHigh Availability with MariaDB Enterprise
High Availability with MariaDB Enterprise
 
Hochverfügbarkeit mit MariaDB Enterprise - MariaDB Roadshow Summer 2014 Hambu...
Hochverfügbarkeit mit MariaDB Enterprise - MariaDB Roadshow Summer 2014 Hambu...Hochverfügbarkeit mit MariaDB Enterprise - MariaDB Roadshow Summer 2014 Hambu...
Hochverfügbarkeit mit MariaDB Enterprise - MariaDB Roadshow Summer 2014 Hambu...
 
MaxScale - The Pluggibale Router MariaDB Roadshow 2014 Paris
MaxScale - The Pluggibale Router MariaDB Roadshow 2014 ParisMaxScale - The Pluggibale Router MariaDB Roadshow 2014 Paris
MaxScale - The Pluggibale Router MariaDB Roadshow 2014 Paris
 
MaxScale - The Pluggable Router
MaxScale - The Pluggable RouterMaxScale - The Pluggable Router
MaxScale - The Pluggable Router
 
Using all of the high availability options in MariaDB
Using all of the high availability options in MariaDBUsing all of the high availability options in MariaDB
Using all of the high availability options in MariaDB
 
Top Ten Private Cloud Risks
Top Ten Private Cloud RisksTop Ten Private Cloud Risks
Top Ten Private Cloud Risks
 
MySQL High Availability & Disaster Recovery (DAT361) - AWS re:Invent 2018
MySQL High Availability & Disaster Recovery (DAT361) - AWS re:Invent 2018MySQL High Availability & Disaster Recovery (DAT361) - AWS re:Invent 2018
MySQL High Availability & Disaster Recovery (DAT361) - AWS re:Invent 2018
 
How to Extend Availability to the Application Layer Across the Hybrid Cloud -...
How to Extend Availability to the Application Layer Across the Hybrid Cloud -...How to Extend Availability to the Application Layer Across the Hybrid Cloud -...
How to Extend Availability to the Application Layer Across the Hybrid Cloud -...
 
MySQL High Availibility Solutions
MySQL High Availibility SolutionsMySQL High Availibility Solutions
MySQL High Availibility Solutions
 
MariaDB: Connect Storage Engine
MariaDB: Connect Storage EngineMariaDB: Connect Storage Engine
MariaDB: Connect Storage Engine
 
1 architecture & design
1   architecture & design1   architecture & design
1 architecture & design
 
Continuent webinar 02-19-2015
Continuent webinar 02-19-2015Continuent webinar 02-19-2015
Continuent webinar 02-19-2015
 
Giga spaces value prop - afas - cloud practices
Giga spaces value prop - afas - cloud practicesGiga spaces value prop - afas - cloud practices
Giga spaces value prop - afas - cloud practices
 
Best Practices of HA and Replication of PostgreSQL in Virtualized Environments
Best Practices of HA and Replication of PostgreSQL in Virtualized EnvironmentsBest Practices of HA and Replication of PostgreSQL in Virtualized Environments
Best Practices of HA and Replication of PostgreSQL in Virtualized Environments
 
NetBackup CloudCatalyst – efficient, cost-effective deduplication to the cloud
NetBackup CloudCatalyst – efficient, cost-effective deduplication to the cloudNetBackup CloudCatalyst – efficient, cost-effective deduplication to the cloud
NetBackup CloudCatalyst – efficient, cost-effective deduplication to the cloud
 
Hazelcast 3.6 Roadmap Preview
Hazelcast 3.6 Roadmap PreviewHazelcast 3.6 Roadmap Preview
Hazelcast 3.6 Roadmap Preview
 
Class 7.pptx
Class 7.pptxClass 7.pptx
Class 7.pptx
 
Openstack HA
Openstack HAOpenstack HA
Openstack HA
 
Building Data Streaming Platforms using OpenShift and Kafka
Building Data Streaming Platforms using OpenShift and KafkaBuilding Data Streaming Platforms using OpenShift and Kafka
Building Data Streaming Platforms using OpenShift and Kafka
 
Disaster Recovery pomocí Oracle Cloudu
Disaster Recovery pomocí Oracle ClouduDisaster Recovery pomocí Oracle Cloudu
Disaster Recovery pomocí Oracle Cloudu
 

More from MariaDB Corporation

More from MariaDB Corporation (19)

MaxScale - The Pluggable Router
MaxScale - The Pluggable RouterMaxScale - The Pluggable Router
MaxScale - The Pluggable Router
 
MariaDB und mehr - MariaDB Roadshow Summer 2014 Hamburg Berlin Frankfurt
MariaDB und mehr - MariaDB Roadshow Summer 2014 Hamburg Berlin FrankfurtMariaDB und mehr - MariaDB Roadshow Summer 2014 Hamburg Berlin Frankfurt
MariaDB und mehr - MariaDB Roadshow Summer 2014 Hamburg Berlin Frankfurt
 
Automatisierung & Verwaltung von Datenbank - Clustern mit Severalnines - Mari...
Automatisierung & Verwaltung von Datenbank - Clustern mit Severalnines - Mari...Automatisierung & Verwaltung von Datenbank - Clustern mit Severalnines - Mari...
Automatisierung & Verwaltung von Datenbank - Clustern mit Severalnines - Mari...
 
The New MariaDB Offering: MariaDB 10, MaxScale and More
The New MariaDB Offering: MariaDB 10, MaxScale and MoreThe New MariaDB Offering: MariaDB 10, MaxScale and More
The New MariaDB Offering: MariaDB 10, MaxScale and More
 
MariaDB Enterprise & MariaDB Enterprise Cluster - MariaDB Webinar July 2014 F...
MariaDB Enterprise & MariaDB Enterprise Cluster - MariaDB Webinar July 2014 F...MariaDB Enterprise & MariaDB Enterprise Cluster - MariaDB Webinar July 2014 F...
MariaDB Enterprise & MariaDB Enterprise Cluster - MariaDB Webinar July 2014 F...
 
MariaDB Enterprise & MariaDB Enterprise Cluster - MariaDB Webinar July 2014
MariaDB Enterprise & MariaDB Enterprise Cluster - MariaDB Webinar July 2014MariaDB Enterprise & MariaDB Enterprise Cluster - MariaDB Webinar July 2014
MariaDB Enterprise & MariaDB Enterprise Cluster - MariaDB Webinar July 2014
 
Galaxy Big Data with MariaDB
Galaxy Big Data with MariaDBGalaxy Big Data with MariaDB
Galaxy Big Data with MariaDB
 
Automatisation et Gestion de Cluster de Bases de Données MariaDB Roadshow
Automatisation et Gestion de Cluster de Bases de Données MariaDB RoadshowAutomatisation et Gestion de Cluster de Bases de Données MariaDB Roadshow
Automatisation et Gestion de Cluster de Bases de Données MariaDB Roadshow
 
Automation and Management of Database Clusters MariaDB Roadshow 2014
Automation and Management of Database Clusters MariaDB Roadshow 2014Automation and Management of Database Clusters MariaDB Roadshow 2014
Automation and Management of Database Clusters MariaDB Roadshow 2014
 
Automation and Management of Database Clusters
Automation and Management of Database ClustersAutomation and Management of Database Clusters
Automation and Management of Database Clusters
 
The New MariaDB Offering - MariaDB 10, MaxScale and more
The New MariaDB Offering - MariaDB 10, MaxScale and moreThe New MariaDB Offering - MariaDB 10, MaxScale and more
The New MariaDB Offering - MariaDB 10, MaxScale and more
 
MariaDB 10 and Beyond
MariaDB 10 and BeyondMariaDB 10 and Beyond
MariaDB 10 and Beyond
 
MaxScale - the pluggable router
MaxScale - the pluggable routerMaxScale - the pluggable router
MaxScale - the pluggable router
 
CCM Escape Case Study - SkySQL Paris Meetup 17.12.2013
CCM Escape Case Study - SkySQL Paris Meetup 17.12.2013CCM Escape Case Study - SkySQL Paris Meetup 17.12.2013
CCM Escape Case Study - SkySQL Paris Meetup 17.12.2013
 
Galera cluster - SkySQL Paris Meetup 17.12.2013
Galera cluster - SkySQL Paris Meetup 17.12.2013Galera cluster - SkySQL Paris Meetup 17.12.2013
Galera cluster - SkySQL Paris Meetup 17.12.2013
 
MariaDB 10.0 - SkySQL Paris Meetup
MariaDB 10.0 - SkySQL Paris MeetupMariaDB 10.0 - SkySQL Paris Meetup
MariaDB 10.0 - SkySQL Paris Meetup
 
High Availability with Galera Cluster - SkySQL Road Show 2013 in Berlin
High Availability with Galera Cluster - SkySQL Road Show 2013 in BerlinHigh Availability with Galera Cluster - SkySQL Road Show 2013 in Berlin
High Availability with Galera Cluster - SkySQL Road Show 2013 in Berlin
 
MySQL & MariaDB - Innovation happens here - London Roadshow 2013
MySQL & MariaDB - Innovation happens here - London Roadshow 2013MySQL & MariaDB - Innovation happens here - London Roadshow 2013
MySQL & MariaDB - Innovation happens here - London Roadshow 2013
 
1&1 MySQL Experience at SkySQL Roadshow
1&1 MySQL Experience at SkySQL Roadshow1&1 MySQL Experience at SkySQL Roadshow
1&1 MySQL Experience at SkySQL Roadshow
 

Recently uploaded

+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
?#DUbAI#??##{{(☎️+971_581248768%)**%*]'#abortion pills for sale in dubai@
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
Joaquim Jorge
 

Recently uploaded (20)

Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
Developing An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of BrazilDeveloping An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of Brazil
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
Tech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdfTech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdf
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
HTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation StrategiesHTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation Strategies
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
 

High Availability with MariaDB Enterprise

  • 1. © SkySQL Corporation Ab. Company Confidential.09/06/2014
  • 2. © SkySQL Corporation Ab. Company Confidential. High Availability with MariaDB Enterprise Stephane Varoqui Professional Services, SkySQL * *09/06/2014
  • 3. © SkySQL Corporation Ab. Company Confidential. Agenda ❏ Introduction to High Availability ❏ Different services that need HA ❏ Different components of High Availability ❏ Different MariaDB HA Solutions ❏ HA using MariaDB Replication ❏ HA using MariaDB Galera Cluster 09/06/2014
  • 4. © SkySQL Corporation Ab. Company Confidential. Introduction to High Availability High availability is a system design protocol and associated implementation that ensures a certain degree of operational continuity during a given measurement period 09/06/2014
  • 5. © SkySQL Corporation Ab. Company Confidential. Introduction to High Availability 09/06/2014 ❏ High Availability != Long Uptime “up” might still not be accessible “down” just once, but for a long time ❏ High Availability rather means Long Mean Time Between Failures (MTBF) Short Mean Time To Recover (MTTR)
  • 6. © SkySQL Corporation Ab. Company Confidential. Introduction to High Availability ❏ Availability level is measured as the ratio of time the system is available over a year, expressed as a percentage ❏ 99.9% availability means that the system is available at least 8751 of 8760 hours in a year, or that it is unavailable at the most 9 hours per year ❏ 99.999% availability means that the system is available at least 525595 or 525600 minutes in a year, or that it is unavailable at the most 5 minutes per year 09/06/2014
  • 7. © SkySQL Corporation Ab. Company Confidential. Maintaining High Availability ❏ There are two common situations that we try to protect ourselves from using an HA solution ❏ Datacenter failure – A whole datacenter becomes unavailable for some reason, like power failure, network failure, a virus or similar situations ❏ Server failure – An individual server fails because of a hardware failure or something similar 09/06/2014
  • 8. © SkySQL Corporation Ab. Company Confidential. Layers in HA Solution ❏ All services that make up the application stack needs HA for the system to achieve HA Web servers Application servers Applications Database servers Storage Network 09/06/2014 TCO for Unbreakable Hardware
  • 9. © SkySQL Corporation Ab. Company Confidential. Services in an HA Solution ❏ Of the different types of services, there are two types Stateless services These servers has no state beyond the current operation. If such a server fails, another server of the same type can replace it without having to transfer any set of data. Webservers and application servers are typical stateless services Stateful services These services maintains a state, and that state needs to be preserved if a server fails, and has to be made available to any other server that takes it place. A database service such as a MariaDB server is a typical stateful service 09/06/2014
  • 10. © SkySQL Corporation Ab. Company Confidential. Components of High Availability ❏ Monitoring and Management Availability of the services needs to be monitored, to be able to take action when there is a failure. A failover can be manual or automatic, but it has to be managed ❏ Failover / Load Balancing mechanism Some mechanism to redirect traffic from the failed server or Datacenter and to a working one ❏ Data redundancy For stateful services, we need to make sure that data is somehow made redundant 09/06/2014
  • 11. © SkySQL Corporation Ab. Company Confidential. Monitoring and Management ❏ There are many different solutions here, some focused on specific services (in particular database), some as part of a Load Balancing software solution of an Appliance or a pure software based solution such as LinuxHA, HaProxy, MaxScale, Mha 09/06/2014
  • 12. © SkySQL Corporation Ab. Company Confidential. Failover mechanism ❏ There is a wide range of options here too, in particular when it comes to Datacenter failover, which can be more complicated ❏ Common mechanisms range from application based failover and DNS failover to Load Balancing and Network Failover 09/06/2014
  • 13. © SkySQL Corporation Ab. Company Confidential. Data Redundancy ❏ Providing Data Redundancy is complex, error prone and takes a toll on performance ❏ It also has to be mentioned that a SAN does not provide redundancy just because a disk set can be failed over from one server to another. A SAN might be a SPOF, but in some cases that is a risk that some customers is willing to take 09/06/2014
  • 14. © SkySQL Corporation Ab. Company Confidential. Data Redundancy with MariaDB ❏ MariaDB Internal Replication ❏ Assync ❏ Semi-sync ❏ Sync per table with spider ❏ MariaDB Galera Cluster ❏ Storage based redundancy (Active / Passive setups) ❏ DRBD (Distributed Replicated Block Device) ❏ SAN (Storage Area Network) ❏ VMWare replication 09/06/2014
  • 15. © SkySQL Corporation Ab. Company Confidential. HA using MariaDB Replication ❏ In many cases best solution ❏ Well known and easy to use technology ❏ The cluster is very loosely coupled, not all nodes are aware of all the other nodes for example it’s self healing solution, no sensibility to network latency, and replication node speed (hardware variability) ❏ Offer the lowest master performance impact so far ❏ Multi node read scalability with best possible query latency, network data distribution still slow vs in memory scale up (photonic bus & memory is for 2020) 09/06/2014
  • 16. © SkySQL Corporation Ab. Company Confidential. HA using MariaDB Replication ❏ In many cases the best solution ❏ Logical replication no corruption propagated ❏ Various topologies using multi source , storage engine switching, multi master , peer to peer ❏ Row vs Statement for strong network compression ❏ MariaDB fixing the gotcha ❏ Parallel replication , group commit, checksum, heartbeat ❏ Can be extended with per session consistency using GTID_POS_WAIT 09/06/2014
  • 17. © SkySQL Corporation Ab. Company Confidential. HA MariaDB Replication GTID SET GLOBAL GTID_SLAVE_POS = BINLOG_GTID_POS("master-bin.00024", 1600); CHANGE MASTER TO master_host="10.2.3.4", master_use_gtid=slave_pos; START SLAVE; CHANGE MASTER TO master_host="10.2.3.5";
  • 18. © SkySQL Corporation Ab. Company Confidential. HA using MariaDB Replication ❏ Replication gotcha ❏ Can lose data on master crash without semi-sync and semi sync performance should be address in next release ❏ Adding a slave stay manual and complex (MyISAM) ❏ Failover is more complex, found the most up to date slave, depends external product like MHA and scripting to LB or HA solutions (maxscale can fix) ❏ Automatic Strong consistency (maxscale can fix) ❏ No map reduce queries (spider temporary table can fix) 09/06/2014
  • 19. © SkySQL Corporation Ab. Company Confidential. HA using MariaDB ❏ This a software-only solution 09/06/2014 MariaDB Server MariaDB Server MariaDB Server Galera wsrep Library Galera wsrep Library Galera wsrep Library Synchronous Replication Load Balancer / Failover Application / Application server
  • 20. © SkySQL Corporation Ab. Company Confidential. Installing MariaDB ❏ MariaDB Galera Cluster consists of separate MariaDB binary that in turns talks to the Galera wsrep library ❏ Once set up, Galera is configured using the usual my.cnf file, and is monitored using the SHOW GLOBAL STATUS command 09/06/2014
  • 21. © SkySQL Corporation Ab. Company Confidential. HA using MariaDB 09/06/2014 ❏ Scales reads ❏ Limited impact on concurrent writes, despite long distance network latency ❏ Proper Cluster with easy failover, optimistic locking, split- brain protection, no possible data lost on failover ❏ Synchronous replication with low overhead due to optimistic locking , paxos queue, parallel event replication ❏ Transparent provisioning ❏ Galera best point
  • 22. © SkySQL Corporation Ab. Company Confidential. HA using MariaDB 09/06/2014 ❏ InnoDB only solution ❏ Network architecture reliability ❏ Local Committed Read only (select for update) ❏ Deadlock error prone ❏ Galera dark side For transactional scenarios it may still need read write splitting !
  • 23. © SkySQL Corporation Ab. Company Confidential. Failover with MariaDB ❏ MariaDB Galera Cluster handles failed servers internally provide a status, that tells about membership of the cluster ❏ MariaDB Galera Cluster also handles split-brain protection and this requires at least 3 servers ❏ MariaDB Galera Cluster can also be configured without split-brain protection, for example when failover is manual or is handled in some other way 09/06/2014
  • 24. © SkySQL Corporation Ab. Company Confidential. Setting up MariaDB ❏ Necessary to allow for protection against split-brain scenarios, but only using 2 database servers, a third server can be set up with a Galera specific arbitration agent (grbd) ❏ Galera also can be used with it’s own simple Load Balancer, (glb) , auto detect new nodes, although it is much more common that other technologies are used, such as HA aware Connectors or a Load Balancer, in this case use a backup policy and no load balancing for write ❏ For advance setup without application control, auto balancing reads and write to a single node we advise you to try out our maxscale proxy 09/06/2014
  • 25. © SkySQL Corporation Ab. Company Confidential. Questions? 09/06/2014