--disable_query_log --disable_result_log --disable_warnings drop database if exists log; create database log; drop table if exists test.log; create table log.bkp(`time` time); let $iter=$ITER; let $bdir=`select @@backupdir`; while ($iter) { --error 0,1 --remove_file $bdir/db1.bkp --echo BACKUP start... let $start= `select now()`; #SELECT count(*) FROM db1.t1; BACKUP DATABASE db1 TO 'db1.bkp'; let $t=`select timediff(now(),'$start')`; --echo BACKUP end: $t eval insert into log.bkp values ('$t'); #--echo RESTORE start... #let $start= `select now()`; #RESTORE FROM 'db1.bkp' OVERWRITE; #let $t=`select timediff(now(),'$start')`; #--echo RESTORE end: $t dec $iter; } --enable_result_log select min(time) as min, sec_to_time(avg(time_to_sec(time))) as avg, max(time) as max from log.bkp; #drop database log; drop table if exists test.table10_innodb_int_autoinc; --exit