Mysql – thesql upgrade from 5.6 to 5.7, how to config thesql backup

backupMySQLupgrade

we have a lot of mysql database running from 5.6 to 5.7 , we use netbackup to backup mysql ,
the local script (mysql_backup.sh) is as belows:

/opt/mysql/meb-4.1.3/bin/mysqlbackup –login-path=root –backup-image=sbt:bkpsbtNB$backuptime –sbt-lib-path=/usr/openv/netbackup/bin/libobk.so64 –sbt-environment="NB_ORA_SERV=pnbumaster,NB_ORA_CLIENT=prmbsage_svc,NB_ORA_POLICY=mysql_cdeskdb,NB_ORA_SCHED=Default-Application-Backup,ORACLE_HOME=/age/mysql" –backup-dir=/usr/openv/meb_bkdir/ backup-to-image –socket=/age/mysql/data-5.7.29/mysql.sock –port=3306 >> $MYSQL_LOG_FILE

every time we have upgrade database , we should re-config mysql_backup.sh

is there any method to auto config mysql backup?

Best Answer

Auto-config requires a script that will edit backup files to change versions. You can use any command-line editor, like vi, to change these files to appropriate configurations. It is almost impossible to say what particular commands you must include or modify in these scripts, as it depends completely on your configurations. Still, the best method is to use third-party backup software, such as Handy Backup, which works equally with both MySQL 5.6 and 5.7, and with all other versions, too.