SlideShare ist ein Scribd-Unternehmen logo
1 von 39
Downloaden Sie, um offline zu lesen
MySQL Server Backup, Restoration,
and Disaster Recovery Planning
Colin Charles <byte@sun.com>
Lenz Grimmer <lenz@sun.com>
MySQL Conference 2009, Santa Clara, CA
2009-04-23


Sun Microsystems
                                         1
Disclaimer
• Covering Linux / Unix only
• MySQL Cluster (NDB) has its own backup
  method




                                           2
Backing up MySQL data
•   When do you need backups?
•   What needs to be backed up?
•   When should backups be performed?
•   Where will the backups be stored?
•   How can backups be performed?




                                        3
When Do You Need Backups?
• Hardware failure
  > A system crash may cause some of the data in
    the databases to be lost
  > A hard­disk failure will most certainly lead to lost
    data
• User/Application failure
  > Accidental DROP TABLE or malformed DELETE
    FROM statements
  > Editing the table files with text editors, usually
    leading to corrupt tables



                                                           4
What needs to be backed up?
• Database content
  > for full backups
  > logical or physical backup
• Log files
  > for incremental backups
  > point­in­time recovery
• Configuration information
  > /etc/my.cnf
  > Cron jobs
• Consider using an SCM (bzr, git, hg) for
  config files
                                             5
When should backups be performed?
• On a regular basis
• Not during high usage peaks (off hours)
• Static data can be backed up less
  frequently




                                            6
Where to store backups?
• On the database server
 > At least on a separate file system/volume or hard disk
   drive
• Copied to another server
 > On or off site
 > Cloud storage (using encryption)
• Backed up to tape/disk
 > Stored on or off site
• Choose multiple locations



                                                            7
The Data Directory
• Databases and most log and status files are
  stored in the data directory by default
• Default directory compiled into the server
  > /usr/local/mysql/data/ (tarball installation)
  > /var/lib/mysql (RPM packages)
• Data directory location can be specified during
  server startup with
  ­­datadir=/path/to/datadir/
• Find out the location by asking the server
  mysql> SHOW VARIABLES like 'data%';



                                                    8
The Binary Log
• Contains all SQL commands that change data
  (statement based) or the actual data that was modified
  (row­based)
• Also contains additional information about each query
  (e.g. query execution time)
• Binary log is stored in an efficient binary format
• Use mysqlbinlog to decipher the log contents
• Log turned on with ­­log­bin[=file_name]
• Update logs are created in sequence
  e.g. file_name­bin.001, file_name­bin.002, etc.
• Binary log is transaction­compatible
• mysqld creates binary log index file which contains
  names of the binary log files used

                                                           9
Managing The Binary Log
   Purpose of the Binary Log:
     Enable replication
     Ease crash recovery


 SHOW MASTER LOGS shows all binary log files
  residing on the server
 FLUSH LOGS or restarting the server creates a

  new file
 RESET MASTER deletes all binary log files

 PURGE MASTER deletes all binary log files up to

  a certain point
 Don't delete logs that slaves still need



                                                    10
mysqldump
 Dumps table structure and data into SQL statements
  $ mysqldump mydb > mydb.20090413.sql
 Dumps individual tables or whole databases

 Default output from mysqldump consists of SQL

  statements:
  – CREATE TABLE statements for table structure
  – INSERT statements for the data
 Can also be used directly as input into another mysqld

  server (without creating any files)
   $ mysqldump ­­opt world | mysql ­

    hwork.mysql.com world



                                                           11
mysqldump hints
• Use ­­single­transaction when
  backing up InnoDB tables
• ­­lock­all­tables is useful for
  performing consistent MyISAM backups
 > But locks all DML statements until backup is
   done
• ­­flush­logs flushes the binary log file
  (checkpointing)



                                                  12
Recovering from Backups
• Restoring tables to the state before a crash requires
    both the backup files and the binary log
  > Restore the tables to the state they were at the time
    of the backup from the backup files
  > Extract the queries issued between the backup and
    now from synchronised binary logs
• If you are recovering data lost due to unwise
  queries, remember not to issue them again

       DB Recovery = Last full backup & binlogs



                                                            13
Example SQL level restore
• Restore the last full backup
  mysql < backup.sql

• Apply all incremental changes done after
  the last full backup
  mysqlbinlog hostname­bin.000001 | mysql




                                             14
MySQL table files backup
• Also called “physical” backup
• MyISAM Database files can simply be
  copied after issuing FLUSH TABLES
  WITH READ LOCK;
• The mysqlhotcopy Perl script automates
  this process
• Locking all tables for consistency can be
  expensive, if the file backup operation
  takes a long time


                                              15
OSS backup tools
• The usual suspects: cp, tar, cpio, gzip,
  zip called in a shell script via a cron job
• rsync or unison for bandwidth­friendly,
  remote backups
• Don't use these on live tables!
  (Remember ma.gnolia.com?)
• Complete network­based backup solutions
  like afbackup, Amanda or Bacula provide
  more sophisticated features (e.g. catalogs)


                                                16
XtraBackup / Maatkit
• http://percona.com/percona­lab.html
• Online backup for InnoDB (and XtraDB)
• Does not work with the InnoDB plugin
• Add this to my.cnf:
  > [xtrabackup]
    target_dir = /home/backups
• To backup:
  > xtrabackup –backup
• http://maatkit.org/
• mk­parallel­dump / mk­parallel­restore
  > Multithreaded Perl wrapper scripts
                                           17
Linux backup support
• File system snapshots
  > LVM
  > Zumastor
  > btrfs
  > R1Soft Linux Hot Copy
• DRBD (“RAID1 over the network”)
• Distributed file systems
 >   OpenAFS
 >   GFS
 >   Lustre
 >   Novell iFolder
                                    18
Backup using file system snapshots
• File system snapshots provide a very
  convenient and fast backup solution for
  backing up entire databases without
  disruption
• Snapshot volume size does not need to be
  very large (10­15% are sufficient in a
  typical scenario)
• Backup of files from a snapshot volume
  can be performed with any tool


                                             19
