Red Flag Linux case selection: Using AmandaZRM to back up a remote MySQL database

Source: Internet
Author: User
Tags server installation and configuration
At the end of this article, I found a fatal problem with ZRMforMySQL. As far as I understand and test it, it overwrites data recovery. For example

At the end of this article, I found a fatal problem with ZRM for MySQL. As far as I understand and test it, it overwrites data recovery. for example

At the end of this article, I found a fatal problem with ZRM for MySQL. As far as I understand and test it, it overwrites data recovery, for example, assume that a database server has two databases test1 and test2. You have backed up these two databases. One day, a table in the test2 database is broken, therefore, it cannot only restore corrupted tables, or even restore test2, but directly restore test1 and test2. This is definitely a nightmare.
I hope my current understanding is wrong, but I cannot find a place to control the recovery granularity. Let's take a look at the text below.

Zmanda Recovery Manager (ZRM) provides the ability to back up MySQL Databases and supports two backup modes: Logical backup and bare backup. For more information, see the official introduction. A backup instance is provided below.

First, we will introduce the backup environment. If you have read the previous article about Amanda's centralized backup instance, you will probably know what kind of network architecture it is. Take over the above, here the backup server is still cp1.domain.com, mySQL databases run on cp2.domain.com and cp3.domain.com respectively, and all their databases need to be backed up.

1. Server installation and configuration
First download the server program of the corresponding system from the official site, and then install it. Note: The server is dependent on the perl-DBI and MySQL-client libraries. install these two packages before installation.

After installation,/etc/mysql-zrm/is the location of its configuration file. There is a mysql-zrm.conf file under the/etc/mysql-zrm/directory, which is the most important configuration file. In the/etc/mysql-zrm/directory, you can create some directories. Each directory is the name of a backup set. For the sake of intuition, the host name is used to create a backup set.

Cp2.domain.com, cp3.domain. cometc

/Etc/mysql-zrm/mysql-zrm.conf can be used as a global configuration file, for each database to be backed up different, can be in the backup Set Directory mysql-zrm.conf definition, the definition here can overwrite the global definition.

First, we configure some global definition information in the/etc/mysql-zrm/mysql-zrm.conf file.

# Cat/etc/mysql-z/mysql-zrm.confBackup-level =0Backup-mode = logicalbackup-type = regularDestination=/Yourpath/DbCompress=1Compress-plugin =1Encrypt-plugin ="/Usr/share/mysql-zrm/plugins/encrypt. pl"Decrypt-option ="-D"All-databases ="Securepassword"Mailto=Your@domain.com"

The configuration information above should be intuitive.
Then configure some special parameters for each MySQL Server

=/Yourpath/Db =/Yourpath/Db

Create an encrypted password file

Root@Cp1 :~# Chmod 700/etc/mysql-zrm/. passphrase

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.