Percona XtraBackup is a free, complete on the internet back-up solution for all editions of Percona Server, MySQL and MariaDB. Percona XtraBackup works on the internet non-blocking, firmly compacted, highly protected back-ups on transnational systems so that programs stay fully available during organized servicing windows.
Percona XtraBackup provides :
- Fast and efficient backups
- Uninterrupted deal handling during backups
- Savings on hard drive area and system data transfer usage with better compression
- Automatic backup verification
- Higher uptime due to quicker recovery time
While following steps you must be:
- Access to the admin of your database
- Superuser privileges on an Ubuntu 14.04 system
- A running MySQL or MariaDB database
Also, to carry out a hot back-up of your data source, your data source program must be using the InnoDB storage engine. This is because XtraBackup is based on the deal log that InnoDB maintains. If your data source is using the MyISAM storage engine, you can still use XtraBackup but the data source will be closed for a brief period towards the end of the back-up.
Storage Engine Status :
If you are uncertain of which storage engine your data source use, you can look it up through a variety of methods. One way is to use the MySQL system to choose the data source in question, then outcome the position of each table.
First, go into the MySQL console:
mysql -u root -p
Here you need to user your mySql Password
Choose the data source that you want to examine. Be sure to alternate your own data source name here
mysql> USE database_name;
Then create its table statuses:
mysql> SHOW TABLE STATUS\G;
Once you are done, keep the console:
Let's set up Percona XtraBackup.
The simplest way to set up Percona XtraBackup is to use apt-get.
Add the Percona repository key with this command:
sudo apt-key adv --keyserver keys.gnupg.net --recv-keys 1C4CBDCDCD2EFD2A
Run this control to upgrade your apt sources:
sudo apt-get update
Lastly, you can run this control to set up XtraBackup:
sudo apt-get install percona-xtrabackup
XtraBackup comprises mainly of the XtraBackup system, and the innobackupex Perl system, which we will use to make our data source back-ups.
First Time Preparations :
sudo gpasswd -a username mysql
sudo mkdir -p /data/backups
sudo chown -R username: /data
MySQL User :
mysql -u root -p
mysql> CREATE USER 'backupuser'@'localhost' IDENTIFIED BY 'backuppassword';
mysql> GRANT RELOAD, LOCK TABLES, REPLICATION CLIENT ON *.* TO 'backupuser'@'localhost';
mysql> FLUSH PRIVILEGES;