UbuntuServer MySql database backup script code: UbuntuServerUbuntu
Ming:
Here I want to back up the pw85 database under the/var/lib/MySql database directory to the compressed file format of/home/snapshot (2012_04_11 refers to the date on which the backup was executed ), at last, only the backups of the last 7 days are retained.
Steps:1. create a directory to s
Xtrabackup One-click Automated backup Script V1 "original"Xtrabackup Backup tool installation and usehttp://990487026.blog.51cto.com/10133282/1697094Information to fill inBackup file path Backdir=/asset.innobackupexmysql used to back up the user User=rootmysql user's password pass=asset output information save path logfile=/var/www/htm L/index.htmlL[[Emailprotect
Note: here I want to back up the pw85 database under the/var/lib/MySql database directory to the compressed file format of/home/snapshot (2012_04_11 refers to the date on which the backup was executed ), at last, only the backups of the last 7 days are retained. Implementation steps: 1. Create a directory for saving the backup file:/home/mysql_datacd/home
Note:
Here I want to back up the pw85 database under
UbuntuServer MySql database backup script code: UbuntuServerUbuntu
BitsCN.com
Note:
Here I want to back up the pw85 database under the/var/lib/MySql database directory to the compressed file format of/home/snapshot (2012_04_11 refers to the date on which the backup was executed ), at last, only the backups of the last 7 days are retained.Steps:1. create a direct
In linux, the mysql automatic backup script code bitsCN.com is stored in/home/user/mysql_backup.sh.
Crontab
# Crontab-l
# M h dom mon dow command
28 16 ***/home/user/mysql_backup.sh
The script is as follows:
#! /Bin/sh
# Mysql_backup.sh: backup mysql databases and keep newest 5 days
Mysql automatic backup script bitsCN.com in linux
Put the script in/home/user/mysql_backup.sh
Crontab
# Crontab-l
# M h dom mon dow command
28 16 ***/home/user/mysql_backup.sh
The script is as follows:
#! /Bin/sh
# Mysql_backup.sh: backup mysql databases and keep newest 5 da
Whether because MySQL is too big, back and forth backup waste resource bandwidth and worry, if you want to solve this problem requires incremental backup, the following is the Zhangxiao resource Network modified a MySQL incremental backup script, I have made the relevant comments, you can use the modified.
VI/ETC/MY.C
One, add an SMTP serverModify the following file on the server that needs to send the automatic alarm, add the following two lines# Vim/etc/mail.rcset [email protected] Smtp=smtp.126.comset Smtp-auth-user=doteyplay smtp-auth-password=*** Smtp-auth =login Of course, the SMTP server here can also use other, such as QQ, but QQ can only send a few gua, in the test, total error: smtp-server:454 error:authentication failed, System busy, What a wicked TX! So, then changed to 126 of the SMTP server, and
Label:MySQL database is commonly used by the mysqldump export SQL for backup, but not suitable for a large number of databases, speed, lock table is two serious problems. I wrote the previous article about Xtrabackup's hot spare tools, see http://www.linuxidc.com/Linux/2015-02/113058.htm. The following script is the ability to automatically back up a database based on the Xtrabackup implementation. Requirem
With the continuous development and increase of the technical environment, the O M department is facing two trends: large-scale and complex. One or two O M personnel can manage hundreds of servers in the company in the future. At this time, the centralized monitoring and automatic O M platform is the best solution to the problem. This article describes a small problem that occurs when you switch to the centralized backup environment.
--------------
backup policy formulation
RMAN backup learning notes
Oracle Database Backup encryption RMAN Encryption
-------------------------------------- Split line --------------------------------------
1. Problem Description
An Oracle server that was originally running in a Windows environment was backed up using a script writt
This is a creation in
Article, where the information may have evolved or changed.
With the server running, the business log is growing, before the article provided by the logger can be on the business log file by day, size, ordinary three mode segmentation, this script is to solve the server storage pressure, the daily split log files scheduled cleanup and compressed storage, need to use with crontab, The script
Mysql runs as a mysql user and fails to write to homemybackup.
Mysql runs as a mysql user and cannot be written to/home/mybackup.
Put the script in/home/user/mysql_backup.sh
Crontab
# Crontab-l
# M h dom mon dow command
28 16 ***/home/user/mysql_backup.sh
The script is as follows:
The Code is as follows:
#! /Bin/sh
# Mysql_backup.sh: backup mysql databases and k
Put the script in/home/user/mysql_backup.sh
Crontab
# Crontab-l
# M h Dom mon Dow command
28 16 ***/home/user/mysql_backup.sh
The script is as follows:
CopyCode The Code is as follows :#! /Bin/sh
# Mysql_backup.sh: Backup MySQL Databases and keep newest 5 days backup.
#
# Last Updated: 20 march2006
#------------------
Share your own linux backup script (webdata + mysql) the function is used with crontab to automatically back up the website directory and mysql local copy ftp copy mailbox copy local and ftp automatically delete 3 days ago linux requires sendmail and ftp if not available when yum is installed and used...
Share your own linux backup
Note:
Here I want to back up the pw85 database under the/var/lib/MySql database directory to the compressed file format of/home/snapshot (2012_04_11 refers to the date on which the backup was executed ), at last, only the backups of the last 7 days are retained.
Steps:
1. Create a directory to save the backup file:/home/mysql_dataCd/home # enter the DirectoryMkdir mysql_data # create a directory2. Create a
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.