Why MEB(Mysql Enterprise Backup) ??
- HOT backup InnoDB tables, Warm MyISAM, MEMORY and other storage engines.
- On-the-fly compression (upto 99%)
- Full, Incremental and Partial backups.
- Quick, lightweight and worry-free backup process.
- In-database history tracking.
- Easy to copy and manage backup files.
- Easy and Fast restore (10X ~)
Installation of MEB using RPM
Step 1: Check if any previous MEB version installed or
not
Step 2: If it is not MEB3.12 then remove it and reinstall
it
To remove
:
To Install :
Default
location of MEB installation:
Create
backup user in mysql DB for backup
CREATE USER
'backupuser'@'localhost' identified by ‘**********’;
GRANT RELOAD
ON *.* TO 'backupuser'@'localhost';
GRANT
CREATE, INSERT, DROP, UPDATE ON mysql.backup_progress TO
'backupuser'@'localhost';
GRANT
CREATE, INSERT, SELECT, DROP, UPDATE ON mysql.backup_history TO
'backupuser'@'localhost';
GRANT
REPLICATION CLIENT ON *.* TO 'backupuser'@'localhost';
GRANT SUPER
ON *.* TO 'backupuser'@'localhost';
Backup Using MEB
Step 1: Configure script to modify backup directory in
example it would be taken /tmp. Script Link Here
--------------------------------------------------------------------------------------------------------
WORKINGDIR=/tmp (this dir
would be location where all backup copy will be placed)
user=root (user to take
backup)
pass=”google@123” (password for backup
user)
dREMOVETIME= 0 (no. of days before that all databases backup would be
cleaned up)
Note: When backup happens script will create directory for full and
differential at WORKINGDIR=/tmp
Step 2: Make Full backup using script
FULLBACKUPDIR
directory would be created in WORKINGDIR(if not) you setup in step1
Under this
directory subdirectory would be created with datetime format
Step 3: Make Incremental Backup using script
INCREMENTALBACKUPDIR directory would be created in WORKINGDIR(if
not) you setup in step1
Under this
directory subdirectory would be created with datetime format
Step 4: Make incremental-with-redo-log-only using script
INCREMENTALBACKUPDIR
directory would be created in WORKINGDIR(if not) you setup in step1
Under this
directory subdirectory would be created with datetime format
Step 5: Old Backup cleanup from FULLBACKUPDIR & INCREMENTALBACKUPDIR
It will clean all backups from directories with no. of
days setup in step 1
dREMOVETIME= 0
(for demo it was setup 0 to clean everything and can be changed in step 1)
RESTORE USING MEB
Step 1: Move backup to target server or ignore if same
server
Step 2: Stop MYSQL database
Step 3: Restore FULL backup
Step 4: Restore INCREMENTAL above FULL backup
Step 5: Restore INCREMENTAL above INCREMENTAL
BACKUP LOGS
All backup logs will be created
by default at location /tmp/log
Hey Jasjeet, This is one shop stop blog. I think nobody needs to go some other blog, after reading this blog. It has all the stuff to work in Production Environment. Thanks for sharing this knowledge as always.
ReplyDeleteThis comment has been removed by the author.
ReplyDeletewhere can i download meb.rpm package ?
ReplyDelete