SlideShare a Scribd company logo
1 of 41
Download to read offline
MySQL High Availability Solutions


     Lenz Grimmer <lenz@grimmer.com>
                  <
     http://lenzg.net/ | Twitter: @lenzgr
2011-01-26 | San Francisco MySQL Meetup | USA
$ whoami




1998              2002



2008              2010
Agenda
●   High Availability: Concepts &
    Considerations
●   MySQL Replication
●   DRBD / Pacemaker
●   MySQL Cluster
●   Other HA tools/applications
Single MySQL Server

            MySQL Client



   SQL (SELECT, INSERT,
      UPDATE, DELETE)

   MySQL Storage Engines
(InnoDB, MyISAM, PBXT...)



             Disk Storage
(XFS, ReiserFS, JFS, ext3...)
Why HA?
●   Something can and will fail
●   Service Maintenance
●   Downtime is expensive
●   Adding HA to an existing system is complex
Elimination of the SPOF
●   Identify what will fail eventually
     ●   Hard disks
     ●   Fans
●   Consider what might fail
     ●   Application crashes
     ●   OOM-Situations, Kernel-Panics
     ●   Network connections, Cables
     ●   Power supply
What is HA Clustering?
●   Redundancy
●   One system or service goes down → others
    take over
●   IP address takeover, service takeover
●   Ensuring data availability & integrity
●   Not designed for high-performance
High Availability Levels
Rules of High Availability
●   Prepare for failure
●   Aim to ensure that no important data is
    lost
●   Keep it simple, stupid (KISS)
●   Complexity is the enemy of reliability
●   Automate it
●   Test your setup frequently!
HA Components
●   Heartbeat
     ●   Checks that services that are monitored, are alive.
     ●   Can check individual servers, software services,
         networking etc.
●   HA Monitor
     ●   Configuration of the services
     ●   Ensures proper shutdown and startup
     ●   Allows manual control
●   Shared storage / Replication
Split-Brain
●   Communications failures can lead to
    separated partitions of the cluster
●   If those partitions each try and take control
    of the cluster, then it's called a split-brain
    condition
●   If this happens, then bad things will happen
●   Use Fencing or Moderation/Arbitration to
    avoid it
Redundancy Using MySQL Replication




           MySQL Replication
MySQL Replication
●   Unidirectional
●   Statement- or row-based (MySQL 5.1)
●   Built into MySQL
●   Easy to use and set up
●   One Master, many Slaves
●   Asynchronous – Slaves can lag behind
●   New in MySQL 5.5: Semisync Replication
MySQL Replication (2)
●   Master maintains Binary logs & index
●   Replication on Slave is single-threaded
    http://forge.mysql.com/wiki/ReplicationFeatures/ParallelSlave
●   No automated fail-over
●   No heartbeat, no monitoring
●   New in 5.5: replication heartbeat
MySQL Replication - Overview

        Read & Write


            Web/App
             Server
                                                                       Write

                                                 Relay
                                                  Log



                  mysqld                                                SQL
                                                       I/O
                                                                       Threa
                                                     Thread
                                                                         d
                       Index &
                       Binlogs

Data

                                 Replication                  Binlog           Data

                                               mysqld

       MySQL Master                                       MySQL Slave
Statement-based Replication
●   Pro
     ✔   Proven (around since MySQL 3.23)
     ✔   Smaller log files
     ✔   Auditing of actual SQL statements
     ✔   No primary key requirement for replicated tables
●   Con
     ✗   Non-deterministic functions and UDFs
     ✗   LOAD_FILE(), UUID(), CURRENT_USER(),
         FOUND_ROWS()
         (but RAND() and NOW() work)
Row-based Replication
●   Pro
     ✔   All changes can be replicated
     ✔   Similar technology used by other RDBMSes
     ✔   Fewer locks required for some INSERT, UPDATE or
         DELETE statements
●   Con
     ✗   More data to be logged
     ✗   Log file size increases (backup/restore implications)
     ✗   Replicated tables require explicit primary keys
     ✗   Possible different result sets on bulk INSERTs
Replication Topologies

Master > Slave                          Master > Slaves




Master > Slave > Slaves            Masters > Slave (Multi-Source)




                                         Ring (Multi-Master)
Master < > Master (Multi-Master)
Master-Master Replication
●   Two nodes are both master and slave to
    each other
●   Useful for easier failover
●   Not suitable for (write) load-balancing
●   Don't write to both masters
    simultaneously!
●   Use Sharding or Partitioning instead
    (e.g. MySQL Proxy)
MySQL Replication as a HA Solution
●   What happens if the Master fails?
●   What happens if the Slave fails?
●   This doesn’t sound like High Availability!
●   Yes!
●   Replication is only part of a HA
    configuration
Pacemaker (Linux-HA)
●   Supports 2 or more Nodes (v2)
●   Resource monitoring (Apps and HW)
●   Active fencing mechanism (STONITH)
●   Node failure detection in seconds
●   Supports many applications (incl. MySQL)
●   http://clusterlabs.org/
●   http://www.clusterlabs.org/wiki/Load_Balanced_MySQL_Replicated_Cluster
●   http://www.clusterlabs.org/wiki/DRBD_MySQL_HowTo
Replication & HA
●   Combined with Pacemaker
●   Virtual IP takeover
●   Slave gets promoted to Master
●   Side benefits: load balancing & backup
●   Can be tricky to fail back
●   No automatic conflict resolution
●   Proper failover needs to be scripted
Redundancy With Disk Replication




           Disk Replication
DRBD
●   Distributed Replicated Block Device
●   “RAID-1 over network”
●   Synchronous/asynchronous block replication
●   Automatic resynchronisation
●   Application-agnostic
●   Can mask local I/O-Errors
●   Active/passive configuration
●   Dual-primary mode (requires cluster file sytem
    like GFS or OCFS2)
●   http://drbd.org/
DRBD in Detail
●   DRBD replicates data blocks between to
    block devices
●   DRBD can be combined with Linux-HA and
    other HA solutions
●   MySQL runs normally                    Applications


    on primary node