Linux LVM snapshot creation
 Basic principle:
 mysql> FLUSH TABLES WITH READ LOCK
 $ lvcreate ­s –­size=<size> ­­name=backup
 <LV>
 mysql> UNLOCK TABLES
 $ mount /dev/<VG>/backup /mnt
 $ tar czvf backup.tar.gz /mnt/*
 $ umount /mnt
 $ lvremove /dev/<VG>/backup




                                             20
Benefits of MySQL Snapshot Backups
•   “Almost hot” (no downtime)
•   Supports all storage engines
•   Fast, low overhead
•   Easy integration
•   Can be combined with log recovery
•   Fast recovery
•   (Usually) Free


                                        21
Snapshot Backup Caveats
• Not incremental
• InnoDB ignores FLUSH TABLES WITH
  READ LOCK
• FLUSH TABLES performance impact
• Possible I/O performance impact while
  snapshot is active (Linux LVM)
• Handling data spread on multiple volumes
  (DB logs on separate LV or DBs spread
  across multiple LVs)

                                             22
Linux LVM Snapshots
• Atomic, instant & exact copy of another LV
• Low disk space requirements (COW)
• LVM2 provides read & write access on
  snapshots
 > Useful for testing purposes (e.g. software
   updates)
 > Or cloning Xen DomU instances
 > Or starting another MySQL instance




                                                23
Linux LVM Overview




                     24
ZFS
• 128bit File System
• Solaris/OpenSolaris, FreeBSD, Linux (zfs­
  fuse), Mac OS X
• Simple administration
• Pooled storage (no partitions/volumes)
• Copy­on­write transactions




                                              25
ZFS (2)
• Checksums, self­healing (no silent data
  corruption)
• Striping / mirroring / RAID / Compression
• ZFS Volumes (iSCSI)
• CIFS / NFS




                                              26
ZFS Snapshots
• Read­only, point­in­time copy of the
  filesystem
• Instantaneous creation
• (Virtually) unlimited number of snapshots
• Initially, no additional space used
• Writable copies (Clones)
• Incremental replication (zfs send/receive)
• Snapshots are simple & cheap to create!
 zfs snapshot fsname@snapname

                                               27
The mylvmbackup script
• A Perl script for quickly creating MySQL backups
  using LVM snapshots
• Snapshots are mounted to a temporary directory
  and all data is backed up using tar,rsync or
  rsnap
• Timestamped archive names allow running
  mylvmbackup many times without risking to
  overwrite old archives
• Can perform InnoDB log recovery on the
  snapshot prior to backup (LVM2)
• Requires Perl, DBI and DBD::mysql
• http://www.lenzg.net/mylvmbackup/
                                                     28
MySQL replication
• Backing up a replication slave is less time­critical
  (Master is not blocked for updates)
• A slave can use different storage engines
• One Master can replicate to many slaves
• Keep the limitations of MySQL replication in
  mind
• Make sure to back up the master.info and
  relay-log.info files as well as any
  SQL_LOAD-* files (if LOAD DATA INFILE is
  replicated)


                                                         29
Commercial backup solutions
•   Acronis True Image
•   ARCServe
•   Arkeia
•   InnoDB HotBackup
•   SEP sesam
•   Veritas vxfs snapshots
•   R1Soft CDP
•   Zmanda Recovery Manager (ZRM)




                                    30
Backup Method Comparison
• Output from mysqldump is portable to any other
  DBMS (without the ­­opt option) whereas
  copied files only work with MySQL
• Full backups are expensive
• Restoring from logs can be tricky
• The file copying methods are much faster than
  mysqldump
• So it comes down to your preferences:
  – Which tool do you prefer to use
  – Speed vs. portability


                                                   31
Backup Principles
• Perform backups regularly
• Turn on the binary update log
  > Update logs are needed to restore the database without
    losing any data
• Synchronise update logs with the backup files
  > Use FLUSH LOGS
• Name your backups consistently and understandably
  > Include the date in the file name mydb.20090414.sql
• Store your backups on a different file system than where
  your databases are




                                                             32
General backup notes
• Putting the binary logs on a different file system
  (or even a different drive) than the data directory
  is recommended (increases performance and
  avoids data loss)
• Verify the backup is consistent and complete!
• Define backup schedules and policies as well
  as recovery procedures
• Test that these actually work!




                                                        33
The MySQL Online Backup API
• An API to perform a streaming MySQL online
  backup, independent of the Storage Engine
• Transactional tables will contain data only from
  committed transactions
• Non­transactional tables will contain data only
  from completed statements
• Referential integrity will be maintained between
  all tables backed up with a specific backup
  command
• Now available on MySQL Forge:
  http://forge.mysql.com/wiki/OnlineBackup


                                                     34
Online Backup example
• Future (MySQL 6)
• Commands
 > BACKUP DATABASE sakila TO 'sakila­
   backup.sql';
 > Metadata: SELECT * FROM
   mysql.online_backup WHERE
   backup_id = 1 G
 > RESTORE FROM 'sakila­backup.sql';
 > Metadata: SELECT * FROM
   mysql.online_backup WHERE
   backup_id = 2 G

                                        35
Disaster Recovery
• Business continuity planning
 > 1. Minimize financial loss
 > 2. Reduce time to restore operations
 > 3. Increase sense of security
• Emergency planning
 > People involved
 > Steps to perform
 > Location of offsite backups?




                                          36
Discussion


             Thank you!

    Lenz Grimmer <lenz@sun.com>
            http://lenzg.net/
    Colin Charles <byte@sun.com>
           http://bytebot.net/


                                   37
The Error Log
• When started with mysqld_safe, all error
  messages are directed to the error log
• The log contains info on when mysqld was started
  and stopped as well as errors found when running
  $ cat /var/log/mysql.err
  000929 15:29:45 mysqld started
  /usr/sbin/mysqld: ready for connections
  000929 15:31:15 Aborted connection 1 to db: 'unconnected'
  user: 'root' host: `localhost' (Got an error writing communication
      packets)
  000929 15:31:15 /usr/local/mysql/bin/mysqld: Normal shutdown

  000929 15:31:15   /usr/local/mysql/bin/mysqld: Shutdown Complete

  000929 15:31:54 mysqld started
  /usr/sbin/mysqld: ready for connections




                                                                       38
Backing Up InnoDB Databases
•   Use mysqldump ­­single transaction to make an
    on­line backup
•   InnoDB Hot Backup (commercial)
•   To take a ’binary’ backup, do the following:
    1. Shutdown the MySQL server
    2. Copy your data files, InnoDB log files, .frm files and
       my.cnf file(s) to a safe location
    3. Restart the server
•   It is a good idea to backup with mysqldump also, since
    an error might occur in a binary file without you noticing
    it



                                                                 39

Weitere ähnliche Inhalte

Was ist angesagt?

Percona XtraDB Cluster vs Galera Cluster vs MySQL Group Replication
Percona XtraDB Cluster vs Galera Cluster vs MySQL Group ReplicationPercona XtraDB Cluster vs Galera Cluster vs MySQL Group Replication
Percona XtraDB Cluster vs Galera Cluster vs MySQL Group ReplicationKenny Gryp
 
Postgresql database administration volume 1
Postgresql database administration volume 1Postgresql database administration volume 1
Postgresql database administration volume 1Federico Campoli
 
Inside PostgreSQL Shared Memory
Inside PostgreSQL Shared MemoryInside PostgreSQL Shared Memory
Inside PostgreSQL Shared MemoryEDB
 
Redpanda and ClickHouse
Redpanda and ClickHouseRedpanda and ClickHouse
Redpanda and ClickHouseAltinity Ltd
 
HandsOn ProxySQL Tutorial - PLSC18
HandsOn ProxySQL Tutorial - PLSC18HandsOn ProxySQL Tutorial - PLSC18
HandsOn ProxySQL Tutorial - PLSC18Derek Downey
 
The Full MySQL and MariaDB Parallel Replication Tutorial
The Full MySQL and MariaDB Parallel Replication TutorialThe Full MySQL and MariaDB Parallel Replication Tutorial
The Full MySQL and MariaDB Parallel Replication TutorialJean-François Gagné
 
ksqlDB - Stream Processing simplified!
ksqlDB - Stream Processing simplified!ksqlDB - Stream Processing simplified!
ksqlDB - Stream Processing simplified!Guido Schmutz
 
ProxySQL High Avalability and Configuration Management Overview
ProxySQL High Avalability and Configuration Management OverviewProxySQL High Avalability and Configuration Management Overview
ProxySQL High Avalability and Configuration Management OverviewRené Cannaò
 
Intro ProxySQL
Intro ProxySQLIntro ProxySQL
Intro ProxySQLI Goo Lee
 
MySQL Parallel Replication: inventory, use-case and limitations
MySQL Parallel Replication: inventory, use-case and limitationsMySQL Parallel Replication: inventory, use-case and limitations
MySQL Parallel Replication: inventory, use-case and limitationsJean-François Gagné
 
MariaDB MaxScale
MariaDB MaxScaleMariaDB MaxScale
MariaDB MaxScaleMariaDB plc
 
OpenStack High Availability
OpenStack High AvailabilityOpenStack High Availability
OpenStack High AvailabilityJakub Pavlik
 
Building ClickHouse and Making Your First Contribution: A Tutorial_06.10.2021
Building ClickHouse and Making Your First Contribution: A Tutorial_06.10.2021Building ClickHouse and Making Your First Contribution: A Tutorial_06.10.2021
Building ClickHouse and Making Your First Contribution: A Tutorial_06.10.2021Altinity Ltd
 
Producer Performance Tuning for Apache Kafka
Producer Performance Tuning for Apache KafkaProducer Performance Tuning for Apache Kafka
Producer Performance Tuning for Apache KafkaJiangjie Qin
 
Spark + Cassandra = Real Time Analytics on Operational Data
Spark + Cassandra = Real Time Analytics on Operational DataSpark + Cassandra = Real Time Analytics on Operational Data
Spark + Cassandra = Real Time Analytics on Operational DataVictor Coustenoble
 
[135] 오픈소스 데이터베이스, 은행 서비스에 첫발을 내밀다.
[135] 오픈소스 데이터베이스, 은행 서비스에 첫발을 내밀다.[135] 오픈소스 데이터베이스, 은행 서비스에 첫발을 내밀다.
[135] 오픈소스 데이터베이스, 은행 서비스에 첫발을 내밀다.NAVER D2
 
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 MariaDBMariaDB plc
 
MySQL Administrator 2021 - 네오클로바
MySQL Administrator 2021 - 네오클로바MySQL Administrator 2021 - 네오클로바
MySQL Administrator 2021 - 네오클로바NeoClova
 
Maxscale 소개 1.1.1
Maxscale 소개 1.1.1Maxscale 소개 1.1.1
Maxscale 소개 1.1.1NeoClova
 
From Message to Cluster: A Realworld Introduction to Kafka Capacity Planning
From Message to Cluster: A Realworld Introduction to Kafka Capacity PlanningFrom Message to Cluster: A Realworld Introduction to Kafka Capacity Planning
From Message to Cluster: A Realworld Introduction to Kafka Capacity Planningconfluent
 

Was ist angesagt? (20)

Percona XtraDB Cluster vs Galera Cluster vs MySQL Group Replication
Percona XtraDB Cluster vs Galera Cluster vs MySQL Group ReplicationPercona XtraDB Cluster vs Galera Cluster vs MySQL Group Replication
Percona XtraDB Cluster vs Galera Cluster vs MySQL Group Replication
 
Postgresql database administration volume 1
Postgresql database administration volume 1Postgresql database administration volume 1
Postgresql database administration volume 1
 
Inside PostgreSQL Shared Memory
Inside PostgreSQL Shared MemoryInside PostgreSQL Shared Memory
Inside PostgreSQL Shared Memory
 
Redpanda and ClickHouse
Redpanda and ClickHouseRedpanda and ClickHouse
Redpanda and ClickHouse
 
HandsOn ProxySQL Tutorial - PLSC18
HandsOn ProxySQL Tutorial - PLSC18HandsOn ProxySQL Tutorial - PLSC18
HandsOn ProxySQL Tutorial - PLSC18
 
The Full MySQL and MariaDB Parallel Replication Tutorial
The Full MySQL and MariaDB Parallel Replication TutorialThe Full MySQL and MariaDB Parallel Replication Tutorial
The Full MySQL and MariaDB Parallel Replication Tutorial
 
ksqlDB - Stream Processing simplified!
ksqlDB - Stream Processing simplified!ksqlDB - Stream Processing simplified!
ksqlDB - Stream Processing simplified!
 
ProxySQL High Avalability and Configuration Management Overview
ProxySQL High Avalability and Configuration Management OverviewProxySQL High Avalability and Configuration Management Overview
ProxySQL High Avalability and Configuration Management Overview
 
Intro ProxySQL
Intro ProxySQLIntro ProxySQL
Intro ProxySQL
 
MySQL Parallel Replication: inventory, use-case and limitations
MySQL Parallel Replication: inventory, use-case and limitationsMySQL Parallel Replication: inventory, use-case and limitations
MySQL Parallel Replication: inventory, use-case and limitations
 
MariaDB MaxScale
MariaDB MaxScaleMariaDB MaxScale
MariaDB MaxScale
 
OpenStack High Availability
OpenStack High AvailabilityOpenStack High Availability
OpenStack High Availability
 
Building ClickHouse and Making Your First Contribution: A Tutorial_06.10.2021
Building ClickHouse and Making Your First Contribution: A Tutorial_06.10.2021Building ClickHouse and Making Your First Contribution: A Tutorial_06.10.2021
Building ClickHouse and Making Your First Contribution: A Tutorial_06.10.2021
 
Producer Performance Tuning for Apache Kafka
Producer Performance Tuning for Apache KafkaProducer Performance Tuning for Apache Kafka
Producer Performance Tuning for Apache Kafka
 
Spark + Cassandra = Real Time Analytics on Operational Data
Spark + Cassandra = Real Time Analytics on Operational DataSpark + Cassandra = Real Time Analytics on Operational Data
Spark + Cassandra = Real Time Analytics on Operational Data
 
[135] 오픈소스 데이터베이스, 은행 서비스에 첫발을 내밀다.
[135] 오픈소스 데이터베이스, 은행 서비스에 첫발을 내밀다.[135] 오픈소스 데이터베이스, 은행 서비스에 첫발을 내밀다.
[135] 오픈소스 데이터베이스, 은행 서비스에 첫발을 내밀다.
 
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
 
MySQL Administrator 2021 - 네오클로바
MySQL Administrator 2021 - 네오클로바MySQL Administrator 2021 - 네오클로바
MySQL Administrator 2021 - 네오클로바
 
Maxscale 소개 1.1.1
Maxscale 소개 1.1.1Maxscale 소개 1.1.1
Maxscale 소개 1.1.1
 
From Message to Cluster: A Realworld Introduction to Kafka Capacity Planning
From Message to Cluster: A Realworld Introduction to Kafka Capacity PlanningFrom Message to Cluster: A Realworld Introduction to Kafka Capacity Planning
From Message to Cluster: A Realworld Introduction to Kafka Capacity Planning
 

Andere mochten auch

Deep Dive on Amazon Relational Database Service
Deep Dive on Amazon Relational Database ServiceDeep Dive on Amazon Relational Database Service
Deep Dive on Amazon Relational Database ServiceAmazon Web Services
 
AWS Blackbelt NINJA Dojo – Dean Samuels
AWS Blackbelt NINJA Dojo – Dean SamuelsAWS Blackbelt NINJA Dojo – Dean Samuels
AWS Blackbelt NINJA Dojo – Dean SamuelsAmazon Web Services
 
(SDD403) Amazon RDS for MySQL Deep Dive | AWS re:Invent 2014
(SDD403) Amazon RDS for MySQL Deep Dive | AWS re:Invent 2014(SDD403) Amazon RDS for MySQL Deep Dive | AWS re:Invent 2014
(SDD403) Amazon RDS for MySQL Deep Dive | AWS re:Invent 2014Amazon Web Services
 
Disaster Recovery using AWS -Architecture blueprints
Disaster Recovery using AWS -Architecture blueprintsDisaster Recovery using AWS -Architecture blueprints
Disaster Recovery using AWS -Architecture blueprintsHarish Ganesan
 
AWS re:Invent 2016: Deep Dive on Amazon Relational Database Service (DAT305)
AWS re:Invent 2016: Deep Dive on Amazon Relational Database Service (DAT305)AWS re:Invent 2016: Deep Dive on Amazon Relational Database Service (DAT305)
AWS re:Invent 2016: Deep Dive on Amazon Relational Database Service (DAT305)Amazon Web Services
 

Andere mochten auch (6)

Deep Dive on Amazon RDS
Deep Dive on Amazon RDSDeep Dive on Amazon RDS
Deep Dive on Amazon RDS
 
Deep Dive on Amazon Relational Database Service
Deep Dive on Amazon Relational Database ServiceDeep Dive on Amazon Relational Database Service
Deep Dive on Amazon Relational Database Service
 
AWS Blackbelt NINJA Dojo – Dean Samuels
AWS Blackbelt NINJA Dojo – Dean SamuelsAWS Blackbelt NINJA Dojo – Dean Samuels
AWS Blackbelt NINJA Dojo – Dean Samuels
 
(SDD403) Amazon RDS for MySQL Deep Dive | AWS re:Invent 2014
(SDD403) Amazon RDS for MySQL Deep Dive | AWS re:Invent 2014(SDD403) Amazon RDS for MySQL Deep Dive | AWS re:Invent 2014
(SDD403) Amazon RDS for MySQL Deep Dive | AWS re:Invent 2014
 
Disaster Recovery using AWS -Architecture blueprints
Disaster Recovery using AWS -Architecture blueprintsDisaster Recovery using AWS -Architecture blueprints
Disaster Recovery using AWS -Architecture blueprints
 
AWS re:Invent 2016: Deep Dive on Amazon Relational Database Service (DAT305)
AWS re:Invent 2016: Deep Dive on Amazon Relational Database Service (DAT305)AWS re:Invent 2016: Deep Dive on Amazon Relational Database Service (DAT305)
AWS re:Invent 2016: Deep Dive on Amazon Relational Database Service (DAT305)
 

Ähnlich wie MySQL Server Backup, Restoration, And Disaster Recovery Planning Presentation

MySQL Server Backup, Restoration, and Disaster Recovery Planning
MySQL Server Backup, Restoration, and Disaster Recovery PlanningMySQL Server Backup, Restoration, and Disaster Recovery Planning
MySQL Server Backup, Restoration, and Disaster Recovery PlanningLenz Grimmer
 
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
 
Making MySQL Administration a Breeze - A look into a MySQL DBA's toolchest
Making MySQL Administration a Breeze - A look into a MySQL DBA's toolchest Making MySQL Administration a Breeze - A look into a MySQL DBA's toolchest
Making MySQL Administration a Breeze - A look into a MySQL DBA's toolchest Lenz Grimmer
 
MySQL for Oracle DBAs
MySQL for Oracle DBAsMySQL for Oracle DBAs
MySQL for Oracle DBAsMark Leith
 
MYSQLDUMP & ZRM COMMUNITY (EN)
MYSQLDUMP & ZRM COMMUNITY (EN)MYSQLDUMP & ZRM COMMUNITY (EN)
MYSQLDUMP & ZRM COMMUNITY (EN)Cédric P
 
MySQL Enterprise Backup (MEB)
MySQL Enterprise Backup (MEB)MySQL Enterprise Backup (MEB)
MySQL Enterprise Backup (MEB)Mydbops
 
Making MySQL Administration a Breeze - A Look Into a MySQL DBA's Toolchest
Making MySQL Administration a Breeze - A Look Into a MySQL DBA's ToolchestMaking MySQL Administration a Breeze - A Look Into a MySQL DBA's Toolchest
Making MySQL Administration a Breeze - A Look Into a MySQL DBA's ToolchestLenz Grimmer
 
Rman Presentation
Rman PresentationRman Presentation
Rman PresentationRick van Ek
 
A Backup Today Saves Tomorrow
A Backup Today Saves TomorrowA Backup Today Saves Tomorrow
A Backup Today Saves TomorrowAndrew Moore
 
Deployment Strategies (Mongo Austin)
Deployment Strategies (Mongo Austin)Deployment Strategies (Mongo Austin)
Deployment Strategies (Mongo Austin)MongoDB
 
My sql introduction for Bestcom
My sql introduction for BestcomMy sql introduction for Bestcom
My sql introduction for BestcomIvan Tu
 
My S Q L Introduction for 1 day training
My S Q L  Introduction for 1 day trainingMy S Q L  Introduction for 1 day training
My S Q L Introduction for 1 day trainingIvan Tu
 
Infrastructure review - Shining a light on the Black Box
Infrastructure review - Shining a light on the Black BoxInfrastructure review - Shining a light on the Black Box
Infrastructure review - Shining a light on the Black BoxMiklos Szel
 
My sql with enterprise storage
My sql with enterprise storageMy sql with enterprise storage
My sql with enterprise storageCaroline_Rose
 
Percona Xtrabackup - Highly Efficient Backups
Percona Xtrabackup - Highly Efficient BackupsPercona Xtrabackup - Highly Efficient Backups
Percona Xtrabackup - Highly Efficient BackupsMydbops
 
Anthony Somerset - Site Speed = Success!
Anthony Somerset - Site Speed = Success!Anthony Somerset - Site Speed = Success!
Anthony Somerset - Site Speed = Success!WordCamp Cape Town
 
Training Slides: 203 - Backup & Recovery
Training Slides: 203 - Backup & RecoveryTraining Slides: 203 - Backup & Recovery
Training Slides: 203 - Backup & RecoveryContinuent
 

Ähnlich wie MySQL Server Backup, Restoration, And Disaster Recovery Planning Presentation (20)

MySQL Server Backup, Restoration, and Disaster Recovery Planning
MySQL Server Backup, Restoration, and Disaster Recovery PlanningMySQL Server Backup, Restoration, and Disaster Recovery Planning
MySQL Server Backup, Restoration, and Disaster Recovery Planning
 
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
 
Making MySQL Administration a Breeze - A look into a MySQL DBA's toolchest
Making MySQL Administration a Breeze - A look into a MySQL DBA's toolchest Making MySQL Administration a Breeze - A look into a MySQL DBA's toolchest
Making MySQL Administration a Breeze - A look into a MySQL DBA's toolchest
 
MySQL for Oracle DBAs
MySQL for Oracle DBAsMySQL for Oracle DBAs
MySQL for Oracle DBAs
 
Running MySQL on Linux
Running MySQL on LinuxRunning MySQL on Linux
Running MySQL on Linux
 
MySQL database
MySQL databaseMySQL database
MySQL database
 
MYSQLDUMP & ZRM COMMUNITY (EN)
MYSQLDUMP & ZRM COMMUNITY (EN)MYSQLDUMP & ZRM COMMUNITY (EN)
MYSQLDUMP & ZRM COMMUNITY (EN)
 
MySQL Enterprise Backup (MEB)
MySQL Enterprise Backup (MEB)MySQL Enterprise Backup (MEB)
MySQL Enterprise Backup (MEB)
 
Making MySQL Administration a Breeze - A Look Into a MySQL DBA's Toolchest
Making MySQL Administration a Breeze - A Look Into a MySQL DBA's ToolchestMaking MySQL Administration a Breeze - A Look Into a MySQL DBA's Toolchest
Making MySQL Administration a Breeze - A Look Into a MySQL DBA's Toolchest
 
Rman Presentation
Rman PresentationRman Presentation
Rman Presentation
 
A Backup Today Saves Tomorrow
A Backup Today Saves TomorrowA Backup Today Saves Tomorrow
A Backup Today Saves Tomorrow
 
Deployment Strategies (Mongo Austin)
Deployment Strategies (Mongo Austin)Deployment Strategies (Mongo Austin)
Deployment Strategies (Mongo Austin)
 
My sql introduction for Bestcom
My sql introduction for BestcomMy sql introduction for Bestcom
My sql introduction for Bestcom
 
My S Q L Introduction for 1 day training
My S Q L  Introduction for 1 day trainingMy S Q L  Introduction for 1 day training
My S Q L Introduction for 1 day training
 
Infrastructure review - Shining a light on the Black Box
Infrastructure review - Shining a light on the Black BoxInfrastructure review - Shining a light on the Black Box
Infrastructure review - Shining a light on the Black Box
 
My sql with enterprise storage
My sql with enterprise storageMy sql with enterprise storage
My sql with enterprise storage
 
Percona Xtrabackup - Highly Efficient Backups
Percona Xtrabackup - Highly Efficient BackupsPercona Xtrabackup - Highly Efficient Backups
Percona Xtrabackup - Highly Efficient Backups
 
Anthony Somerset - Site Speed = Success!
Anthony Somerset - Site Speed = Success!Anthony Somerset - Site Speed = Success!
Anthony Somerset - Site Speed = Success!
 
Tuning Linux for MongoDB
Tuning Linux for MongoDBTuning Linux for MongoDB
Tuning Linux for MongoDB
 
Training Slides: 203 - Backup & Recovery
Training Slides: 203 - Backup & RecoveryTraining Slides: 203 - Backup & Recovery
Training Slides: 203 - Backup & Recovery
 

Mehr von Colin Charles

Differences between MariaDB 10.3 & MySQL 8.0
Differences between MariaDB 10.3 & MySQL 8.0Differences between MariaDB 10.3 & MySQL 8.0
Differences between MariaDB 10.3 & MySQL 8.0Colin Charles
 
What is MariaDB Server 10.3?
What is MariaDB Server 10.3?What is MariaDB Server 10.3?
What is MariaDB Server 10.3?Colin Charles
 
Databases in the hosted cloud
Databases in the hosted cloud Databases in the hosted cloud
Databases in the hosted cloud Colin Charles
 
MySQL features missing in MariaDB Server
MySQL features missing in MariaDB ServerMySQL features missing in MariaDB Server
MySQL features missing in MariaDB ServerColin Charles
 
The MySQL ecosystem - understanding it, not running away from it!
The MySQL ecosystem - understanding it, not running away from it! The MySQL ecosystem - understanding it, not running away from it!
The MySQL ecosystem - understanding it, not running away from it! Colin Charles
 
Databases in the Hosted Cloud
Databases in the Hosted CloudDatabases in the Hosted Cloud
Databases in the Hosted CloudColin Charles
 
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 TutorialColin Charles
 
Percona ServerをMySQL 5.6と5.7用に作るエンジニアリング(そしてMongoDBのヒント)
Percona ServerをMySQL 5.6と5.7用に作るエンジニアリング(そしてMongoDBのヒント)Percona ServerをMySQL 5.6と5.7用に作るエンジニアリング(そしてMongoDBのヒント)
Percona ServerをMySQL 5.6と5.7用に作るエンジニアリング(そしてMongoDBのヒント)Colin Charles
 
Capacity planning for your data stores
Capacity planning for your data storesCapacity planning for your data stores
Capacity planning for your data storesColin Charles
 
The Proxy Wars - MySQL Router, ProxySQL, MariaDB MaxScale
The Proxy Wars - MySQL Router, ProxySQL, MariaDB MaxScaleThe Proxy Wars - MySQL Router, ProxySQL, MariaDB MaxScale
The Proxy Wars - MySQL Router, ProxySQL, MariaDB MaxScaleColin Charles
 
Lessons from {distributed,remote,virtual} communities and companies
Lessons from {distributed,remote,virtual} communities and companiesLessons from {distributed,remote,virtual} communities and companies
Lessons from {distributed,remote,virtual} communities and companiesColin Charles
 
Forking Successfully - or is a branch better?
Forking Successfully - or is a branch better?Forking Successfully - or is a branch better?
Forking Successfully - or is a branch better?Colin Charles
 
MariaDB Server Compatibility with MySQL
MariaDB Server Compatibility with MySQLMariaDB Server Compatibility with MySQL
MariaDB Server Compatibility with MySQLColin Charles
 
Securing your MySQL / MariaDB Server data
Securing your MySQL / MariaDB Server dataSecuring your MySQL / MariaDB Server data
Securing your MySQL / MariaDB Server dataColin Charles
 
The MySQL Server Ecosystem in 2016
The MySQL Server Ecosystem in 2016The MySQL Server Ecosystem in 2016
The MySQL Server Ecosystem in 2016Colin Charles
 
The Complete MariaDB Server tutorial
The Complete MariaDB Server tutorialThe Complete MariaDB Server tutorial
The Complete MariaDB Server tutorialColin Charles
 
Best practices for MySQL/MariaDB Server/Percona Server High Availability
Best practices for MySQL/MariaDB Server/Percona Server High AvailabilityBest practices for MySQL/MariaDB Server/Percona Server High Availability
Best practices for MySQL/MariaDB Server/Percona Server High AvailabilityColin Charles
 
Lessons from database failures
Lessons from database failures Lessons from database failures
Lessons from database failures Colin Charles
 
Lessons from database failures
Lessons from database failuresLessons from database failures
Lessons from database failuresColin Charles
 
Lessons from database failures
Lessons from database failuresLessons from database failures
Lessons from database failuresColin Charles
 

Mehr von Colin Charles (20)

Differences between MariaDB 10.3 & MySQL 8.0
Differences between MariaDB 10.3 & MySQL 8.0Differences between MariaDB 10.3 & MySQL 8.0
Differences between MariaDB 10.3 & MySQL 8.0
 
What is MariaDB Server 10.3?
What is MariaDB Server 10.3?What is MariaDB Server 10.3?
What is MariaDB Server 10.3?
 
Databases in the hosted cloud
Databases in the hosted cloud Databases in the hosted cloud
Databases in the hosted cloud
 
MySQL features missing in MariaDB Server
MySQL features missing in MariaDB ServerMySQL features missing in MariaDB Server
MySQL features missing in MariaDB Server
 
The MySQL ecosystem - understanding it, not running away from it!
The MySQL ecosystem - understanding it, not running away from it! The MySQL ecosystem - understanding it, not running away from it!
The MySQL ecosystem - understanding it, not running away from it!
 
Databases in the Hosted Cloud
Databases in the Hosted CloudDatabases in the Hosted Cloud
Databases in the Hosted Cloud
 
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
 
Percona ServerをMySQL 5.6と5.7用に作るエンジニアリング(そしてMongoDBのヒント)
Percona ServerをMySQL 5.6と5.7用に作るエンジニアリング(そしてMongoDBのヒント)Percona ServerをMySQL 5.6と5.7用に作るエンジニアリング(そしてMongoDBのヒント)
Percona ServerをMySQL 5.6と5.7用に作るエンジニアリング(そしてMongoDBのヒント)
 
Capacity planning for your data stores
Capacity planning for your data storesCapacity planning for your data stores
Capacity planning for your data stores
 
The Proxy Wars - MySQL Router, ProxySQL, MariaDB MaxScale
The Proxy Wars - MySQL Router, ProxySQL, MariaDB MaxScaleThe Proxy Wars - MySQL Router, ProxySQL, MariaDB MaxScale
The Proxy Wars - MySQL Router, ProxySQL, MariaDB MaxScale
 
Lessons from {distributed,remote,virtual} communities and companies
Lessons from {distributed,remote,virtual} communities and companiesLessons from {distributed,remote,virtual} communities and companies
Lessons from {distributed,remote,virtual} communities and companies
 
Forking Successfully - or is a branch better?
Forking Successfully - or is a branch better?Forking Successfully - or is a branch better?
Forking Successfully - or is a branch better?
 
MariaDB Server Compatibility with MySQL
MariaDB Server Compatibility with MySQLMariaDB Server Compatibility with MySQL
MariaDB Server Compatibility with MySQL
 
Securing your MySQL / MariaDB Server data
Securing your MySQL / MariaDB Server dataSecuring your MySQL / MariaDB Server data
Securing your MySQL / MariaDB Server data
 
The MySQL Server Ecosystem in 2016
The MySQL Server Ecosystem in 2016The MySQL Server Ecosystem in 2016
The MySQL Server Ecosystem in 2016
 
The Complete MariaDB Server tutorial
The Complete MariaDB Server tutorialThe Complete MariaDB Server tutorial
The Complete MariaDB Server tutorial
 
Best practices for MySQL/MariaDB Server/Percona Server High Availability
Best practices for MySQL/MariaDB Server/Percona Server High AvailabilityBest practices for MySQL/MariaDB Server/Percona Server High Availability
Best practices for MySQL/MariaDB Server/Percona Server High Availability
 
Lessons from database failures
Lessons from database failures Lessons from database failures
Lessons from database failures
 
Lessons from database failures
Lessons from database failuresLessons from database failures
Lessons from database failures
 
Lessons from database failures
Lessons from database failuresLessons from database failures
Lessons from database failures
 

Kürzlich hochgeladen

MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MIND CTI
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProduct Anonymous
 
Top 10 Most Downloaded Games on Play Store in 2024
Top 10 Most Downloaded Games on Play Store in 2024Top 10 Most Downloaded Games on Play Store in 2024
Top 10 Most Downloaded Games on Play Store in 2024SynarionITSolutions
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodJuan lago vázquez
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Scriptwesley chun
 
Manulife - Insurer Innovation Award 2024
Manulife - Insurer Innovation Award 2024Manulife - Insurer Innovation Award 2024
Manulife - Insurer Innovation Award 2024The Digital Insurer
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingEdi Saputra
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024The Digital Insurer
 
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?Igalia
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processorsdebabhi2
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc
 
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...apidays
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUK Journal
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024The Digital Insurer
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)Gabriella Davis
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsJoaquim Jorge
 
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 WorkerThousandEyes
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024The Digital Insurer
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityPrincipled Technologies
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century educationjfdjdjcjdnsjd
 

Kürzlich hochgeladen (20)

MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
Top 10 Most Downloaded Games on Play Store in 2024
Top 10 Most Downloaded Games on Play Store in 2024Top 10 Most Downloaded Games on Play Store in 2024
Top 10 Most Downloaded Games on Play Store in 2024
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
Manulife - Insurer Innovation Award 2024
Manulife - Insurer Innovation Award 2024Manulife - Insurer Innovation Award 2024
Manulife - Insurer Innovation Award 2024
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
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?
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
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...
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
 
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
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 

MySQL Server Backup, Restoration, And Disaster Recovery Planning Presentation

  • 1. MySQL Server Backup, Restoration, and Disaster Recovery Planning Colin Charles <byte@sun.com> Lenz Grimmer <lenz@sun.com> MySQL Conference 2009, Santa Clara, CA 2009-04-23 Sun Microsystems 1
  • 2. Disclaimer • Covering Linux / Unix only • MySQL Cluster (NDB) has its own backup method 2
  • 3. Backing up MySQL data • When do you need backups? • What needs to be backed up? • When should backups be performed? • Where will the backups be stored? • How can backups be performed? 3
  • 4. When Do You Need Backups? • Hardware failure > A system crash may cause some of the data in the databases to be lost > A hard­disk failure will most certainly lead to lost data • User/Application failure > Accidental DROP TABLE or malformed DELETE FROM statements > Editing the table files with text editors, usually leading to corrupt tables 4
  • 5. What needs to be backed up? • Database content > for full backups > logical or physical backup • Log files > for incremental backups > point­in­time recovery • Configuration information > /etc/my.cnf > Cron jobs • Consider using an SCM (bzr, git, hg) for config files 5
  • 6. When should backups be performed? • On a regular basis • Not during high usage peaks (off hours) • Static data can be backed up less frequently 6
  • 7. Where to store backups? • On the database server > At least on a separate file system/volume or hard disk drive • Copied to another server > On or off site > Cloud storage (using encryption) • Backed up to tape/disk > Stored on or off site • Choose multiple locations 7
  • 8. The Data Directory • Databases and most log and status files are stored in the data directory by default • Default directory compiled into the server > /usr/local/mysql/data/ (tarball installation) > /var/lib/mysql (RPM packages) • Data directory location can be specified during server startup with ­­datadir=/path/to/datadir/ • Find out the location by asking the server mysql> SHOW VARIABLES like 'data%'; 8
  • 9. The Binary Log • Contains all SQL commands that change data (statement based) or the actual data that was modified (row­based) • Also contains additional information about each query (e.g. query execution time) • Binary log is stored in an efficient binary format • Use mysqlbinlog to decipher the log contents • Log turned on with ­­log­bin[=file_name] • Update logs are created in sequence e.g. file_name­bin.001, file_name­bin.002, etc. • Binary log is transaction­compatible • mysqld creates binary log index file which contains names of the binary log files used 9
  • 10. Managing The Binary Log  Purpose of the Binary Log:  Enable replication  Ease crash recovery  SHOW MASTER LOGS shows all binary log files residing on the server  FLUSH LOGS or restarting the server creates a new file  RESET MASTER deletes all binary log files  PURGE MASTER deletes all binary log files up to a certain point  Don't delete logs that slaves still need 10
  • 11. mysqldump  Dumps table structure and data into SQL statements $ mysqldump mydb > mydb.20090413.sql  Dumps individual tables or whole databases  Default output from mysqldump consists of SQL statements: – CREATE TABLE statements for table structure – INSERT statements for the data  Can also be used directly as input into another mysqld server (without creating any files)  $ mysqldump ­­opt world | mysql ­ hwork.mysql.com world 11
  • 12. mysqldump hints • Use ­­single­transaction when backing up InnoDB tables • ­­lock­all­tables is useful for performing consistent MyISAM backups > But locks all DML statements until backup is done • ­­flush­logs flushes the binary log file (checkpointing) 12
  • 13. Recovering from Backups • Restoring tables to the state before a crash requires both the backup files and the binary log > Restore the tables to the state they were at the time of the backup from the backup files > Extract the queries issued between the backup and now from synchronised binary logs • If you are recovering data lost due to unwise queries, remember not to issue them again DB Recovery = Last full backup & binlogs 13
  • 14. Example SQL level restore • Restore the last full backup mysql < backup.sql • Apply all incremental changes done after the last full backup mysqlbinlog hostname­bin.000001 | mysql 14
  • 15. MySQL table files backup • Also called “physical” backup • MyISAM Database files can simply be copied after issuing FLUSH TABLES WITH READ LOCK; • The mysqlhotcopy Perl script automates this process • Locking all tables for consistency can be expensive, if the file backup operation takes a long time 15
  • 16. OSS backup tools • The usual suspects: cp, tar, cpio, gzip, zip called in a shell script via a cron job • rsync or unison for bandwidth­friendly, remote backups • Don't use these on live tables! (Remember ma.gnolia.com?) • Complete network­based backup solutions like afbackup, Amanda or Bacula provide more sophisticated features (e.g. catalogs) 16
  • 17. XtraBackup / Maatkit • http://percona.com/percona­lab.html • Online backup for InnoDB (and XtraDB) • Does not work with the InnoDB plugin • Add this to my.cnf: > [xtrabackup] target_dir = /home/backups • To backup: > xtrabackup –backup • http://maatkit.org/ • mk­parallel­dump / mk­parallel­restore > Multithreaded Perl wrapper scripts 17
  • 18. Linux backup support • File system snapshots > LVM > Zumastor > btrfs > R1Soft Linux Hot Copy • DRBD (“RAID1 over the network”) • Distributed file systems > OpenAFS > GFS > Lustre > Novell iFolder 18
  • 19. Backup using file system snapshots • File system snapshots provide a very convenient and fast backup solution for backing up entire databases without disruption • Snapshot volume size does not need to be very large (10­15% are sufficient in a typical scenario) • Backup of files from a snapshot volume can be performed with any tool 19
  • 20. Linux LVM snapshot creation Basic principle: mysql> FLUSH TABLES WITH READ LOCK $ lvcreate ­s –­size=<size> ­­name=backup <LV> mysql> UNLOCK TABLES $ mount /dev/<VG>/backup /mnt $ tar czvf backup.tar.gz /mnt/* $ umount /mnt $ lvremove /dev/<VG>/backup 20
  • 21. Benefits of MySQL Snapshot Backups • “Almost hot” (no downtime) • Supports all storage engines • Fast, low overhead • Easy integration • Can be combined with log recovery • Fast recovery • (Usually) Free 21
  • 22. Snapshot Backup Caveats • Not incremental • InnoDB ignores FLUSH TABLES WITH READ LOCK • FLUSH TABLES performance impact • Possible I/O performance impact while snapshot is active (Linux LVM) • Handling data spread on multiple volumes (DB logs on separate LV or DBs spread across multiple LVs) 22
  • 23. Linux LVM Snapshots • Atomic, instant & exact copy of another LV • Low disk space requirements (COW) • LVM2 provides read & write access on snapshots > Useful for testing purposes (e.g. software updates) > Or cloning Xen DomU instances > Or starting another MySQL instance 23
  • 25. ZFS • 128bit File System • Solaris/OpenSolaris, FreeBSD, Linux (zfs­ fuse), Mac OS X • Simple administration • Pooled storage (no partitions/volumes) • Copy­on­write transactions 25
  • 26. ZFS (2) • Checksums, self­healing (no silent data corruption) • Striping / mirroring / RAID / Compression • ZFS Volumes (iSCSI) • CIFS / NFS 26
  • 27. ZFS Snapshots • Read­only, point­in­time copy of the filesystem • Instantaneous creation • (Virtually) unlimited number of snapshots • Initially, no additional space used • Writable copies (Clones) • Incremental replication (zfs send/receive) • Snapshots are simple & cheap to create! zfs snapshot fsname@snapname 27
  • 28. The mylvmbackup script • A Perl script for quickly creating MySQL backups using LVM snapshots • Snapshots are mounted to a temporary directory and all data is backed up using tar,rsync or rsnap • Timestamped archive names allow running mylvmbackup many times without risking to overwrite old archives • Can perform InnoDB log recovery on the snapshot prior to backup (LVM2) • Requires Perl, DBI and DBD::mysql • http://www.lenzg.net/mylvmbackup/ 28
  • 29. MySQL replication • Backing up a replication slave is less time­critical (Master is not blocked for updates) • A slave can use different storage engines • One Master can replicate to many slaves • Keep the limitations of MySQL replication in mind • Make sure to back up the master.info and relay-log.info files as well as any SQL_LOAD-* files (if LOAD DATA INFILE is replicated) 29
  • 30. Commercial backup solutions • Acronis True Image • ARCServe • Arkeia • InnoDB HotBackup • SEP sesam • Veritas vxfs snapshots • R1Soft CDP • Zmanda Recovery Manager (ZRM) 30
  • 31. Backup Method Comparison • Output from mysqldump is portable to any other DBMS (without the ­­opt option) whereas copied files only work with MySQL • Full backups are expensive • Restoring from logs can be tricky • The file copying methods are much faster than mysqldump • So it comes down to your preferences: – Which tool do you prefer to use – Speed vs. portability 31
  • 32. Backup Principles • Perform backups regularly • Turn on the binary update log > Update logs are needed to restore the database without losing any data • Synchronise update logs with the backup files > Use FLUSH LOGS • Name your backups consistently and understandably > Include the date in the file name mydb.20090414.sql • Store your backups on a different file system than where your databases are 32
  • 33. General backup notes • Putting the binary logs on a different file system (or even a different drive) than the data directory is recommended (increases performance and avoids data loss) • Verify the backup is consistent and complete! • Define backup schedules and policies as well as recovery procedures • Test that these actually work! 33
  • 34. The MySQL Online Backup API • An API to perform a streaming MySQL online backup, independent of the Storage Engine • Transactional tables will contain data only from committed transactions • Non­transactional tables will contain data only from completed statements • Referential integrity will be maintained between all tables backed up with a specific backup command • Now available on MySQL Forge: http://forge.mysql.com/wiki/OnlineBackup 34
  • 35. Online Backup example • Future (MySQL 6) • Commands > BACKUP DATABASE sakila TO 'sakila­ backup.sql'; > Metadata: SELECT * FROM mysql.online_backup WHERE backup_id = 1 G > RESTORE FROM 'sakila­backup.sql'; > Metadata: SELECT * FROM mysql.online_backup WHERE backup_id = 2 G 35
  • 36. Disaster Recovery • Business continuity planning > 1. Minimize financial loss > 2. Reduce time to restore operations > 3. Increase sense of security • Emergency planning > People involved > Steps to perform > Location of offsite backups? 36
  • 37. Discussion Thank you! Lenz Grimmer <lenz@sun.com> http://lenzg.net/ Colin Charles <byte@sun.com> http://bytebot.net/ 37
  • 38. The Error Log • When started with mysqld_safe, all error messages are directed to the error log • The log contains info on when mysqld was started and stopped as well as errors found when running $ cat /var/log/mysql.err 000929 15:29:45 mysqld started /usr/sbin/mysqld: ready for connections 000929 15:31:15 Aborted connection 1 to db: 'unconnected' user: 'root' host: `localhost' (Got an error writing communication packets) 000929 15:31:15 /usr/local/mysql/bin/mysqld: Normal shutdown 000929 15:31:15 /usr/local/mysql/bin/mysqld: Shutdown Complete 000929 15:31:54 mysqld started /usr/sbin/mysqld: ready for connections 38
  • 39. Backing Up InnoDB Databases • Use mysqldump ­­single transaction to make an on­line backup • InnoDB Hot Backup (commercial) • To take a ’binary’ backup, do the following: 1. Shutdown the MySQL server 2. Copy your data files, InnoDB log files, .frm files and my.cnf file(s) to a safe location 3. Restart the server • It is a good idea to backup with mysqldump also, since an error might occur in a binary file without you noticing it 39