Free Sample
+ Collection

Mastering MariaDB

Mastering
Federico Razzoli

Debug, secure, and back up your data for optimum server performance with MariaDB
$29.99
$49.99
RRP $29.99
RRP $49.99
eBook
Print + eBook

Want this title & more?

$16.99 p/month

Subscribe to PacktLib

Enjoy full and instant access to over 2000 books and videos – you’ll find everything you need to stay ahead of the curve and make sure you can always get the job done.

Book Details

ISBN 139781783981540
Paperback384 pages

About This Book

  • Monitor database activity and the major operating system parameters to improve performance
  • Tweak the behaviour of a large number of servers to achieve the desired level of stability and reliability
  • Solve the typical problems related to running a server, such as slow queries, long locks, and so on
  • A practical guide to implementing MariaDB to administrate servers and improve their performance

Who This Book Is For

This book is intended for intermediate users who want to learn how to administrate a MariaDB server or a set of servers. It is aimed at MariaDB users, and hence working knowledge of MariaDB is a prerequisite.

Table of Contents

Chapter 1: Understanding the Essentials of MariaDB
The MariaDB architecture
The command-line client
Storage engines
Logs
MariaDB caches
InnoDB data structures
Authentication and security
The information_schema database
The performance_schema database
Compatibility with MySQL and other DBMS
MariaDB resources
Summary
Chapter 2: Debugging
Understanding error conditions in MariaDB
The diagnostics area
The GET DIAGNOSTICS statement
The error log
System logs
The general query log
Maintenance of the server logs
The SQL_ERROR_LOG plugin
Tips on debugging stored programs
Debugging stored programs using the SQL_ERROR_LOG plugin
Summary
Chapter 3: Optimizing Queries
The slow query log
Explaining the pt-query-digest command from Percona Toolkit
Introducing indexes
Working with the EXPLAIN statement
Summary
Chapter 4: Transactions and Locks
The InnoDB locks
Reads consistency
Deadlocks
Transactions
Metadata locks
Summary
Chapter 5: Users and Connections
User accounts
Setting permissions using roles
Connecting MariaDB through Secure Socket Layer
Authentication plugins
Monitoring connections
Summary
Chapter 6: Caches
InnoDB caches
MyISAM key cache
Aria page cache
The query cache explained
The table open cache
Per-session buffers
Summary
Chapter 7: InnoDB Compressed Tables
An overview of the InnoDB compression
InnoDB compression requirements
Explaining the file-per-table mode
Creating InnoDB compressed tables
Explaining the implementation of the InnoDB compression
Monitoring the InnoDB compression performance
Other compression solutions
Summary
Chapter 8: Backup and Disaster Recovery
Types of backups
Complete and incremental backups
Creating a dump file with mysqldump
Delimited text backups
Physical backups
Using the binary log for incremental backups
Percona XtraBackup
Securing backups
Repairing tables
Summary
Chapter 9: Replication
An overview of replication
Choosing a binary log format
Configuring replication
Multisource replication
Replication logs
Checking the replication for errors
Troubleshooting
Summary
Chapter 10: Table Partitioning
Support for partitioning
Partitioning types and expressions
Administering partitioned tables
Partitions' physical files
Query optimizations
Summary
Chapter 11: Data Sharding
Distributing files between multiple disks
The FEDERATEDX and CONNECT storage engines
The SPIDER storage engine
Summary
Chapter 12: MariaDB Galera Cluster
MariaDB Galera Cluster key concepts
Setting up a cluster
Starting the nodes
Configuring the cluster
Monitoring and troubleshooting
Load balancing
Listing the limitations of Galera Cluster
Galera Load Balancer
Summary

What You Will Learn

  • Identify inefficient queries using logs and log analysis tools
  • Design your indexes and optimize your queries to produce efficient query plans
  • Tune MariaDB and InnoDB configuration to achieve a stabilized degree of performance and reliability
  • Create and manage users, roles, and permissions
  • Perform regular backups and restore data
  • Share your data through several partitions, disks, or servers using techniques such as replication to make operations faster
  • Set up, maintain, and troubleshoot a replication environment as well as a database cluster

In Detail

MariaDB is a community-driven fork of MySQL, and is a relational DBMS that can be used to build reliable, high-performance database servers. MariaDB combines MySQL characteristics such as replication, backup and disaster recovery, transactions and locks, and also includes important improvements to the performance, stability, security, and monitoring capabilities.

Mastering MariaDBstarts with an overview of the basic features and mechanisms, which includes diagnosing and solving real-life problems such as data corruption, poorly performing queries, and deadlocks. You will learn how to improve the performance of a server by identifying slow queries, and how to choose and set up a proper backup plan and recover data when disasters occur. You will learn how to share your data through several servers using replication. By the end of this book, you will be able to configure MariaDB servers, diagnose as well as troubleshoot common transactional problems, and execute database maintenance.

Authors

Read More