●   MySQL is not active on   Active Node   Virtual IP     Passive Node


    the secondary node
●   DRBD is Linux only                            DRBD
Redundancy Using Shared Storage
Replication vs. SAN
●   Data Consistency / Integrity
●   Synchronous vs. asynchronous
●   SAN can become the SPOF
●   Cold caches
●   “Split brain”-Situations
●   SAN/NAS I/O Overhead
Redundancy with MySQL Cluster
MySQL Cluster
●   “Shared-nothing”-Architecture
●   Automatic partitioning
●   Distributed fragments
●   Synchronous replication
●   Fast, automatic fail-over of data nodes
●   Automatic resynchronisation
●   Transparent to MySQL applicationen
●   Supports transactions
●   http://mysql.com/products/database/cluster/
MySQL Cluster
●   In-memory indexes
●   Not suitable for all query patterns
    (cross-table JOINs, range scans)
●   No support for foreign keys
●   Not suitable for long running transactions
●   Network latency crucial
●   Can be combined with MySQL replication
    (RBR)
MySQL Cluster & Replikation
●   MySQL Cluster
     ●   Easy failover from one MySQL node to another
     ●   Scaling write load using multiple SQL nodes
●   Asynchronous replication from Cluster to
    regular MySQL slaves
●   Slaves take read load (InnoDB/MyISAM)
●   Quick setup of new slaves (Cluster Online
    Backup)
●   Easy failover and fast recovery
http://johanandersson.blogspot.com/2009/05/ha-mysql-write-scaling-using-cluster-to.html
Galera Replication
●   Patch for InnoDB plus external library
●   Synchronous replication
●   Single- or multi-master
●   Multicast-Replication
●   HA plus load sharing possible
●   Certifikate-based replikation
    (instead of 2PC)
●   http://codership.com/products/mysql_galera
MMM
●   MySQL Master-Master Replication
    Manager
●   Perl-Script for monitoring, failover and
    management
●   Master-master replication configuration
    (one active writable master)
●   Failover by moving virtual IP-Address
●   Also supports read balancing
●   http://mysql-mmm.org/
Continuent Tungsten Replicator
●   Database-external solution
●   Asynchronous, Master-Slave, Fan-out &
    Fan-in
●   Java
●   Log-based
●   Events are stored in the Transaction History
    Log (THL)
●   Modular architekture (Pipelines, Stages)
●   http://continuent.com/community/tungsten-replicator
Red Hat Cluster Suite
●   HA and load balancing
●   Supports up to 16 nodes
●   Shared storage
●   Monitors services, file systems and network
    status
●   Fencing (STONITH) or distributed lock
    manager
●   Configuration synchronization
●   http://www.redhat.com/cluster_suite/
Solaris Cluster / OpenHA Cluster
●   Provides failover and scalability services
●   Solaris / OpenSolaris (Project Colorado)
●   Kernel-level components plus userland
●   Agents monitor applications
●   Geo Edition to provide Disaster Recovery
    using Replication
●   Open Source since June 2007
●   http://hub.opensolaris.org/bin/view/Community+Group+ha-clusters/WebHome
●   http://hub.opensolaris.org/bin/view/Project+ha-mysql/WebHome
Flipper
●   Perl Script managing pairs of MySQL
    servers replicating to each other.
●   Automatic switchover, triggered manually
●   Enables one half of the pair to be taken
    offline for maintenance work while other
    half carries on
●   Moves IP addresses based on a role ("read-
    only", "writable")
●   http://provenscaling.com/software/flipper/
Q&A




Questions, Comments?
Thank you!




Lenz Grimmer <lenz@grimmer.com>
         Twitter: @lenzgr
         http://lenzg.net/

More Related Content

What's hot

M|18 Under the Hood: Galera Cluster
M|18 Under the Hood: Galera ClusterM|18 Under the Hood: Galera Cluster
M|18 Under the Hood: Galera ClusterMariaDB plc
 
M|18 Why Abstract Away the Underlying Database Infrastructure
M|18 Why Abstract Away the Underlying Database InfrastructureM|18 Why Abstract Away the Underlying Database Infrastructure
M|18 Why Abstract Away the Underlying Database InfrastructureMariaDB plc
 
Demystifying MySQL Replication Crash Safety
Demystifying MySQL Replication Crash SafetyDemystifying MySQL Replication Crash Safety
Demystifying MySQL Replication Crash SafetyJean-François Gagné
 
MySQL Parallel Replication by Booking.com
MySQL Parallel Replication by Booking.comMySQL Parallel Replication by Booking.com
MySQL Parallel Replication by Booking.comJean-François Gagné
 
"Advanced MySQL 5 Tuning" by Michael Monty Widenius @ eLiberatica 2007
"Advanced MySQL 5 Tuning" by Michael Monty Widenius @ eLiberatica 2007"Advanced MySQL 5 Tuning" by Michael Monty Widenius @ eLiberatica 2007
"Advanced MySQL 5 Tuning" by Michael Monty Widenius @ eLiberatica 2007eLiberatica
 
MyRocks in MariaDB: why and how
MyRocks in MariaDB: why and howMyRocks in MariaDB: why and how
MyRocks in MariaDB: why and howSergey Petrunya
 
Discard inport exchange table & tablespace
Discard inport exchange table & tablespaceDiscard inport exchange table & tablespace
Discard inport exchange table & tablespaceMarco Tusa
 
MySQL developing Store Procedure
MySQL developing Store ProcedureMySQL developing Store Procedure
MySQL developing Store ProcedureMarco Tusa
 
Demystifying MySQL Replication Crash Safety
Demystifying MySQL Replication Crash SafetyDemystifying MySQL Replication Crash Safety
Demystifying MySQL Replication Crash SafetyJean-François Gagné
 
What's New in MySQL 5.7
What's New in MySQL 5.7What's New in MySQL 5.7
What's New in MySQL 5.7Olivier DASINI
 
Yahoo: Experiences with MySQL GTID and Multi Threaded Replication
Yahoo: Experiences with MySQL GTID and Multi Threaded ReplicationYahoo: Experiences with MySQL GTID and Multi Threaded Replication
Yahoo: Experiences with MySQL GTID and Multi Threaded ReplicationYashada Jadhav
 
M|18 Writing Stored Procedures in the Real World
M|18 Writing Stored Procedures in the Real WorldM|18 Writing Stored Procedures in the Real World
M|18 Writing Stored Procedures in the Real WorldMariaDB plc
 
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 FrankfurtMariaDB Corporation
 
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 ClusterMariaDB Corporation
 
Ansible is Our Wishbone(Automate DBA Tasks With Ansible)
Ansible is Our Wishbone(Automate DBA Tasks With Ansible)Ansible is Our Wishbone(Automate DBA Tasks With Ansible)
Ansible is Our Wishbone(Automate DBA Tasks With Ansible)M Malai
 
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 MoreMariaDB Corporation
 
Online MySQL Backups with Percona XtraBackup
Online MySQL Backups with Percona XtraBackupOnline MySQL Backups with Percona XtraBackup
Online MySQL Backups with Percona XtraBackupKenny Gryp
 
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 2014MariaDB Corporation
 
UKOUG 2011: MySQL Architectures for Oracle DBA's
UKOUG 2011: MySQL Architectures for Oracle DBA'sUKOUG 2011: MySQL Architectures for Oracle DBA's
UKOUG 2011: MySQL Architectures for Oracle DBA'sFromDual GmbH
 

What's hot (20)

M|18 Under the Hood: Galera Cluster
M|18 Under the Hood: Galera ClusterM|18 Under the Hood: Galera Cluster
M|18 Under the Hood: Galera Cluster
 
M|18 Why Abstract Away the Underlying Database Infrastructure
M|18 Why Abstract Away the Underlying Database InfrastructureM|18 Why Abstract Away the Underlying Database Infrastructure
M|18 Why Abstract Away the Underlying Database Infrastructure
 
Demystifying MySQL Replication Crash Safety
Demystifying MySQL Replication Crash SafetyDemystifying MySQL Replication Crash Safety
Demystifying MySQL Replication Crash Safety
 
MySQL Parallel Replication by Booking.com
MySQL Parallel Replication by Booking.comMySQL Parallel Replication by Booking.com
MySQL Parallel Replication by Booking.com
 
"Advanced MySQL 5 Tuning" by Michael Monty Widenius @ eLiberatica 2007
"Advanced MySQL 5 Tuning" by Michael Monty Widenius @ eLiberatica 2007"Advanced MySQL 5 Tuning" by Michael Monty Widenius @ eLiberatica 2007
"Advanced MySQL 5 Tuning" by Michael Monty Widenius @ eLiberatica 2007
 
MyRocks in MariaDB: why and how
MyRocks in MariaDB: why and howMyRocks in MariaDB: why and how
MyRocks in MariaDB: why and how
 
Discard inport exchange table & tablespace
Discard inport exchange table & tablespaceDiscard inport exchange table & tablespace
Discard inport exchange table & tablespace
 
MySQL developing Store Procedure
MySQL developing Store ProcedureMySQL developing Store Procedure
MySQL developing Store Procedure
 
Demystifying MySQL Replication Crash Safety
Demystifying MySQL Replication Crash SafetyDemystifying MySQL Replication Crash Safety
Demystifying MySQL Replication Crash Safety
 
What's New in MySQL 5.7
What's New in MySQL 5.7What's New in MySQL 5.7
What's New in MySQL 5.7
 
Yahoo: Experiences with MySQL GTID and Multi Threaded Replication
Yahoo: Experiences with MySQL GTID and Multi Threaded ReplicationYahoo: Experiences with MySQL GTID and Multi Threaded Replication
Yahoo: Experiences with MySQL GTID and Multi Threaded Replication
 
M|18 Writing Stored Procedures in the Real World
M|18 Writing Stored Procedures in the Real WorldM|18 Writing Stored Procedures in the Real World
M|18 Writing Stored Procedures in the Real World
 
MySQL highav Availability
MySQL highav AvailabilityMySQL highav Availability
MySQL highav Availability
 
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
 
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
 
Ansible is Our Wishbone(Automate DBA Tasks With Ansible)
Ansible is Our Wishbone(Automate DBA Tasks With Ansible)Ansible is Our Wishbone(Automate DBA Tasks With Ansible)
Ansible is Our Wishbone(Automate DBA Tasks With Ansible)
 
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
 
Online MySQL Backups with Percona XtraBackup
Online MySQL Backups with Percona XtraBackupOnline MySQL Backups with Percona XtraBackup
Online MySQL Backups with Percona XtraBackup
 
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
 
UKOUG 2011: MySQL Architectures for Oracle DBA's
UKOUG 2011: MySQL Architectures for Oracle DBA'sUKOUG 2011: MySQL Architectures for Oracle DBA's
UKOUG 2011: MySQL Architectures for Oracle DBA's
 

Viewers also liked

Kovalenko a
Kovalenko aKovalenko a
Kovalenko agarasym
 
Triển lãm "Tôi Mơ...Tôi Bay"-2012
Triển lãm "Tôi Mơ...Tôi Bay"-2012Triển lãm "Tôi Mơ...Tôi Bay"-2012
Triển lãm "Tôi Mơ...Tôi Bay"-2012NguyenHoang92002
 
L'archivage du Web, présentation college de france
L'archivage du Web, présentation college de franceL'archivage du Web, présentation college de france
L'archivage du Web, présentation college de franceJulien Masanès
 
A place in_my_heart
A place in_my_heartA place in_my_heart
A place in_my_heartnguyensnowy
 
Spring2012 week14 pt3-1 13-59-57
Spring2012 week14 pt3-1 13-59-57Spring2012 week14 pt3-1 13-59-57
Spring2012 week14 pt3-1 13-59-57educw200
 
TWSS House Renaming Competition
TWSS House Renaming CompetitionTWSS House Renaming Competition
TWSS House Renaming CompetitionYuliana Tjioe
 
DRAFT MuseSocial Pres
DRAFT MuseSocial PresDRAFT MuseSocial Pres
DRAFT MuseSocial PresErin Blasco
 
La pesca
La pescaLa pesca
La pescaalanola
 
Developments in making tourism a responsible industry stephan farrant wtfl 2011
Developments in making tourism a responsible industry stephan farrant wtfl 2011Developments in making tourism a responsible industry stephan farrant wtfl 2011
Developments in making tourism a responsible industry stephan farrant wtfl 2011World Tourism Forum Lucerne
 
OS Kralj Petar I- Niš
OS Kralj Petar I- NišOS Kralj Petar I- Niš
OS Kralj Petar I- Ništio_marina
 
Chakryan v
Chakryan vChakryan v
Chakryan vgarasym
 
Iran National Copper Corporation
Iran National Copper CorporationIran National Copper Corporation
Iran National Copper CorporationReza Motaghedi
 
Поисковая оптимизация как инструмент привлечения целевой аудитории на сайт ко...
Поисковая оптимизация как инструмент привлечения целевой аудитории на сайт ко...Поисковая оптимизация как инструмент привлечения целевой аудитории на сайт ко...
Поисковая оптимизация как инструмент привлечения целевой аудитории на сайт ко...Promodo
 

Viewers also liked (20)

Kovalenko a
Kovalenko aKovalenko a
Kovalenko a
 
Moto armonico
Moto armonicoMoto armonico
Moto armonico
 
Triển lãm "Tôi Mơ...Tôi Bay"-2012
Triển lãm "Tôi Mơ...Tôi Bay"-2012Triển lãm "Tôi Mơ...Tôi Bay"-2012
Triển lãm "Tôi Mơ...Tôi Bay"-2012
 
06
0606
06
 
Happy message
Happy messageHappy message
Happy message
 
L'archivage du Web, présentation college de france
L'archivage du Web, présentation college de franceL'archivage du Web, présentation college de france
L'archivage du Web, présentation college de france
 
Slimmer werken met een Social Intranet
Slimmer werken met een Social IntranetSlimmer werken met een Social Intranet
Slimmer werken met een Social Intranet
 
A place in_my_heart
A place in_my_heartA place in_my_heart
A place in_my_heart
 
Spring2012 week14 pt3-1 13-59-57
Spring2012 week14 pt3-1 13-59-57Spring2012 week14 pt3-1 13-59-57
Spring2012 week14 pt3-1 13-59-57
 
TWSS House Renaming Competition
TWSS House Renaming CompetitionTWSS House Renaming Competition
TWSS House Renaming Competition
 
Zatik annax
Zatik annaxZatik annax
Zatik annax
 
DRAFT MuseSocial Pres
DRAFT MuseSocial PresDRAFT MuseSocial Pres
DRAFT MuseSocial Pres
 
La pesca
La pescaLa pesca
La pesca
 
Developments in making tourism a responsible industry stephan farrant wtfl 2011
Developments in making tourism a responsible industry stephan farrant wtfl 2011Developments in making tourism a responsible industry stephan farrant wtfl 2011
Developments in making tourism a responsible industry stephan farrant wtfl 2011
 
OS Kralj Petar I- Niš
OS Kralj Petar I- NišOS Kralj Petar I- Niš
OS Kralj Petar I- Niš
 
Evaluation 3
Evaluation 3Evaluation 3
Evaluation 3
 
Chakryan v
Chakryan vChakryan v
Chakryan v
 
Iran National Copper Corporation
Iran National Copper CorporationIran National Copper Corporation
Iran National Copper Corporation
 
Vv28 mar 330
Vv28 mar 330Vv28 mar 330
Vv28 mar 330
 
Поисковая оптимизация как инструмент привлечения целевой аудитории на сайт ко...
Поисковая оптимизация как инструмент привлечения целевой аудитории на сайт ко...Поисковая оптимизация как инструмент привлечения целевой аудитории на сайт ко...
Поисковая оптимизация как инструмент привлечения целевой аудитории на сайт ко...
 

Similar to Mysqlhacodebits20091203 1260184765-phpapp02

Drupal Con My Sql Ha 2008 08 29
Drupal Con My Sql Ha 2008 08 29Drupal Con My Sql Ha 2008 08 29
Drupal Con My Sql Ha 2008 08 29liufabin 66688
 
Buytaert kris my_sql-pacemaker
Buytaert kris my_sql-pacemakerBuytaert kris my_sql-pacemaker
Buytaert kris my_sql-pacemakerkuchinskaya
 
Ukoug 2011 mysql_arch_for_orcl_dba
Ukoug 2011 mysql_arch_for_orcl_dbaUkoug 2011 mysql_arch_for_orcl_dba
Ukoug 2011 mysql_arch_for_orcl_dbaorablue11
 
MySQL for Oracle DBAs
MySQL for Oracle DBAsMySQL for Oracle DBAs
MySQL for Oracle DBAsFromDual GmbH
 
UKOUG 2011: Practical MySQL Tuning
UKOUG 2011: Practical MySQL TuningUKOUG 2011: Practical MySQL Tuning
UKOUG 2011: Practical MySQL TuningFromDual GmbH
 
MySQL always-up with Galera Cluster
MySQL always-up with Galera ClusterMySQL always-up with Galera Cluster
MySQL always-up with Galera ClusterFromDual GmbH
 
Collaborate 2012 - Administering MySQL for Oracle DBAs
Collaborate 2012 - Administering MySQL for Oracle DBAsCollaborate 2012 - Administering MySQL for Oracle DBAs
Collaborate 2012 - Administering MySQL for Oracle DBAsNelson Calero
 
The Peoper Care and Feeding of a MySQL Server for Busy Linux Admin
The Peoper Care and Feeding of a MySQL Server for Busy Linux AdminThe Peoper Care and Feeding of a MySQL Server for Busy Linux Admin
The Peoper Care and Feeding of a MySQL Server for Busy Linux AdminDave Stokes
 
When is MyRocks good?
When is MyRocks good? When is MyRocks good?
When is MyRocks good? Alkin Tezuysal
 
MySQL Webinar 2/4 Performance tuning, hardware, optimisation
MySQL Webinar 2/4 Performance tuning, hardware, optimisationMySQL Webinar 2/4 Performance tuning, hardware, optimisation
MySQL Webinar 2/4 Performance tuning, hardware, optimisationMark Swarbrick
 
Open stack HA - Theory to Reality
Open stack HA -  Theory to RealityOpen stack HA -  Theory to Reality
Open stack HA - Theory to RealitySriram Subramanian
 
Proper Care and Feeding of a MySQL Database for Busy Linux Administrators
Proper Care and Feeding of a MySQL Database for Busy Linux AdministratorsProper Care and Feeding of a MySQL Database for Busy Linux Administrators
Proper Care and Feeding of a MySQL Database for Busy Linux AdministratorsDave Stokes
 
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 AvailableMariaDB Corporation
 
Linuxfest Northwest Proper Care and Feeding Of a MySQL for Busy Linux Admins
Linuxfest Northwest Proper Care and Feeding Of a MySQL for Busy Linux AdminsLinuxfest Northwest Proper Care and Feeding Of a MySQL for Busy Linux Admins
Linuxfest Northwest Proper Care and Feeding Of a MySQL for Busy Linux AdminsDave Stokes
 
MySQL InnoDB Cluster - New Features in 8.0 Releases - Best Practices
MySQL InnoDB Cluster - New Features in 8.0 Releases - Best PracticesMySQL InnoDB Cluster - New Features in 8.0 Releases - Best Practices
MySQL InnoDB Cluster - New Features in 8.0 Releases - Best PracticesKenny Gryp
 
The Proper Care and Feeding of a MySQL Database for Busy Linux Admins -- SCaL...
The Proper Care and Feeding of a MySQL Database for Busy Linux Admins -- SCaL...The Proper Care and Feeding of a MySQL Database for Busy Linux Admins -- SCaL...
The Proper Care and Feeding of a MySQL Database for Busy Linux Admins -- SCaL...Dave Stokes
 
High-availability with Galera Cluster for MySQL
High-availability with Galera Cluster for MySQLHigh-availability with Galera Cluster for MySQL
High-availability with Galera Cluster for MySQLFromDual GmbH
 

Similar to Mysqlhacodebits20091203 1260184765-phpapp02 (20)

Drupal Con My Sql Ha 2008 08 29
Drupal Con My Sql Ha 2008 08 29Drupal Con My Sql Ha 2008 08 29
Drupal Con My Sql Ha 2008 08 29
 
Buytaert kris my_sql-pacemaker
Buytaert kris my_sql-pacemakerBuytaert kris my_sql-pacemaker
Buytaert kris my_sql-pacemaker
 
Ukoug 2011 mysql_arch_for_orcl_dba
Ukoug 2011 mysql_arch_for_orcl_dbaUkoug 2011 mysql_arch_for_orcl_dba
Ukoug 2011 mysql_arch_for_orcl_dba
 
MySQL for Oracle DBAs
MySQL for Oracle DBAsMySQL for Oracle DBAs
MySQL for Oracle DBAs
 
Running MySQL in AWS
Running MySQL in AWSRunning MySQL in AWS
Running MySQL in AWS
 
NoSQL with MySQL
NoSQL with MySQLNoSQL with MySQL
NoSQL with MySQL
 
UKOUG 2011: Practical MySQL Tuning
UKOUG 2011: Practical MySQL TuningUKOUG 2011: Practical MySQL Tuning
UKOUG 2011: Practical MySQL Tuning
 
MySQL always-up with Galera Cluster
MySQL always-up with Galera ClusterMySQL always-up with Galera Cluster
MySQL always-up with Galera Cluster
 
Collaborate 2012 - Administering MySQL for Oracle DBAs
Collaborate 2012 - Administering MySQL for Oracle DBAsCollaborate 2012 - Administering MySQL for Oracle DBAs
Collaborate 2012 - Administering MySQL for Oracle DBAs
 
The Peoper Care and Feeding of a MySQL Server for Busy Linux Admin
The Peoper Care and Feeding of a MySQL Server for Busy Linux AdminThe Peoper Care and Feeding of a MySQL Server for Busy Linux Admin
The Peoper Care and Feeding of a MySQL Server for Busy Linux Admin
 
When is MyRocks good?
When is MyRocks good? When is MyRocks good?
When is MyRocks good?
 
MySQL Webinar 2/4 Performance tuning, hardware, optimisation
MySQL Webinar 2/4 Performance tuning, hardware, optimisationMySQL Webinar 2/4 Performance tuning, hardware, optimisation
MySQL Webinar 2/4 Performance tuning, hardware, optimisation
 
Open stack HA - Theory to Reality
Open stack HA -  Theory to RealityOpen stack HA -  Theory to Reality
Open stack HA - Theory to Reality
 
Proper Care and Feeding of a MySQL Database for Busy Linux Administrators
Proper Care and Feeding of a MySQL Database for Busy Linux AdministratorsProper Care and Feeding of a MySQL Database for Busy Linux Administrators
Proper Care and Feeding of a MySQL Database for Busy Linux Administrators
 
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
 
Linuxfest Northwest Proper Care and Feeding Of a MySQL for Busy Linux Admins
Linuxfest Northwest Proper Care and Feeding Of a MySQL for Busy Linux AdminsLinuxfest Northwest Proper Care and Feeding Of a MySQL for Busy Linux Admins
Linuxfest Northwest Proper Care and Feeding Of a MySQL for Busy Linux Admins
 
MySQL InnoDB Cluster - New Features in 8.0 Releases - Best Practices
MySQL InnoDB Cluster - New Features in 8.0 Releases - Best PracticesMySQL InnoDB Cluster - New Features in 8.0 Releases - Best Practices
MySQL InnoDB Cluster - New Features in 8.0 Releases - Best Practices
 
The Proper Care and Feeding of a MySQL Database for Busy Linux Admins -- SCaL...
The Proper Care and Feeding of a MySQL Database for Busy Linux Admins -- SCaL...The Proper Care and Feeding of a MySQL Database for Busy Linux Admins -- SCaL...
The Proper Care and Feeding of a MySQL Database for Busy Linux Admins -- SCaL...
 
High-availability with Galera Cluster for MySQL
High-availability with Galera Cluster for MySQLHigh-availability with Galera Cluster for MySQL
High-availability with Galera Cluster for MySQL
 
MariaDB 10 and Beyond
MariaDB 10 and BeyondMariaDB 10 and Beyond
MariaDB 10 and Beyond
 

More from Louis liu

Tcpcopy benchmark
Tcpcopy benchmarkTcpcopy benchmark
Tcpcopy benchmarkLouis liu
 
JK Log-Center architect
JK Log-Center architectJK Log-Center architect
JK Log-Center architectLouis liu
 
JKDB BACKUP Introduction
JKDB BACKUP IntroductionJKDB BACKUP Introduction
JKDB BACKUP IntroductionLouis liu
 
Infiniflash benchmark
Infiniflash benchmarkInfiniflash benchmark
Infiniflash benchmarkLouis liu
 
MySQL Tokudb engine benchmark
MySQL Tokudb engine benchmarkMySQL Tokudb engine benchmark
MySQL Tokudb engine benchmarkLouis liu
 
Nvmfs benchmark
Nvmfs benchmarkNvmfs benchmark
Nvmfs benchmarkLouis liu
 
MySQL 5.7 milestone
MySQL 5.7 milestoneMySQL 5.7 milestone
MySQL 5.7 milestoneLouis liu
 
MySQL Oslayer performace optimization
MySQL  Oslayer performace optimizationMySQL  Oslayer performace optimization
MySQL Oslayer performace optimizationLouis liu
 
MySQL async message subscription platform
MySQL async message subscription platformMySQL async message subscription platform
MySQL async message subscription platformLouis liu
 
HBASE Performane Test
HBASE Performane TestHBASE Performane Test
HBASE Performane TestLouis liu
 
Jkcn MySQLDB 架构
Jkcn MySQLDB 架构Jkcn MySQLDB 架构
Jkcn MySQLDB 架构Louis liu
 
基于Mongodb的压力评测工具 ycsb的一些概括
基于Mongodb的压力评测工具 ycsb的一些概括基于Mongodb的压力评测工具 ycsb的一些概括
基于Mongodb的压力评测工具 ycsb的一些概括Louis liu
 
My sql fabric ha and sharding solutions
My sql fabric ha and sharding solutionsMy sql fabric ha and sharding solutions
My sql fabric ha and sharding solutionsLouis liu
 
NetApp ef540 SSD Storage Test
NetApp ef540 SSD Storage TestNetApp ef540 SSD Storage Test
NetApp ef540 SSD Storage TestLouis liu
 
Exadata best practice on E-commerce area
Exadata best practice on E-commerce area Exadata best practice on E-commerce area
Exadata best practice on E-commerce area Louis liu
 
MySQL 5.5&5.6 new features summary
MySQL 5.5&5.6 new features summaryMySQL 5.5&5.6 new features summary
MySQL 5.5&5.6 new features summaryLouis liu
 
Ssd gc review
Ssd gc reviewSsd gc review
Ssd gc reviewLouis liu
 
1号店数据库架构
1号店数据库架构1号店数据库架构
1号店数据库架构Louis liu
 
Architecture of YHD
Architecture of YHDArchitecture of YHD
Architecture of YHDLouis liu
 

More from Louis liu (20)

Tcpcopy benchmark
Tcpcopy benchmarkTcpcopy benchmark
Tcpcopy benchmark
 
JK Log-Center architect
JK Log-Center architectJK Log-Center architect
JK Log-Center architect
 
Wdt Test
Wdt TestWdt Test
Wdt Test
 
JKDB BACKUP Introduction
JKDB BACKUP IntroductionJKDB BACKUP Introduction
JKDB BACKUP Introduction
 
Infiniflash benchmark
Infiniflash benchmarkInfiniflash benchmark
Infiniflash benchmark
 
MySQL Tokudb engine benchmark
MySQL Tokudb engine benchmarkMySQL Tokudb engine benchmark
MySQL Tokudb engine benchmark
 
Nvmfs benchmark
Nvmfs benchmarkNvmfs benchmark
Nvmfs benchmark
 
MySQL 5.7 milestone
MySQL 5.7 milestoneMySQL 5.7 milestone
MySQL 5.7 milestone
 
MySQL Oslayer performace optimization
MySQL  Oslayer performace optimizationMySQL  Oslayer performace optimization
MySQL Oslayer performace optimization
 
MySQL async message subscription platform
MySQL async message subscription platformMySQL async message subscription platform
MySQL async message subscription platform
 
HBASE Performane Test
HBASE Performane TestHBASE Performane Test
HBASE Performane Test
 
Jkcn MySQLDB 架构
Jkcn MySQLDB 架构Jkcn MySQLDB 架构
Jkcn MySQLDB 架构
 
基于Mongodb的压力评测工具 ycsb的一些概括
基于Mongodb的压力评测工具 ycsb的一些概括基于Mongodb的压力评测工具 ycsb的一些概括
基于Mongodb的压力评测工具 ycsb的一些概括
 
My sql fabric ha and sharding solutions
My sql fabric ha and sharding solutionsMy sql fabric ha and sharding solutions
My sql fabric ha and sharding solutions
 
NetApp ef540 SSD Storage Test
NetApp ef540 SSD Storage TestNetApp ef540 SSD Storage Test
NetApp ef540 SSD Storage Test
 
Exadata best practice on E-commerce area
Exadata best practice on E-commerce area Exadata best practice on E-commerce area
Exadata best practice on E-commerce area
 
MySQL 5.5&5.6 new features summary
MySQL 5.5&5.6 new features summaryMySQL 5.5&5.6 new features summary
MySQL 5.5&5.6 new features summary
 
Ssd gc review
Ssd gc reviewSsd gc review
Ssd gc review
 
1号店数据库架构
1号店数据库架构1号店数据库架构
1号店数据库架构
 
Architecture of YHD
Architecture of YHDArchitecture of YHD
Architecture of YHD
 

Recently uploaded

Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 3652toLead Limited
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsMark Billinghurst
 
Search Engine Optimization SEO PDF for 2024.pdf
Search Engine Optimization SEO PDF for 2024.pdfSearch Engine Optimization SEO PDF for 2024.pdf
Search Engine Optimization SEO PDF for 2024.pdfRankYa
 
Anypoint Exchange: It’s Not Just a Repo!
Anypoint Exchange: It’s Not Just a Repo!Anypoint Exchange: It’s Not Just a Repo!
Anypoint Exchange: It’s Not Just a Repo!Manik S Magar
 
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)Wonjun Hwang
 
"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr BaganFwdays
 
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationSafe Software
 
Unleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubUnleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubKalema Edgar
 
SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024Lorenzo Miniero
 
Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Mattias Andersson
 
Powerpoint exploring the locations used in television show Time Clash
Powerpoint exploring the locations used in television show Time ClashPowerpoint exploring the locations used in television show Time Clash
Powerpoint exploring the locations used in television show Time Clashcharlottematthew16
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationRidwan Fadjar
 
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Patryk Bandurski
 
Gen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfGen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfAddepto
 
The Future of Software Development - Devin AI Innovative Approach.pdf
The Future of Software Development - Devin AI Innovative Approach.pdfThe Future of Software Development - Devin AI Innovative Approach.pdf
The Future of Software Development - Devin AI Innovative Approach.pdfSeasiaInfotech2
 
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Mark Simos
 
Streamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupStreamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupFlorian Wilhelm
 
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek SchlawackFwdays
 
Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Scott Keck-Warren
 

Recently uploaded (20)

Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR Systems
 
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptxE-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
 
Search Engine Optimization SEO PDF for 2024.pdf
Search Engine Optimization SEO PDF for 2024.pdfSearch Engine Optimization SEO PDF for 2024.pdf
Search Engine Optimization SEO PDF for 2024.pdf
 
Anypoint Exchange: It’s Not Just a Repo!
Anypoint Exchange: It’s Not Just a Repo!Anypoint Exchange: It’s Not Just a Repo!
Anypoint Exchange: It’s Not Just a Repo!
 
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
 
"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan
 
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry InnovationBeyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
Beyond Boundaries: Leveraging No-Code Solutions for Industry Innovation
 
Unleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubUnleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding Club
 
SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024
 
Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?
 
Powerpoint exploring the locations used in television show Time Clash
Powerpoint exploring the locations used in television show Time ClashPowerpoint exploring the locations used in television show Time Clash
Powerpoint exploring the locations used in television show Time Clash
 
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 Presentation
 
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
 
Gen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfGen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdf
 
The Future of Software Development - Devin AI Innovative Approach.pdf
The Future of Software Development - Devin AI Innovative Approach.pdfThe Future of Software Development - Devin AI Innovative Approach.pdf
The Future of Software Development - Devin AI Innovative Approach.pdf
 
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
 
Streamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupStreamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project Setup
 
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
 
Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024
 

Mysqlhacodebits20091203 1260184765-phpapp02

  • 1. MySQL High Availability Solutions Lenz Grimmer <lenz@grimmer.com> < http://lenzg.net/ | Twitter: @lenzgr 2011-01-26 | San Francisco MySQL Meetup | USA
  • 2. $ whoami 1998 2002 2008 2010
  • 3. Agenda ● High Availability: Concepts & Considerations ● MySQL Replication ● DRBD / Pacemaker ● MySQL Cluster ● Other HA tools/applications
  • 4. Single MySQL Server MySQL Client SQL (SELECT, INSERT, UPDATE, DELETE) MySQL Storage Engines (InnoDB, MyISAM, PBXT...) Disk Storage (XFS, ReiserFS, JFS, ext3...)
  • 5. Why HA? ● Something can and will fail ● Service Maintenance ● Downtime is expensive ● Adding HA to an existing system is complex
  • 6. Elimination of the SPOF ● Identify what will fail eventually ● Hard disks ● Fans ● Consider what might fail ● Application crashes ● OOM-Situations, Kernel-Panics ● Network connections, Cables ● Power supply
  • 7. What is HA Clustering? ● Redundancy ● One system or service goes down → others take over ● IP address takeover, service takeover ● Ensuring data availability & integrity ● Not designed for high-performance
  • 9. Rules of High Availability ● Prepare for failure ● Aim to ensure that no important data is lost ● Keep it simple, stupid (KISS) ● Complexity is the enemy of reliability ● Automate it ● Test your setup frequently!
  • 10. HA Components ● Heartbeat ● Checks that services that are monitored, are alive. ● Can check individual servers, software services, networking etc. ● HA Monitor ● Configuration of the services ● Ensures proper shutdown and startup ● Allows manual control ● Shared storage / Replication
  • 11. Split-Brain ● Communications failures can lead to separated partitions of the cluster ● If those partitions each try and take control of the cluster, then it's called a split-brain condition ● If this happens, then bad things will happen ● Use Fencing or Moderation/Arbitration to avoid it
  • 12. Redundancy Using MySQL Replication MySQL Replication
  • 13. MySQL Replication ● Unidirectional ● Statement- or row-based (MySQL 5.1) ● Built into MySQL ● Easy to use and set up ● One Master, many Slaves ● Asynchronous – Slaves can lag behind ● New in MySQL 5.5: Semisync Replication
  • 14. MySQL Replication (2) ● Master maintains Binary logs & index ● Replication on Slave is single-threaded http://forge.mysql.com/wiki/ReplicationFeatures/ParallelSlave ● No automated fail-over ● No heartbeat, no monitoring ● New in 5.5: replication heartbeat
  • 15. MySQL Replication - Overview Read & Write Web/App Server Write Relay Log mysqld SQL I/O Threa Thread d Index & Binlogs Data Replication Binlog Data mysqld MySQL Master MySQL Slave
  • 16. Statement-based Replication ● Pro ✔ Proven (around since MySQL 3.23) ✔ Smaller log files ✔ Auditing of actual SQL statements ✔ No primary key requirement for replicated tables ● Con ✗ Non-deterministic functions and UDFs ✗ LOAD_FILE(), UUID(), CURRENT_USER(), FOUND_ROWS() (but RAND() and NOW() work)
  • 17. Row-based Replication ● Pro ✔ All changes can be replicated ✔ Similar technology used by other RDBMSes ✔ Fewer locks required for some INSERT, UPDATE or DELETE statements ● Con ✗ More data to be logged ✗ Log file size increases (backup/restore implications) ✗ Replicated tables require explicit primary keys ✗ Possible different result sets on bulk INSERTs
  • 18. Replication Topologies Master > Slave Master > Slaves Master > Slave > Slaves Masters > Slave (Multi-Source) Ring (Multi-Master) Master < > Master (Multi-Master)
  • 19. Master-Master Replication ● Two nodes are both master and slave to each other ● Useful for easier failover ● Not suitable for (write) load-balancing ● Don't write to both masters simultaneously! ● Use Sharding or Partitioning instead (e.g. MySQL Proxy)
  • 20. MySQL Replication as a HA Solution ● What happens if the Master fails? ● What happens if the Slave fails? ● This doesn’t sound like High Availability! ● Yes! ● Replication is only part of a HA configuration
  • 21. Pacemaker (Linux-HA) ● Supports 2 or more Nodes (v2) ● Resource monitoring (Apps and HW) ● Active fencing mechanism (STONITH) ● Node failure detection in seconds ● Supports many applications (incl. MySQL) ● http://clusterlabs.org/ ● http://www.clusterlabs.org/wiki/Load_Balanced_MySQL_Replicated_Cluster ● http://www.clusterlabs.org/wiki/DRBD_MySQL_HowTo
  • 22. Replication & HA ● Combined with Pacemaker ● Virtual IP takeover ● Slave gets promoted to Master ● Side benefits: load balancing & backup ● Can be tricky to fail back ● No automatic conflict resolution ● Proper failover needs to be scripted
  • 23. Redundancy With Disk Replication Disk Replication
  • 24. DRBD ● Distributed Replicated Block Device ● “RAID-1 over network” ● Synchronous/asynchronous block replication ● Automatic resynchronisation ● Application-agnostic ● Can mask local I/O-Errors ● Active/passive configuration ● Dual-primary mode (requires cluster file sytem like GFS or OCFS2) ● http://drbd.org/
  • 25. DRBD in Detail ● DRBD replicates data blocks between to block devices ● DRBD can be combined with Linux-HA and other HA solutions ● MySQL runs normally Applications on primary node ● MySQL is not active on Active Node Virtual IP Passive Node the secondary node ● DRBD is Linux only DRBD
  • 27. Replication vs. SAN ● Data Consistency / Integrity ● Synchronous vs. asynchronous ● SAN can become the SPOF ● Cold caches ● “Split brain”-Situations ● SAN/NAS I/O Overhead
  • 29. MySQL Cluster ● “Shared-nothing”-Architecture ● Automatic partitioning ● Distributed fragments ● Synchronous replication ● Fast, automatic fail-over of data nodes ● Automatic resynchronisation ● Transparent to MySQL applicationen ● Supports transactions ● http://mysql.com/products/database/cluster/
  • 30. MySQL Cluster ● In-memory indexes ● Not suitable for all query patterns (cross-table JOINs, range scans) ● No support for foreign keys ● Not suitable for long running transactions ● Network latency crucial ● Can be combined with MySQL replication (RBR)
  • 31.
  • 32. MySQL Cluster & Replikation ● MySQL Cluster ● Easy failover from one MySQL node to another ● Scaling write load using multiple SQL nodes ● Asynchronous replication from Cluster to regular MySQL slaves ● Slaves take read load (InnoDB/MyISAM) ● Quick setup of new slaves (Cluster Online Backup) ● Easy failover and fast recovery
  • 34. Galera Replication ● Patch for InnoDB plus external library ● Synchronous replication ● Single- or multi-master ● Multicast-Replication ● HA plus load sharing possible ● Certifikate-based replikation (instead of 2PC) ● http://codership.com/products/mysql_galera
  • 35. MMM ● MySQL Master-Master Replication Manager ● Perl-Script for monitoring, failover and management ● Master-master replication configuration (one active writable master) ● Failover by moving virtual IP-Address ● Also supports read balancing ● http://mysql-mmm.org/
  • 36. Continuent Tungsten Replicator ● Database-external solution ● Asynchronous, Master-Slave, Fan-out & Fan-in ● Java ● Log-based ● Events are stored in the Transaction History Log (THL) ● Modular architekture (Pipelines, Stages) ● http://continuent.com/community/tungsten-replicator
  • 37. Red Hat Cluster Suite ● HA and load balancing ● Supports up to 16 nodes ● Shared storage ● Monitors services, file systems and network status ● Fencing (STONITH) or distributed lock manager ● Configuration synchronization ● http://www.redhat.com/cluster_suite/
  • 38. Solaris Cluster / OpenHA Cluster ● Provides failover and scalability services ● Solaris / OpenSolaris (Project Colorado) ● Kernel-level components plus userland ● Agents monitor applications ● Geo Edition to provide Disaster Recovery using Replication ● Open Source since June 2007 ● http://hub.opensolaris.org/bin/view/Community+Group+ha-clusters/WebHome ● http://hub.opensolaris.org/bin/view/Project+ha-mysql/WebHome
  • 39. Flipper ● Perl Script managing pairs of MySQL servers replicating to each other. ● Automatic switchover, triggered manually ● Enables one half of the pair to be taken offline for maintenance work while other half carries on ● Moves IP addresses based on a role ("read- only", "writable") ● http://provenscaling.com/software/flipper/
  • 41. Thank you! Lenz Grimmer <lenz@grimmer.com> Twitter: @lenzgr http://lenzg.net/