List:Commits« Previous MessageNext Message »
From:Chuck Bell Date:August 21 2008 3:56pm
Subject:bzr commit into mysql-6.0-backup branch (cbell:2681) WL#4296
View as plain text  
#At file:///D:/source/bzr/mysql-6.0-wl-4296/

 2681 Chuck Bell	2008-08-21
      WL#4296 : Online Backup : Refine backup progress mechanism
      
      PATCH 2 of 2 : Test changes.
      
      This worklog changes the existing backup progress mechanism from MyISAM
      tables to logging capability similar to the query log. The new mechanism
      allows users to specify the destination of the log as a file, table, both,
      and allows users to turn the logs on or off.
added:
  mysql-test/r/backup_logs_output.result
  mysql-test/t/backup_logs_output.test
renamed:
  mysql-test/r/backup_progress.result => mysql-test/r/backup_logs.result
  mysql-test/t/backup_progress.test => mysql-test/t/backup_logs.test
modified:
  mysql-test/lib/mtr_report.pl
  mysql-test/r/1st.result
  mysql-test/r/backup_errors.result
  mysql-test/r/backup_no_be.result
  mysql-test/r/connect.result
  mysql-test/r/information_schema.result
  mysql-test/r/log_state.result
  mysql-test/r/mysql_upgrade.result
  mysql-test/r/mysqlcheck.result
  mysql-test/r/system_mysql_db.result
  mysql-test/suite/funcs_1/r/is_columns_mysql.result
  mysql-test/suite/funcs_1/r/is_statistics_mysql.result
  mysql-test/suite/funcs_1/r/is_table_constraints_mysql.result
  mysql-test/suite/funcs_1/r/is_tables_mysql.result
  mysql-test/t/backup_errors.test
  mysql-test/t/backup_no_be.test
  mysql-test/t/log_state.test
  mysql-test/t/mysqldump.test
  mysql-test/t/system_mysql_db_fix30020.test
  mysql-test/t/system_mysql_db_fix40123.test
  mysql-test/t/system_mysql_db_fix50030.test
  mysql-test/t/system_mysql_db_fix50117.test
  mysql-test/r/backup_logs.result
  mysql-test/t/backup_logs.test

per-file messages:
  mysql-test/lib/mtr_report.pl
    Corrected error message in warning exclusion.
  mysql-test/r/1st.result
    Corrected result file due to renamed backup log names.
  mysql-test/r/backup_errors.result
    Corrected result file due to renamed backup log names.
  mysql-test/r/backup_logs.result
    Corrected result file due to renamed backup log names.
  mysql-test/r/backup_logs_output.result
    New result file.
  mysql-test/r/backup_no_be.result
    Corrected result file with backup log renames.
  mysql-test/r/connect.result
    Corrected result file due to renamed backup log names.
  mysql-test/r/information_schema.result
    Corrected result file due to renamed backup log names.
  mysql-test/r/log_state.result
    Corrected log files output.
  mysql-test/r/mysql_upgrade.result
    Corrected result file due to renamed backup log names.
  mysql-test/r/mysqlcheck.result
    Corrected result file due to renamed backup log names.
  mysql-test/r/system_mysql_db.result
    Corrected result file due to renamed backup log names.
  mysql-test/suite/funcs_1/r/is_columns_mysql.result
    Corrected result file with changes to the backup log columns.
  mysql-test/suite/funcs_1/r/is_statistics_mysql.result
    Removed old backup table from list of tables with keys.
  mysql-test/suite/funcs_1/r/is_table_constraints_mysql.result
    Removed old backup table from list of tables with keys.
  mysql-test/suite/funcs_1/r/is_tables_mysql.result
    Corrected result file due to changes of backup log names and character set.
  mysql-test/t/backup_errors.test
    Changed backup log file names in test to match new log names.
  mysql-test/t/backup_logs.test
    Renamed test and expanded to test writing historical and progress data to the new backup logs.
  mysql-test/t/backup_logs_output.test
    New test to test output options for backup logs.
  mysql-test/t/backup_no_be.test
    Changed table names in test for the renamed backup log files.
  mysql-test/t/log_state.test
    Change commands to only display query and slow logs per original test.
  mysql-test/t/mysqldump.test
    Changed table names in test for the renamed backup log files.
  mysql-test/t/system_mysql_db_fix30020.test
    Changed table names in test for the renamed backup log files.
  mysql-test/t/system_mysql_db_fix40123.test
    Changed table names in test for the renamed backup log files.
  mysql-test/t/system_mysql_db_fix50030.test
    Changed table names in test for the renamed backup log files.
  mysql-test/t/system_mysql_db_fix50117.test
    Changed table names in test for the renamed backup log files.
=== modified file 'mysql-test/lib/mtr_report.pl'
--- a/mysql-test/lib/mtr_report.pl	2008-08-20 13:23:10 +0000
+++ b/mysql-test/lib/mtr_report.pl	2008-08-21 15:56:17 +0000
@@ -331,7 +331,7 @@ sub mtr_report_stats ($) {
 		# backup_errors test is supposed to trigger lots of backup related errors
 		($testname eq 'main.backup_errors') and
 		(
-		  /Backup:/ or /Restore:/ or /Can't open the online backup progress tables/
+		  /Backup:/ or /Restore:/ or /Can't open the backup log tables/
 		) or
 
 		# backup_backupdir test is supposed to trigger backup related errors

=== modified file 'mysql-test/r/1st.result'
--- a/mysql-test/r/1st.result	2007-11-30 06:04:31 +0000
+++ b/mysql-test/r/1st.result	2008-08-21 15:56:17 +0000
@@ -5,6 +5,8 @@ mysql
 test
 show tables in mysql;
 Tables_in_mysql
+backup_history
+backup_progress
 columns_priv
 db
 event
@@ -16,8 +18,6 @@ help_relation
 help_topic
 host
 ndb_binlog_index
-online_backup
-online_backup_progress
 plugin
 proc
 procs_priv

=== modified file 'mysql-test/r/backup_errors.result'
--- a/mysql-test/r/backup_errors.result	2008-08-21 11:36:09 +0000
+++ b/mysql-test/r/backup_errors.result	2008-08-21 15:56:17 +0000
@@ -63,8 +63,8 @@ Backup of mysql, information_schema scen
 BACKUP DATABASE mysql, information_schema, test TO 't.bak';
 ERROR HY000: Database 'mysql' cannot be included in a backup
 Making copies of progress tables.
-CREATE TABLE IF NOT EXISTS test.ob_copy LIKE mysql.online_backup;
-CREATE TABLE IF NOT EXISTS test.obp_copy LIKE mysql.online_backup_progress;
+CREATE TABLE IF NOT EXISTS test.ob_copy LIKE mysql.backup_history;
+CREATE TABLE IF NOT EXISTS test.obp_copy LIKE mysql.backup_progress;
 CREATE DATABASE test_ob_error;
 CREATE TABLE test_ob_error.t1 (col_a int);
 INSERT INTO test_ob_error.t1 VALUES (1), (2), (3), (4), (5);
@@ -72,27 +72,27 @@ Backup the database;
 BACKUP DATABASE test_ob_error TO 'ob_err.bak';
 backup_id
 #
-DROP TABLE mysql.online_backup;
+DROP TABLE mysql.backup_history;
 Backup the database;
 BACKUP DATABASE test_ob_error TO 'ob_err.bak';
-ERROR 42S02: Table 'mysql.online_backup' doesn't exist
+ERROR 42S02: Table 'mysql.backup_history' doesn't exist
 SHOW ERRORS;
 Level	Code	Message
-Error	#	Table 'mysql.online_backup' doesn't exist
+Error	#	Table 'mysql.backup_history' doesn't exist
 Error	#	Cannot create backup/restore execution context
 Restoring the table
-CREATE TABLE mysql.online_backup LIKE test.ob_copy;
+CREATE TABLE mysql.backup_history LIKE test.ob_copy;
 DROP TABLE test.ob_copy;
-DROP TABLE mysql.online_backup_progress;
+DROP TABLE mysql.backup_progress;
 Backup the database;
 BACKUP DATABASE test_ob_error TO 'ob_err.bak';
-ERROR 42S02: Table 'mysql.online_backup_progress' doesn't exist
+ERROR 42S02: Table 'mysql.backup_progress' doesn't exist
 SHOW ERRORS;
 Level	Code	Message
-Error	#	Table 'mysql.online_backup_progress' doesn't exist
+Error	#	Table 'mysql.backup_progress' doesn't exist
 Error	#	Cannot create backup/restore execution context
 Restoring the table
-CREATE TABLE mysql.online_backup_progress LIKE test.obp_copy;
+CREATE TABLE mysql.backup_progress LIKE test.obp_copy;
 DROP TABLE test.obp_copy;
 DROP DATABASE test_ob_error;
 

=== renamed file 'mysql-test/r/backup_progress.result' => 'mysql-test/r/backup_logs.result'
--- a/mysql-test/r/backup_progress.result	2008-08-08 17:21:31 +0000
+++ b/mysql-test/r/backup_logs.result	2008-08-21 15:56:17 +0000
@@ -1,9 +1,10 @@
+SET DEBUG_SYNC= 'RESET';
 
 Checking character set for backup tables 
 
 SELECT column_name, character_set_name 
 FROM information_schema.columns 
-WHERE table_name LIKE 'online_backup' 
+WHERE table_name LIKE 'backup_history' 
 AND character_set_name LIKE 'utf8' 
 ORDER BY column_name;
 column_name	character_set_name
@@ -19,7 +20,7 @@ user_comment	utf8
 
 SELECT column_name, character_set_name 
 FROM information_schema.columns 
-WHERE table_name LIKE 'online_backup_progress' 
+WHERE table_name LIKE 'backup_progress' 
 AND character_set_name LIKE 'utf8' 
 ORDER BY column_name;
 column_name	character_set_name
@@ -28,32 +29,30 @@ object	utf8
 
 Now starting real tests
 
-SET DEBUG_SYNC= 'reset';
-DROP DATABASE IF EXISTS backup_progress;
-DROP TABLE IF EXISTS backup_progress.t1_res;
-CREATE DATABASE backup_progress;
+DROP DATABASE IF EXISTS backup_logs;
+CREATE DATABASE backup_logs;
 con1: Create table and new users.
-CREATE TABLE backup_progress.t1 (a char(30)) ENGINE=MYISAM;
-CREATE TABLE backup_progress.t2 (a char(30)) ENGINE=INNODB;
-CREATE TABLE backup_progress.t3 (a char(30)) ENGINE=MEMORY;
-CREATE TABLE backup_progress.t1_res (id INT) ENGINE=MEMORY;
-INSERT INTO backup_progress.t1 VALUES ("01 Test #1 - progress");
-INSERT INTO backup_progress.t1 VALUES ("02 Test #1 - progress");
-INSERT INTO backup_progress.t1 VALUES ("03 Test #1 - progress");
-INSERT INTO backup_progress.t1 VALUES ("04 Test #1 - progress");
-INSERT INTO backup_progress.t1 VALUES ("05 Test #1 - progress");
-INSERT INTO backup_progress.t1 VALUES ("06 Test #1 - progress");
-INSERT INTO backup_progress.t1 VALUES ("07 Test #1 - progress");
-INSERT INTO backup_progress.t2 VALUES ("01 Test #1 - progress");
-INSERT INTO backup_progress.t2 VALUES ("02 Test #1 - progress");
-INSERT INTO backup_progress.t2 VALUES ("03 Test #1 - progress");
-INSERT INTO backup_progress.t2 VALUES ("04 Test #1 - progress");
-INSERT INTO backup_progress.t2 VALUES ("05 Test #1 - progress");
-INSERT INTO backup_progress.t2 VALUES ("06 Test #1 - progress");
-INSERT INTO backup_progress.t3 VALUES ("01 Test #1 - progress");
-INSERT INTO backup_progress.t3 VALUES ("02 Test #1 - progress");
-INSERT INTO backup_progress.t3 VALUES ("03 Test #1 - progress");
-INSERT INTO backup_progress.t3 VALUES ("04 Test #1 - progress");
+CREATE TABLE backup_logs.t1 (a char(30)) ENGINE=MYISAM;
+CREATE TABLE backup_logs.t2 (a char(30)) ENGINE=INNODB;
+CREATE TABLE backup_logs.t3 (a char(30)) ENGINE=MEMORY;
+CREATE TABLE backup_logs.t1_res (id INT) ENGINE=MEMORY;
+INSERT INTO backup_logs.t1 VALUES ("01 Test #1 - progress");
+INSERT INTO backup_logs.t1 VALUES ("02 Test #1 - progress");
+INSERT INTO backup_logs.t1 VALUES ("03 Test #1 - progress");
+INSERT INTO backup_logs.t1 VALUES ("04 Test #1 - progress");
+INSERT INTO backup_logs.t1 VALUES ("05 Test #1 - progress");
+INSERT INTO backup_logs.t1 VALUES ("06 Test #1 - progress");
+INSERT INTO backup_logs.t1 VALUES ("07 Test #1 - progress");
+INSERT INTO backup_logs.t2 VALUES ("01 Test #1 - progress");
+INSERT INTO backup_logs.t2 VALUES ("02 Test #1 - progress");
+INSERT INTO backup_logs.t2 VALUES ("03 Test #1 - progress");
+INSERT INTO backup_logs.t2 VALUES ("04 Test #1 - progress");
+INSERT INTO backup_logs.t2 VALUES ("05 Test #1 - progress");
+INSERT INTO backup_logs.t2 VALUES ("06 Test #1 - progress");
+INSERT INTO backup_logs.t3 VALUES ("01 Test #1 - progress");
+INSERT INTO backup_logs.t3 VALUES ("02 Test #1 - progress");
+INSERT INTO backup_logs.t3 VALUES ("03 Test #1 - progress");
+INSERT INTO backup_logs.t3 VALUES ("04 Test #1 - progress");
 Do backup of database
 con2: Activate sync points for the backup statement.
 SET DEBUG_SYNC= 'after_backup_log_init     SIGNAL started   WAIT_FOR do_run';
@@ -61,39 +60,46 @@ SET DEBUG_SYNC= 'after_backup_start_back
 SET DEBUG_SYNC= 'after_backup_validated    SIGNAL validated WAIT_FOR do_phase2';
 SET DEBUG_SYNC= 'after_backup_binlog       SIGNAL phase2    WAIT_FOR finish';
 con2: Send backup command.
-BACKUP DATABASE backup_progress to 'backup_progress_orig.bak';
+BACKUP DATABASE backup_logs to 'backup_logs_orig.bak';
 con1: Wait for the backup to be started.
 SET DEBUG_SYNC= 'now WAIT_FOR started';
 con1: Display progress
-SELECT MAX(backup_id) INTO @bup_id FROM mysql.online_backup WHERE command LIKE "BACKUP DATABASE backup_progress%";
-INSERT INTO backup_progress.t1_res (id) VALUES (@bup_id);
-SELECT backup_state FROM mysql.online_backup AS ob JOIN backup_progress.t1_res as t1 ON ob.backup_id = t1.id;
-backup_state
+SELECT MAX(backup_id) INTO @bup_id FROM mysql.backup_progress;
+INSERT INTO backup_logs.t1_res (id) VALUES (@bup_id);
+SELECT notes FROM mysql.backup_progress AS ob JOIN backup_logs.t1_res as t1 ON ob.backup_id = t1.id;
+notes
 starting
 con1: Let backup step to running state.
 SET DEBUG_SYNC= 'now SIGNAL do_run WAIT_FOR phase1';
 con1: Display progress
-SELECT backup_state FROM mysql.online_backup AS ob JOIN backup_progress.t1_res as t1 ON ob.backup_id = t1.id;
-backup_state
+SELECT notes FROM mysql.backup_progress AS ob JOIN backup_logs.t1_res as t1 ON ob.backup_id = t1.id;
+notes
+starting
 running
 con1: Let backup do the backup phase1.
 SET DEBUG_SYNC= 'now SIGNAL backup WAIT_FOR validated';
 con1: Display progress
-SELECT backup_state FROM mysql.online_backup AS ob JOIN backup_progress.t1_res as t1 ON ob.backup_id = t1.id;
-backup_state
+SELECT notes FROM mysql.backup_progress AS ob JOIN backup_logs.t1_res as t1 ON ob.backup_id = t1.id;
+notes
+starting
+running
 validity point
 con1: Let backup do the backup phase2.
 SET DEBUG_SYNC= 'now SIGNAL do_phase2 WAIT_FOR phase2';
 con1: Display progress
-SELECT backup_state FROM mysql.online_backup AS ob JOIN backup_progress.t1_res as t1 ON ob.backup_id = t1.id;
-backup_state
+SELECT notes FROM mysql.backup_progress AS ob JOIN backup_logs.t1_res as t1 ON ob.backup_id = t1.id;
+notes
+starting
+running
+validity point
+vp time
 running
 con1: Let backup finish.
 SET DEBUG_SYNC= 'now SIGNAL finish';
 con2: Finish backup command
 backup_id
 #
-SELECT ob.* FROM mysql.online_backup AS ob JOIN backup_progress.t1_res AS t1 ON ob.backup_id = t1.id;;
+SELECT ob.* FROM mysql.backup_history AS ob JOIN backup_logs.t1_res AS t1 ON ob.backup_id = t1.id;;
 backup_id	#
 process_id	#
 binlog_pos	#
@@ -110,47 +116,50 @@ host_or_server_name	localhost
 username	root
 backup_file	#
 user_comment	
-command	BACKUP DATABASE backup_progress to 'backup_progress_orig.bak'
+command	BACKUP DATABASE backup_logs to 'backup_logs_orig.bak'
 drivers	MyISAM, Default, Snapshot
-SELECT obp.* FROM mysql.online_backup_progress AS obp JOIN backup_progress.t1_res AS t1 ON obp.backup_id = t1.id;
+SELECT obp.* FROM mysql.backup_progress AS obp JOIN backup_logs.t1_res AS t1 ON obp.backup_id = t1.id;
 backup_id	object	start_time	stop_time	total_bytes	progress	error_num	notes
 #	backup kernel	#	#	0	0	0	starting
 #	backup kernel	#	#	0	0	0	running
 #	backup kernel	#	#	0	0	0	validity point
+#	backup kernel	#	#	0	0	0	vp time
 #	backup kernel	#	#	0	0	0	running
 #	backup kernel	#	#	0	0	0	complete
-Do restore of database
-DELETE FROM backup_progress.t1_res;
+DELETE FROM backup_logs.t1_res;
 con2: Activate sync points for the backup statement.
 SET DEBUG_SYNC= 'after_backup_log_init      SIGNAL started WAIT_FOR do_run';
 SET DEBUG_SYNC= 'after_backup_start_restore SIGNAL running WAIT_FOR finish';
 con2: Send restore command.
-RESTORE FROM 'backup_progress_orig.bak';
+RESTORE FROM 'backup_logs_orig.bak';
 con1: Wait for the restore to be started.
 SET DEBUG_SYNC= 'now WAIT_FOR started';
 con1: Display progress
-select * from backup_progress.t1_res;
+select * from backup_logs.t1_res;
 id
-SELECT MAX(backup_id) INTO @bup_id FROM mysql.online_backup WHERE command LIKE "RESTORE FROM%";
-INSERT INTO backup_progress.t1_res (id) VALUES (@bup_id);
-SELECT backup_state FROM mysql.online_backup AS ob JOIN backup_progress.t1_res as t1 ON ob.backup_id = t1.id;
-backup_state
+SELECT MAX(backup_id) INTO @bup_id FROM mysql.backup_progress;
+INSERT INTO backup_logs.t1_res (id) VALUES (@bup_id);
+SELECT notes FROM mysql.backup_progress AS ob JOIN backup_logs.t1_res as t1 ON ob.backup_id = t1.id;
+notes
 starting
 con1: Let restore step to running state.
 SET DEBUG_SYNC= 'now SIGNAL do_run WAIT_FOR running';
 con1: Display progress
-SELECT backup_state FROM mysql.online_backup AS ob JOIN backup_progress.t1_res as t1 ON ob.backup_id = t1.id;
-backup_state
+SELECT notes FROM mysql.backup_progress AS ob JOIN backup_logs.t1_res as t1 ON ob.backup_id = t1.id;
+notes
+starting
 running
 con1: Let restore do its job and finish.
 SET DEBUG_SYNC= 'now SIGNAL finish';
 con2: Finish restore command
 backup_id
 #
-DELETE FROM backup_progress.t1_res;
-SELECT MAX(backup_id) INTO @bup_id FROM mysql.online_backup WHERE command LIKE "RESTORE FROM%";
-INSERT INTO backup_progress.t1_res (id) VALUES (@bup_id);
-SELECT ob.* FROM mysql.online_backup AS ob JOIN backup_progress.t1_res AS t1 ON ob.backup_id = t1.id;;
+SET DEBUG_SYNC= 'now SIGNAL complete';
+SET DEBUG_SYNC= 'now WAIT_FOR complete';
+DELETE FROM backup_logs.t1_res;
+SELECT MAX(backup_id) INTO @bup_id FROM mysql.backup_history WHERE command LIKE "RESTORE FROM%";
+INSERT INTO backup_logs.t1_res (id) VALUES (@bup_id);
+SELECT ob.* FROM mysql.backup_history AS ob JOIN backup_logs.t1_res AS t1 ON ob.backup_id = t1.id;;
 backup_id	#
 process_id	#
 binlog_pos	#
@@ -167,12 +176,29 @@ host_or_server_name	localhost
 username	root
 backup_file	#
 user_comment	
-command	RESTORE FROM 'backup_progress_orig.bak'
+command	RESTORE FROM 'backup_logs_orig.bak'
 drivers	MyISAM, Default, Snapshot
-SELECT obp.* FROM mysql.online_backup_progress AS obp JOIN backup_progress.t1_res AS t1 ON obp.backup_id = t1.id;
+SELECT obp.* FROM mysql.backup_progress AS obp JOIN backup_logs.t1_res AS t1 ON obp.backup_id = t1.id;
 backup_id	object	start_time	stop_time	total_bytes	progress	error_num	notes
 #	backup kernel	#	#	0	0	0	starting
 #	backup kernel	#	#	0	0	0	running
 #	backup kernel	#	#	0	0	0	complete
-SET DEBUG_SYNC= 'reset';
-DROP DATABASE backup_progress;
+SET DEBUG_SYNC= 'RESET';
+SET SESSION debug="d,set_backup_id";
+BACKUP DATABASE backup_logs to 'backup_logs_orig.bak';
+backup_id
+500
+SET SESSION debug="d";
+The backup id for this command should be 501.
+BACKUP DATABASE backup_logs to 'backup_logs_orig.bak';
+backup_id
+501
+The backup id for this command should be 502.
+BACKUP DATABASE backup_logs to 'backup_logs_orig.bak';
+backup_id
+502
+The backup id for this command should be 503.
+BACKUP DATABASE backup_logs to 'backup_logs_orig.bak';
+backup_id
+503
+DROP DATABASE backup_logs;

=== added file 'mysql-test/r/backup_logs_output.result'
--- a/mysql-test/r/backup_logs_output.result	1970-01-01 00:00:00 +0000
+++ b/mysql-test/r/backup_logs_output.result	2008-08-21 15:56:17 +0000
@@ -0,0 +1,203 @@
+con1
+Display backup variables
+SHOW VARIABLES LIKE 'backup_history_log';
+Variable_name	Value
+backup_history_log	ON
+SHOW VARIABLES LIKE 'backup_progress_log';
+Variable_name	Value
+backup_progress_log	ON
+SHOW VARIABLES LIKE 'log_backup_output';
+Variable_name	Value
+log_backup_output	TABLE
+'---Checking backup logs when log_backup_output is NONE---'
+'---and the backup logs are turned off                 ---'
+SET @@global.log_backup_output = 'NONE';
+SET @@global.backup_history_log = 'OFF';
+SET @@global.backup_progress_log = 'OFF';
+Display backup variables
+SHOW VARIABLES LIKE 'backup_history_log';
+Variable_name	Value
+backup_history_log	OFF
+SHOW VARIABLES LIKE 'backup_progress_log';
+Variable_name	Value
+backup_progress_log	OFF
+SHOW VARIABLES LIKE 'log_backup_output';
+Variable_name	Value
+log_backup_output	NONE
+TRUNCATE TABLE mysql.backup_history;
+TRUNCATE TABLE mysql.backup_progress;
+Show the size of the logs
+SELECT count(*) FROM mysql.backup_history;
+count(*)
+0
+SELECT count(*) FROM mysql.backup_progress;
+count(*)
+0
+DROP DATABASE IF EXISTS bup_log;
+Create a database and back it up
+CREATE DATABASE bup_log;
+CREATE TABLE bup_log.t1(a INT);
+INSERT INTO bup_log.t1 VALUES (1), (2), (3);
+BACKUP DATABASE bup_log TO 'bup_log.bak';
+backup_id
+#
+Show the size of the logs
+SELECT count(*) FROM mysql.backup_history;
+count(*)
+0
+SELECT count(*) FROM mysql.backup_progress;
+count(*)
+0
+FLUSH BACKUP LOGS;
+'---Checking backup logs when log_backup_output is TABLE---'
+SET @@global.log_backup_output = 'TABLE';
+turning backup logs back on
+SET @@global.backup_history_log = 'ON';
+SET @@global.backup_progress_log = 'ON';
+Display backup variables
+SHOW VARIABLES LIKE 'backup_history_log';
+Variable_name	Value
+backup_history_log	ON
+SHOW VARIABLES LIKE 'backup_progress_log';
+Variable_name	Value
+backup_progress_log	ON
+SHOW VARIABLES LIKE 'log_backup_output';
+Variable_name	Value
+log_backup_output	TABLE
+TRUNCATE TABLE mysql.backup_history;
+TRUNCATE TABLE mysql.backup_progress;
+BACKUP DATABASE bup_log TO 'bup_log.bak';
+backup_id
+#
+Show the size of the logs
+SELECT count(*) FROM mysql.backup_history;
+count(*)
+1
+SELECT count(*) FROM mysql.backup_progress;
+count(*)
+6
+FLUSH BACKUP LOGS;
+'---Checking backup logs when log_backup_output is TABLE---'
+'---and the progress log is turned off                   ---'
+SET @@global.backup_history_log = 'ON';
+SET @@global.backup_progress_log = 'OFF';
+Display backup variables
+SHOW VARIABLES LIKE 'backup_history_log';
+Variable_name	Value
+backup_history_log	ON
+SHOW VARIABLES LIKE 'backup_progress_log';
+Variable_name	Value
+backup_progress_log	OFF
+SHOW VARIABLES LIKE 'log_backup_output';
+Variable_name	Value
+log_backup_output	TABLE
+TRUNCATE TABLE mysql.backup_history;
+TRUNCATE TABLE mysql.backup_progress;
+Show the size of the logs
+SELECT count(*) FROM mysql.backup_history;
+count(*)
+0
+SELECT count(*) FROM mysql.backup_progress;
+count(*)
+0
+BACKUP DATABASE bup_log TO 'bup_log.bak';
+backup_id
+#
+Show the size of the logs
+SELECT count(*) FROM mysql.backup_history;
+count(*)
+1
+SELECT count(*) FROM mysql.backup_progress;
+count(*)
+0
+FLUSH BACKUP LOGS;
+'---Checking backup logs when log_backup_output is TABLE---'
+'---and the history log is turned off                 ---'
+SET @@global.backup_history_log = 'OFF';
+SET @@global.backup_progress_log = 'ON';
+Display backup variables
+SHOW VARIABLES LIKE 'backup_history_log';
+Variable_name	Value
+backup_history_log	OFF
+SHOW VARIABLES LIKE 'backup_progress_log';
+Variable_name	Value
+backup_progress_log	ON
+SHOW VARIABLES LIKE 'log_backup_output';
+Variable_name	Value
+log_backup_output	TABLE
+TRUNCATE TABLE mysql.backup_history;
+TRUNCATE TABLE mysql.backup_progress;
+Show the size of the logs
+SELECT count(*) FROM mysql.backup_history;
+count(*)
+0
+SELECT count(*) FROM mysql.backup_progress;
+count(*)
+0
+BACKUP DATABASE bup_log TO 'bup_log.bak';
+backup_id
+#
+Show the size of the logs
+SELECT count(*) FROM mysql.backup_history;
+count(*)
+0
+SELECT count(*) FROM mysql.backup_progress;
+count(*)
+6
+FLUSH BACKUP LOGS;
+'---Checking backup logs when log_backup_output is FILE---'
+SET @@global.log_backup_output = 'FILE';
+turning backup logs back on
+SET @@global.backup_history_log = 'ON';
+SET @@global.backup_progress_log = 'ON';
+Display backup variables
+SHOW VARIABLES LIKE 'backup_history_log';
+Variable_name	Value
+backup_history_log	ON
+SHOW VARIABLES LIKE 'backup_progress_log';
+Variable_name	Value
+backup_progress_log	ON
+SHOW VARIABLES LIKE 'log_backup_output';
+Variable_name	Value
+log_backup_output	FILE
+TRUNCATE TABLE mysql.backup_history;
+TRUNCATE TABLE mysql.backup_progress;
+BACKUP DATABASE bup_log TO 'bup_log.bak';
+backup_id
+#
+Show the size of the logs
+SELECT count(*) FROM mysql.backup_history;
+count(*)
+0
+SELECT count(*) FROM mysql.backup_progress;
+count(*)
+0
+FLUSH BACKUP LOGS;
+'---Checking backup logs when log_backup_output is TABLE, FILE---'
+SET @@global.log_backup_output = 'TABLE,FILE';
+Display backup variables
+SHOW VARIABLES LIKE 'backup_history_log';
+Variable_name	Value
+backup_history_log	ON
+SHOW VARIABLES LIKE 'backup_progress_log';
+Variable_name	Value
+backup_progress_log	ON
+SHOW VARIABLES LIKE 'log_backup_output';
+Variable_name	Value
+log_backup_output	FILE,TABLE
+TRUNCATE TABLE mysql.backup_history;
+TRUNCATE TABLE mysql.backup_progress;
+BACKUP DATABASE bup_log TO 'bup_log.bak';
+backup_id
+#
+Show the size of the logs
+SELECT count(*) FROM mysql.backup_history;
+count(*)
+1
+SELECT count(*) FROM mysql.backup_progress;
+count(*)
+6
+FLUSH BACKUP LOGS;
+Cleanup
+DROP DATABASE bup_log;
+SET @@global.log_backup_output = 'TABLE';

=== modified file 'mysql-test/r/backup_no_be.result'
--- a/mysql-test/r/backup_no_be.result	2008-07-09 18:37:42 +0000
+++ b/mysql-test/r/backup_no_be.result	2008-08-21 15:56:17 +0000
@@ -12,9 +12,9 @@ backup_id
 #
 SHOW WARNINGS;
 Level	Code	Message
-SELECT max(backup_id) INTO @id FROM mysql.online_backup 
+SELECT max(backup_id) INTO @id FROM mysql.backup_history 
 WHERE command LIKE 'BACKUP DATABASE db1 %';
-SELECT drivers FROM mysql.online_backup WHERE backup_id=@id;
+SELECT drivers FROM mysql.backup_history WHERE backup_id=@id;
 drivers
 MyISAM
 SET SESSION debug="d,backup_test_dummy_be_factory";
@@ -27,9 +27,9 @@ backup_id
 SHOW WARNINGS;
 Level	Code	Message
 Warning	#	Cannot create backup engine for storage engine MyISAM
-SELECT max(backup_id) INTO @id FROM mysql.online_backup 
+SELECT max(backup_id) INTO @id FROM mysql.backup_history 
 WHERE command LIKE 'BACKUP DATABASE db1 %';
-SELECT drivers FROM mysql.online_backup WHERE backup_id=@id;
+SELECT drivers FROM mysql.backup_history WHERE backup_id=@id;
 drivers
 Default
 RESTORE FROM 'db1.bak';

=== modified file 'mysql-test/r/connect.result'
--- a/mysql-test/r/connect.result	2008-03-27 19:02:15 +0000
+++ b/mysql-test/r/connect.result	2008-08-21 15:56:17 +0000
@@ -1,6 +1,8 @@
 drop table if exists t1,t2;
 show tables;
 Tables_in_mysql
+backup_history
+backup_progress
 columns_priv
 db
 event
@@ -12,8 +14,6 @@ help_relation
 help_topic
 host
 ndb_binlog_index
-online_backup
-online_backup_progress
 plugin
 proc
 procs_priv
@@ -36,6 +36,8 @@ grant ALL on *.* to test@localhost ident
 grant ALL on *.* to test@stripped identified by "gambling";
 show tables;
 Tables_in_mysql
+backup_history
+backup_progress
 columns_priv
 db
 event
@@ -47,8 +49,6 @@ help_relation
 help_topic
 host
 ndb_binlog_index
-online_backup
-online_backup_progress
 plugin
 proc
 procs_priv
@@ -79,6 +79,8 @@ ERROR HY000: Password hash should be a 4
 set password=old_password('gambling3');
 show tables;
 Tables_in_mysql
+backup_history
+backup_progress
 columns_priv
 db
 event
@@ -90,8 +92,6 @@ help_relation
 help_topic
 host
 ndb_binlog_index
-online_backup
-online_backup_progress
 plugin
 proc
 procs_priv

=== modified file 'mysql-test/r/information_schema.result'
--- a/mysql-test/r/information_schema.result	2008-06-30 08:43:39 +0000
+++ b/mysql-test/r/information_schema.result	2008-08-21 15:56:17 +0000
@@ -68,6 +68,8 @@ TABLE_PRIVILEGES
 TRIGGERS
 USER_PRIVILEGES
 VIEWS
+backup_history
+backup_progress
 columns_priv
 db
 event
@@ -78,8 +80,6 @@ help_keyword
 help_relation
 help_topic
 host
-online_backup
-online_backup_progress
 plugin
 proc
 procs_priv
@@ -803,15 +803,15 @@ TABLES	CREATE_TIME	datetime
 TABLES	UPDATE_TIME	datetime
 TABLES	CHECK_TIME	datetime
 TRIGGERS	CREATED	datetime
+backup_history	validity_point_time	datetime
+backup_history	start_time	datetime
+backup_history	stop_time	datetime
+backup_progress	start_time	datetime
+backup_progress	stop_time	datetime
 event	execute_at	datetime
 event	last_executed	datetime
 event	starts	datetime
 event	ends	datetime
-online_backup	validity_point_time	datetime
-online_backup	start_time	datetime
-online_backup	stop_time	datetime
-online_backup_progress	start_time	datetime
-online_backup_progress	stop_time	datetime
 SELECT COUNT(*) FROM INFORMATION_SCHEMA.TABLES A
 WHERE NOT EXISTS 
 (SELECT * FROM INFORMATION_SCHEMA.COLUMNS B
@@ -1283,7 +1283,6 @@ select 1 as f1 from information_schema.t
 (select cast(table_name as char)  from information_schema.tables
 order by table_name limit 1) limit 1;
 f1
-1
 select t.table_name, group_concat(t.table_schema, '.', t.table_name),
 count(*) as num1
 from information_schema.tables t

=== modified file 'mysql-test/r/log_state.result'
--- a/mysql-test/r/log_state.result	2008-03-31 10:53:35 +0000
+++ b/mysql-test/r/log_state.result	2008-08-21 15:56:17 +0000
@@ -261,9 +261,11 @@ SET @slow_query_log_file_saved = @@globa
 SET GLOBAL general_log_file = 'bug32748.query.log';
 SET GLOBAL slow_query_log_file = 'bug32748.slow.log';
 
-SHOW VARIABLES LIKE '%log_file';
+show variables like 'general_log_file';
 Variable_name	Value
 general_log_file	bug32748.query.log
+show variables like 'slow_query_log_file';
+Variable_name	Value
 slow_query_log_file	bug32748.slow.log
 
 SET GLOBAL general_log_file = @general_log_file_saved;

=== modified file 'mysql-test/r/mysql_upgrade.result'
--- a/mysql-test/r/mysql_upgrade.result	2008-03-21 01:59:35 +0000
+++ b/mysql-test/r/mysql_upgrade.result	2008-08-21 15:56:17 +0000
@@ -1,4 +1,10 @@
 Run mysql_upgrade once
+mysql.backup_history
+Error    : You can't use locks with log tables.
+status   : OK
+mysql.backup_progress
+Error    : You can't use locks with log tables.
+status   : OK
 mysql.columns_priv                                 OK
 mysql.db                                           OK
 mysql.event                                        OK
@@ -12,12 +18,6 @@ mysql.help_relation                     
 mysql.help_topic                                   OK
 mysql.host                                         OK
 mysql.ndb_binlog_index                             OK
-mysql.online_backup
-Error    : You can't use locks with log tables.
-status   : OK
-mysql.online_backup_progress
-Error    : You can't use locks with log tables.
-status   : OK
 mysql.plugin                                       OK
 mysql.proc                                         OK
 mysql.procs_priv                                   OK
@@ -35,6 +35,12 @@ mysql.user                              
 Run it again - should say already completed
 This installation of MySQL is already upgraded to VERSION, use --force if you still need to run mysql_upgrade
 Force should run it regardless of wether it's been run before
+mysql.backup_history
+Error    : You can't use locks with log tables.
+status   : OK
+mysql.backup_progress
+Error    : You can't use locks with log tables.
+status   : OK
 mysql.columns_priv                                 OK
 mysql.db                                           OK
 mysql.event                                        OK
@@ -48,12 +54,6 @@ mysql.help_relation                     
 mysql.help_topic                                   OK
 mysql.host                                         OK
 mysql.ndb_binlog_index                             OK
-mysql.online_backup
-Error    : You can't use locks with log tables.
-status   : OK
-mysql.online_backup_progress
-Error    : You can't use locks with log tables.
-status   : OK
 mysql.plugin                                       OK
 mysql.proc                                         OK
 mysql.procs_priv                                   OK
@@ -71,6 +71,12 @@ mysql.user                              
 CREATE USER mysqltest1@'%' IDENTIFIED by 'sakila';
 GRANT ALL ON *.* TO mysqltest1@'%';
 Run mysql_upgrade with password protected account
+mysql.backup_history
+Error    : You can't use locks with log tables.
+status   : OK
+mysql.backup_progress
+Error    : You can't use locks with log tables.
+status   : OK
 mysql.columns_priv                                 OK
 mysql.db                                           OK
 mysql.event                                        OK
@@ -84,12 +90,6 @@ mysql.help_relation                     
 mysql.help_topic                                   OK
 mysql.host                                         OK
 mysql.ndb_binlog_index                             OK
-mysql.online_backup
-Error    : You can't use locks with log tables.
-status   : OK
-mysql.online_backup_progress
-Error    : You can't use locks with log tables.
-status   : OK
 mysql.plugin                                       OK
 mysql.proc                                         OK
 mysql.procs_priv                                   OK
@@ -109,6 +109,12 @@ Run mysql_upgrade with a non existing se
 mysqlcheck: Got error: 2005: Unknown MySQL server host 'not_existing_host' (errno) when trying to connect
 FATAL ERROR: Upgrade failed
 set GLOBAL sql_mode='STRICT_ALL_TABLES,ANSI_QUOTES,NO_ZERO_DATE';
+mysql.backup_history
+Error    : You can't use locks with log tables.
+status   : OK
+mysql.backup_progress
+Error    : You can't use locks with log tables.
+status   : OK
 mysql.columns_priv                                 OK
 mysql.db                                           OK
 mysql.event                                        OK
@@ -122,12 +128,6 @@ mysql.help_relation                     
 mysql.help_topic                                   OK
 mysql.host                                         OK
 mysql.ndb_binlog_index                             OK
-mysql.online_backup
-Error    : You can't use locks with log tables.
-status   : OK
-mysql.online_backup_progress
-Error    : You can't use locks with log tables.
-status   : OK
 mysql.plugin                                       OK
 mysql.proc                                         OK
 mysql.procs_priv                                   OK

=== modified file 'mysql-test/r/mysqlcheck.result'
--- a/mysql-test/r/mysqlcheck.result	2008-02-11 21:22:19 +0000
+++ b/mysql-test/r/mysqlcheck.result	2008-08-21 15:56:17 +0000
@@ -1,6 +1,10 @@
 DROP TABLE IF EXISTS t1, `t``1`, `t 1`;
 drop view if exists v1;
 drop database if exists client_test_db;
+mysql.backup_history
+note     : The storage engine for the table doesn't support optimize
+mysql.backup_progress
+note     : The storage engine for the table doesn't support optimize
 mysql.columns_priv                                 OK
 mysql.db                                           OK
 mysql.event                                        OK
@@ -13,8 +17,6 @@ mysql.help_relation                     
 mysql.help_topic                                   OK
 mysql.host                                         OK
 mysql.ndb_binlog_index                             OK
-mysql.online_backup                                OK
-mysql.online_backup_progress                       OK
 mysql.plugin                                       OK
 mysql.proc                                         OK
 mysql.procs_priv                                   OK
@@ -28,6 +30,10 @@ mysql.time_zone_name                    
 mysql.time_zone_transition                         OK
 mysql.time_zone_transition_type                    OK
 mysql.user                                         OK
+mysql.backup_history
+note     : The storage engine for the table doesn't support optimize
+mysql.backup_progress
+note     : The storage engine for the table doesn't support optimize
 mysql.columns_priv                                 OK
 mysql.db                                           OK
 mysql.event                                        OK
@@ -40,8 +46,6 @@ mysql.help_relation                     
 mysql.help_topic                                   OK
 mysql.host                                         OK
 mysql.ndb_binlog_index                             OK
-mysql.online_backup                                OK
-mysql.online_backup_progress                       OK
 mysql.plugin                                       OK
 mysql.proc                                         OK
 mysql.procs_priv                                   OK

=== modified file 'mysql-test/r/system_mysql_db.result'
--- a/mysql-test/r/system_mysql_db.result	2008-07-24 07:44:21 +0000
+++ b/mysql-test/r/system_mysql_db.result	2008-08-21 15:56:17 +0000
@@ -1,6 +1,8 @@
 drop table if exists t1,t1aa,t2aa;
 show tables;
 Tables_in_db
+backup_history
+backup_progress
 columns_priv
 db
 event
@@ -12,8 +14,6 @@ help_relation
 help_topic
 host
 ndb_binlog_index
-online_backup
-online_backup_progress
 plugin
 proc
 procs_priv

=== modified file 'mysql-test/suite/funcs_1/r/is_columns_mysql.result'
--- a/mysql-test/suite/funcs_1/r/is_columns_mysql.result	2008-08-14 08:48:35 +0000
+++ b/mysql-test/suite/funcs_1/r/is_columns_mysql.result	2008-08-21 15:56:17 +0000
@@ -2,6 +2,32 @@ SELECT * FROM information_schema.columns
 WHERE table_schema = 'mysql'
 ORDER BY table_schema, table_name, column_name;
 TABLE_CATALOG	TABLE_SCHEMA	TABLE_NAME	COLUMN_NAME	ORDINAL_POSITION	COLUMN_DEFAULT	IS_NULLABLE	DATA_TYPE	CHARACTER_MAXIMUM_LENGTH	CHARACTER_OCTET_LENGTH	NUMERIC_PRECISION	NUMERIC_SCALE	CHARACTER_SET_NAME	COLLATION_NAME	COLUMN_TYPE	COLUMN_KEY	EXTRA	PRIVILEGES	COLUMN_COMMENT	STORAGE	FORMAT
+NULL	mysql	backup_history	backup_file	15		NO	char	100	400	NULL	NULL	utf8	utf8_general_ci	char(100)			select,insert,update,references	The name of the file	Default	Default
+NULL	mysql	backup_history	backup_id	1	NULL	NO	bigint	NULL	NULL	19	0	NULL	NULL	bigint(20) unsigned			select,insert,update,references	Surrogate key for (near) duplicate entries	Default	Default
+NULL	mysql	backup_history	backup_state	5	NULL	NO	enum	14	56	NULL	NULL	utf8	utf8_general_ci	enum('complete','starting','validity point','running','error','cancel')			select,insert,update,references	Status of current operation	Default	Default
+NULL	mysql	backup_history	binlog_file	4		NO	char	64	256	NULL	NULL	utf8	utf8_general_ci	char(64)			select,insert,update,references	The recorded binlog filename at time of backup/restore	Default	Default
+NULL	mysql	backup_history	binlog_pos	3	0	NO	int	NULL	NULL	10	0	NULL	NULL	int(10) unsigned			select,insert,update,references	The recorded binlog position of backup/restore	Default	Default
+NULL	mysql	backup_history	command	17		NO	varchar	512	2048	NULL	NULL	utf8	utf8_general_ci	varchar(512)			select,insert,update,references	The command used to issue operation	Default	Default
+NULL	mysql	backup_history	drivers	18		NO	varchar	100	400	NULL	NULL	utf8	utf8_general_ci	varchar(100)			select,insert,update,references	The name of the storage engines used in the operation	Default	Default
+NULL	mysql	backup_history	error_num	7	0	NO	int	NULL	NULL	10	0	NULL	NULL	int(11)			select,insert,update,references	The error from this run 0 == none	Default	Default
+NULL	mysql	backup_history	host_or_server_name	13		NO	char	30	120	NULL	NULL	utf8	utf8_general_ci	char(30)			select,insert,update,references	The server name where operation ran	Default	Default
+NULL	mysql	backup_history	num_objects	8	0	NO	int	NULL	NULL	10	0	NULL	NULL	int(10) unsigned			select,insert,update,references	The number of objects in the backup	Default	Default
+NULL	mysql	backup_history	operation	6	NULL	NO	enum	7	28	NULL	NULL	utf8	utf8_general_ci	enum('backup','restore')			select,insert,update,references	Type of operation	Default	Default
+NULL	mysql	backup_history	process_id	2	NULL	NO	int	NULL	NULL	10	0	NULL	NULL	int(10) unsigned			select,insert,update,references	The process id that operation ran as	Default	Default
+NULL	mysql	backup_history	start_time	11	0000-00-00 00:00:00	NO	datetime	NULL	NULL	NULL	NULL	NULL	NULL	datetime			select,insert,update,references	The date/time of start of operation	Default	Default
+NULL	mysql	backup_history	stop_time	12	0000-00-00 00:00:00	NO	datetime	NULL	NULL	NULL	NULL	NULL	NULL	datetime			select,insert,update,references	The date/time of end of operation	Default	Default
+NULL	mysql	backup_history	total_bytes	9	0	NO	bigint	NULL	NULL	19	0	NULL	NULL	bigint(20) unsigned			select,insert,update,references	The size of the backup repository in bytes	Default	Default
+NULL	mysql	backup_history	username	14		NO	char	30	120	NULL	NULL	utf8	utf8_general_ci	char(30)			select,insert,update,references	The user name who ran the operation	Default	Default
+NULL	mysql	backup_history	user_comment	16		NO	varchar	200	800	NULL	NULL	utf8	utf8_general_ci	varchar(200)			select,insert,update,references	The comment from user entered at command line	Default	Default
+NULL	mysql	backup_history	validity_point_time	10	0000-00-00 00:00:00	NO	datetime	NULL	NULL	NULL	NULL	NULL	NULL	datetime			select,insert,update,references	The time of the validity point.	Default	Default
+NULL	mysql	backup_progress	backup_id	1	NULL	NO	bigint	NULL	NULL	19	0	NULL	NULL	bigint(20) unsigned			select,insert,update,references	Key for backup_history table entries	Default	Default
+NULL	mysql	backup_progress	error_num	7	0	NO	int	NULL	NULL	10	0	NULL	NULL	int(11)			select,insert,update,references	The error from this run 0 == none	Default	Default
+NULL	mysql	backup_progress	notes	8		NO	char	100	400	NULL	NULL	utf8	utf8_general_ci	char(100)			select,insert,update,references	Commentary from the backup engine	Default	Default
+NULL	mysql	backup_progress	object	2		NO	char	30	120	NULL	NULL	utf8	utf8_general_ci	char(30)			select,insert,update,references	The object being operated on	Default	Default
+NULL	mysql	backup_progress	progress	6	0	NO	bigint	NULL	NULL	19	0	NULL	NULL	bigint(20) unsigned			select,insert,update,references	The number of bytes processed	Default	Default
+NULL	mysql	backup_progress	start_time	3	0000-00-00 00:00:00	NO	datetime	NULL	NULL	NULL	NULL	NULL	NULL	datetime			select,insert,update,references	The date/time of start of operation	Default	Default
+NULL	mysql	backup_progress	stop_time	4	0000-00-00 00:00:00	NO	datetime	NULL	NULL	NULL	NULL	NULL	NULL	datetime			select,insert,update,references	The date/time of end of operation	Default	Default
+NULL	mysql	backup_progress	total_bytes	5	0	NO	bigint	NULL	NULL	19	0	NULL	NULL	bigint(20)			select,insert,update,references	The size of the object in bytes	Default	Default
 NULL	mysql	columns_priv	Column_name	5		NO	char	64	256	NULL	NULL	utf8	utf8_bin	char(64)	PRI		select,insert,update,references		Default	Default
 NULL	mysql	columns_priv	Column_priv	7		NO	set	31	124	NULL	NULL	utf8	utf8_general_ci	set('Select','Insert','Update','References')			select,insert,update,references		Default	Default
 NULL	mysql	columns_priv	Db	2		NO	char	64	256	NULL	NULL	utf8	utf8_bin	char(64)	PRI		select,insert,update,references		Default	Default
@@ -107,32 +133,6 @@ NULL	mysql	ndb_binlog_index	orig_server_
 NULL	mysql	ndb_binlog_index	Position	1	NULL	NO	bigint	NULL	NULL	19	0	NULL	NULL	bigint(20) unsigned			select,insert,update,references		Default	Default
 NULL	mysql	ndb_binlog_index	schemaops	7	NULL	NO	int	NULL	NULL	10	0	NULL	NULL	int(10) unsigned			select,insert,update,references		Default	Default
 NULL	mysql	ndb_binlog_index	updates	5	NULL	NO	int	NULL	NULL	10	0	NULL	NULL	int(10) unsigned			select,insert,update,references		Default	Default
-NULL	mysql	online_backup	backup_file	15	NULL	YES	char	100	400	NULL	NULL	utf8	utf8_general_ci	char(100)			select,insert,update,references	The name of the file	Default	Default
-NULL	mysql	online_backup	backup_id	1	NULL	NO	bigint	NULL	NULL	19	0	NULL	NULL	bigint(20) unsigned	PRI	auto_increment	select,insert,update,references	Surrogate key for (near) duplicate entries	Default	Default
-NULL	mysql	online_backup	backup_state	5	NULL	NO	enum	14	56	NULL	NULL	utf8	utf8_general_ci	enum('complete','starting','validity point','running','error','cancel')			select,insert,update,references	Status of current operation	Default	Default
-NULL	mysql	online_backup	binlog_file	4	NULL	YES	char	64	256	NULL	NULL	utf8	utf8_general_ci	char(64)			select,insert,update,references	The recorded binlog filename at time of backup/restore	Default	Default
-NULL	mysql	online_backup	binlog_pos	3	0	YES	int	NULL	NULL	10	0	NULL	NULL	int(10) unsigned			select,insert,update,references	The recorded binlog position of backup/restore	Default	Default
-NULL	mysql	online_backup	command	17	NULL	YES	varchar	512	2048	NULL	NULL	utf8	utf8_general_ci	varchar(512)			select,insert,update,references	The command used to issue operation	Default	Default
-NULL	mysql	online_backup	drivers	18	NULL	YES	varchar	100	400	NULL	NULL	utf8	utf8_general_ci	varchar(100)			select,insert,update,references	The name of the storage engine backup drivers used in the operation	Default	Default
-NULL	mysql	online_backup	error_num	7	0	NO	int	NULL	NULL	10	0	NULL	NULL	int(11)			select,insert,update,references	The error from this run 0 == none	Default	Default
-NULL	mysql	online_backup	host_or_server_name	13	NULL	YES	char	30	120	NULL	NULL	utf8	utf8_general_ci	char(30)			select,insert,update,references	The server name where operation ran	Default	Default
-NULL	mysql	online_backup	num_objects	8	0	NO	int	NULL	NULL	10	0	NULL	NULL	int(10) unsigned			select,insert,update,references	The number of objects in the backup	Default	Default
-NULL	mysql	online_backup	operation	6	NULL	NO	enum	7	28	NULL	NULL	utf8	utf8_general_ci	enum('backup','restore')			select,insert,update,references	Type of operation	Default	Default
-NULL	mysql	online_backup	process_id	2	NULL	NO	int	NULL	NULL	10	0	NULL	NULL	int(10) unsigned			select,insert,update,references	The process id that operation ran as	Default	Default
-NULL	mysql	online_backup	start_time	11	NULL	YES	datetime	NULL	NULL	NULL	NULL	NULL	NULL	datetime			select,insert,update,references	The date/time of start of operation	Default	Default
-NULL	mysql	online_backup	stop_time	12	NULL	YES	datetime	NULL	NULL	NULL	NULL	NULL	NULL	datetime			select,insert,update,references	The date/time of end of operation	Default	Default
-NULL	mysql	online_backup	total_bytes	9	NULL	YES	bigint	NULL	NULL	19	0	NULL	NULL	bigint(20) unsigned			select,insert,update,references	The size of the backup repository in bytes	Default	Default
-NULL	mysql	online_backup	username	14	NULL	YES	char	30	120	NULL	NULL	utf8	utf8_general_ci	char(30)			select,insert,update,references	The user name who ran the operation	Default	Default
-NULL	mysql	online_backup	user_comment	16	NULL	YES	varchar	200	800	NULL	NULL	utf8	utf8_general_ci	varchar(200)			select,insert,update,references	The comment from user entered at command line	Default	Default
-NULL	mysql	online_backup	validity_point_time	10	NULL	YES	datetime	NULL	NULL	NULL	NULL	NULL	NULL	datetime			select,insert,update,references	The time of the validity point.	Default	Default
-NULL	mysql	online_backup_progress	backup_id	1	NULL	NO	bigint	NULL	NULL	19	0	NULL	NULL	bigint(20) unsigned			select,insert,update,references	Key for online_backup table entries	Default	Default
-NULL	mysql	online_backup_progress	error_num	7	0	NO	int	NULL	NULL	10	0	NULL	NULL	int(11)			select,insert,update,references	The error from this run 0 == none	Default	Default
-NULL	mysql	online_backup_progress	notes	8	NULL	YES	char	100	400	NULL	NULL	utf8	utf8_general_ci	char(100)			select,insert,update,references	Commentary from the backup engine	Default	Default
-NULL	mysql	online_backup_progress	object	2	NULL	NO	char	30	120	NULL	NULL	utf8	utf8_general_ci	char(30)			select,insert,update,references	The object being operated on	Default	Default
-NULL	mysql	online_backup_progress	progress	6	NULL	YES	bigint	NULL	NULL	19	0	NULL	NULL	bigint(20) unsigned			select,insert,update,references	The number of bytes processed	Default	Default
-NULL	mysql	online_backup_progress	start_time	3	NULL	YES	datetime	NULL	NULL	NULL	NULL	NULL	NULL	datetime			select,insert,update,references	The date/time of start of operation	Default	Default
-NULL	mysql	online_backup_progress	stop_time	4	NULL	YES	datetime	NULL	NULL	NULL	NULL	NULL	NULL	datetime			select,insert,update,references	The date/time of end of operation	Default	Default
-NULL	mysql	online_backup_progress	total_bytes	5	NULL	YES	bigint	NULL	NULL	19	0	NULL	NULL	bigint(20)			select,insert,update,references	The size of the object in bytes	Default	Default
 NULL	mysql	plugin	dl	2		NO	char	128	512	NULL	NULL	utf8	utf8_bin	char(128)			select,insert,update,references		Default	Default
 NULL	mysql	plugin	name	1		NO	char	64	256	NULL	NULL	utf8	utf8_bin	char(64)	PRI		select,insert,update,references		Default	Default
 NULL	mysql	proc	body	11	NULL	NO	longblob	4294967295	4294967295	NULL	NULL	NULL	NULL	longblob			select,insert,update,references		Default	Default
@@ -209,6 +209,7 @@ NULL	mysql	user	Alter_priv	17	N	NO	enum	
 NULL	mysql	user	Alter_routine_priv	28	N	NO	enum	1	4	NULL	NULL	utf8	utf8_general_ci	enum('N','Y')			select,insert,update,references		Default	Default
 NULL	mysql	user	Create_priv	8	N	NO	enum	1	4	NULL	NULL	utf8	utf8_general_ci	enum('N','Y')			select,insert,update,references		Default	Default
 NULL	mysql	user	Create_routine_priv	27	N	NO	enum	1	4	NULL	NULL	utf8	utf8_general_ci	enum('N','Y')			select,insert,update,references		Default	Default
+NULL	mysql	user	Create_tablespace_priv	32	N	NO	enum	1	4	NULL	NULL	utf8	utf8_general_ci	enum('N','Y')			select,insert,update,references		Default	Default
 NULL	mysql	user	Create_tmp_table_priv	20	N	NO	enum	1	4	NULL	NULL	utf8	utf8_general_ci	enum('N','Y')			select,insert,update,references		Default	Default
 NULL	mysql	user	Create_user_priv	29	N	NO	enum	1	4	NULL	NULL	utf8	utf8_general_ci	enum('N','Y')			select,insert,update,references		Default	Default
 NULL	mysql	user	Create_view_priv	25	N	NO	enum	1	4	NULL	NULL	utf8	utf8_general_ci	enum('N','Y')			select,insert,update,references		Default	Default
@@ -222,10 +223,10 @@ NULL	mysql	user	Host	1		NO	char	60	240	N
 NULL	mysql	user	Index_priv	16	N	NO	enum	1	4	NULL	NULL	utf8	utf8_general_ci	enum('N','Y')			select,insert,update,references		Default	Default
 NULL	mysql	user	Insert_priv	5	N	NO	enum	1	4	NULL	NULL	utf8	utf8_general_ci	enum('N','Y')			select,insert,update,references		Default	Default
 NULL	mysql	user	Lock_tables_priv	21	N	NO	enum	1	4	NULL	NULL	utf8	utf8_general_ci	enum('N','Y')			select,insert,update,references		Default	Default
-NULL	mysql	user	max_connections	38	0	NO	int	NULL	NULL	10	0	NULL	NULL	int(11) unsigned			select,insert,update,references		Default	Default
-NULL	mysql	user	max_questions	36	0	NO	int	NULL	NULL	10	0	NULL	NULL	int(11) unsigned			select,insert,update,references		Default	Default
-NULL	mysql	user	max_updates	37	0	NO	int	NULL	NULL	10	0	NULL	NULL	int(11) unsigned			select,insert,update,references		Default	Default
-NULL	mysql	user	max_user_connections	39	0	NO	int	NULL	NULL	10	0	NULL	NULL	int(11) unsigned			select,insert,update,references		Default	Default
+NULL	mysql	user	max_connections	39	0	NO	int	NULL	NULL	10	0	NULL	NULL	int(11) unsigned			select,insert,update,references		Default	Default
+NULL	mysql	user	max_questions	37	0	NO	int	NULL	NULL	10	0	NULL	NULL	int(11) unsigned			select,insert,update,references		Default	Default
+NULL	mysql	user	max_updates	38	0	NO	int	NULL	NULL	10	0	NULL	NULL	int(11) unsigned			select,insert,update,references		Default	Default
+NULL	mysql	user	max_user_connections	40	0	NO	int	NULL	NULL	10	0	NULL	NULL	int(11) unsigned			select,insert,update,references		Default	Default
 NULL	mysql	user	Password	3		NO	char	41	41	NULL	NULL	latin1	latin1_bin	char(41)			select,insert,update,references		Default	Default
 NULL	mysql	user	Process_priv	12	N	NO	enum	1	4	NULL	NULL	utf8	utf8_general_ci	enum('N','Y')			select,insert,update,references		Default	Default
 NULL	mysql	user	References_priv	15	N	NO	enum	1	4	NULL	NULL	utf8	utf8_general_ci	enum('N','Y')			select,insert,update,references		Default	Default
@@ -236,14 +237,14 @@ NULL	mysql	user	Select_priv	4	N	NO	enum	
 NULL	mysql	user	Show_db_priv	18	N	NO	enum	1	4	NULL	NULL	utf8	utf8_general_ci	enum('N','Y')			select,insert,update,references		Default	Default
 NULL	mysql	user	Show_view_priv	26	N	NO	enum	1	4	NULL	NULL	utf8	utf8_general_ci	enum('N','Y')			select,insert,update,references		Default	Default
 NULL	mysql	user	Shutdown_priv	11	N	NO	enum	1	4	NULL	NULL	utf8	utf8_general_ci	enum('N','Y')			select,insert,update,references		Default	Default
-NULL	mysql	user	ssl_cipher	33	NULL	NO	blob	65535	65535	NULL	NULL	NULL	NULL	blob			select,insert,update,references		Default	Default
-NULL	mysql	user	ssl_type	32		NO	enum	9	36	NULL	NULL	utf8	utf8_general_ci	enum('','ANY','X509','SPECIFIED')			select,insert,update,references		Default	Default
+NULL	mysql	user	ssl_cipher	34	NULL	NO	blob	65535	65535	NULL	NULL	NULL	NULL	blob			select,insert,update,references		Default	Default
+NULL	mysql	user	ssl_type	33		NO	enum	9	36	NULL	NULL	utf8	utf8_general_ci	enum('','ANY','X509','SPECIFIED')			select,insert,update,references		Default	Default
 NULL	mysql	user	Super_priv	19	N	NO	enum	1	4	NULL	NULL	utf8	utf8_general_ci	enum('N','Y')			select,insert,update,references		Default	Default
 NULL	mysql	user	Trigger_priv	31	N	NO	enum	1	4	NULL	NULL	utf8	utf8_general_ci	enum('N','Y')			select,insert,update,references		Default	Default
 NULL	mysql	user	Update_priv	6	N	NO	enum	1	4	NULL	NULL	utf8	utf8_general_ci	enum('N','Y')			select,insert,update,references		Default	Default
 NULL	mysql	user	User	2		NO	char	16	64	NULL	NULL	utf8	utf8_bin	char(16)	PRI		select,insert,update,references		Default	Default
-NULL	mysql	user	x509_issuer	34	NULL	NO	blob	65535	65535	NULL	NULL	NULL	NULL	blob			select,insert,update,references		Default	Default
-NULL	mysql	user	x509_subject	35	NULL	NO	blob	65535	65535	NULL	NULL	NULL	NULL	blob			select,insert,update,references		Default	Default
+NULL	mysql	user	x509_issuer	35	NULL	NO	blob	65535	65535	NULL	NULL	NULL	NULL	blob			select,insert,update,references		Default	Default
+NULL	mysql	user	x509_subject	36	NULL	NO	blob	65535	65535	NULL	NULL	NULL	NULL	blob			select,insert,update,references		Default	Default
 ##########################################################################
 # Show the quotient of CHARACTER_OCTET_LENGTH and CHARACTER_MAXIMUM_LENGTH
 ##########################################################################
@@ -313,6 +314,32 @@ FROM information_schema.columns
 WHERE table_schema = 'mysql'
 ORDER BY TABLE_SCHEMA, TABLE_NAME, ORDINAL_POSITION;
 COL_CML	TABLE_SCHEMA	TABLE_NAME	COLUMN_NAME	DATA_TYPE	CHARACTER_MAXIMUM_LENGTH	CHARACTER_OCTET_LENGTH	CHARACTER_SET_NAME	COLLATION_NAME	COLUMN_TYPE
+NULL	mysql	backup_history	backup_id	bigint	NULL	NULL	NULL	NULL	bigint(20) unsigned
+NULL	mysql	backup_history	process_id	int	NULL	NULL	NULL	NULL	int(10) unsigned
+NULL	mysql	backup_history	binlog_pos	int	NULL	NULL	NULL	NULL	int(10) unsigned
+4.0000	mysql	backup_history	binlog_file	char	64	256	utf8	utf8_general_ci	char(64)
+4.0000	mysql	backup_history	backup_state	enum	14	56	utf8	utf8_general_ci	enum('complete','starting','validity point','running','error','cancel')
+4.0000	mysql	backup_history	operation	enum	7	28	utf8	utf8_general_ci	enum('backup','restore')
+NULL	mysql	backup_history	error_num	int	NULL	NULL	NULL	NULL	int(11)
+NULL	mysql	backup_history	num_objects	int	NULL	NULL	NULL	NULL	int(10) unsigned
+NULL	mysql	backup_history	total_bytes	bigint	NULL	NULL	NULL	NULL	bigint(20) unsigned
+NULL	mysql	backup_history	validity_point_time	datetime	NULL	NULL	NULL	NULL	datetime
+NULL	mysql	backup_history	start_time	datetime	NULL	NULL	NULL	NULL	datetime
+NULL	mysql	backup_history	stop_time	datetime	NULL	NULL	NULL	NULL	datetime
+4.0000	mysql	backup_history	host_or_server_name	char	30	120	utf8	utf8_general_ci	char(30)
+4.0000	mysql	backup_history	username	char	30	120	utf8	utf8_general_ci	char(30)
+4.0000	mysql	backup_history	backup_file	char	100	400	utf8	utf8_general_ci	char(100)
+4.0000	mysql	backup_history	user_comment	varchar	200	800	utf8	utf8_general_ci	varchar(200)
+4.0000	mysql	backup_history	command	varchar	512	2048	utf8	utf8_general_ci	varchar(512)
+4.0000	mysql	backup_history	drivers	varchar	100	400	utf8	utf8_general_ci	varchar(100)
+NULL	mysql	backup_progress	backup_id	bigint	NULL	NULL	NULL	NULL	bigint(20) unsigned
+4.0000	mysql	backup_progress	object	char	30	120	utf8	utf8_general_ci	char(30)
+NULL	mysql	backup_progress	start_time	datetime	NULL	NULL	NULL	NULL	datetime
+NULL	mysql	backup_progress	stop_time	datetime	NULL	NULL	NULL	NULL	datetime
+NULL	mysql	backup_progress	total_bytes	bigint	NULL	NULL	NULL	NULL	bigint(20)
+NULL	mysql	backup_progress	progress	bigint	NULL	NULL	NULL	NULL	bigint(20) unsigned
+NULL	mysql	backup_progress	error_num	int	NULL	NULL	NULL	NULL	int(11)
+4.0000	mysql	backup_progress	notes	char	100	400	utf8	utf8_general_ci	char(100)
 4.0000	mysql	columns_priv	Host	char	60	240	utf8	utf8_bin	char(60)
 4.0000	mysql	columns_priv	Db	char	64	256	utf8	utf8_bin	char(64)
 4.0000	mysql	columns_priv	User	char	16	64	utf8	utf8_bin	char(16)
@@ -418,32 +445,6 @@ NULL	mysql	ndb_binlog_index	schemaops	in
 NULL	mysql	ndb_binlog_index	orig_server_id	int	NULL	NULL	NULL	NULL	int(10) unsigned
 NULL	mysql	ndb_binlog_index	orig_epoch	bigint	NULL	NULL	NULL	NULL	bigint(20) unsigned
 NULL	mysql	ndb_binlog_index	gci	int	NULL	NULL	NULL	NULL	int(10) unsigned
-NULL	mysql	online_backup	backup_id	bigint	NULL	NULL	NULL	NULL	bigint(20) unsigned
-NULL	mysql	online_backup	process_id	int	NULL	NULL	NULL	NULL	int(10) unsigned
-NULL	mysql	online_backup	binlog_pos	int	NULL	NULL	NULL	NULL	int(10) unsigned
-4.0000	mysql	online_backup	binlog_file	char	64	256	utf8	utf8_general_ci	char(64)
-4.0000	mysql	online_backup	backup_state	enum	14	56	utf8	utf8_general_ci	enum('complete','starting','validity point','running','error','cancel')
-4.0000	mysql	online_backup	operation	enum	7	28	utf8	utf8_general_ci	enum('backup','restore')
-NULL	mysql	online_backup	error_num	int	NULL	NULL	NULL	NULL	int(11)
-NULL	mysql	online_backup	num_objects	int	NULL	NULL	NULL	NULL	int(10) unsigned
-NULL	mysql	online_backup	total_bytes	bigint	NULL	NULL	NULL	NULL	bigint(20) unsigned
-NULL	mysql	online_backup	validity_point_time	datetime	NULL	NULL	NULL	NULL	datetime
-NULL	mysql	online_backup	start_time	datetime	NULL	NULL	NULL	NULL	datetime
-NULL	mysql	online_backup	stop_time	datetime	NULL	NULL	NULL	NULL	datetime
-4.0000	mysql	online_backup	host_or_server_name	char	30	120	utf8	utf8_general_ci	char(30)
-4.0000	mysql	online_backup	username	char	30	120	utf8	utf8_general_ci	char(30)
-4.0000	mysql	online_backup	backup_file	char	100	400	utf8	utf8_general_ci	char(100)
-4.0000	mysql	online_backup	user_comment	varchar	200	800	utf8	utf8_general_ci	varchar(200)
-4.0000	mysql	online_backup	command	varchar	512	2048	utf8	utf8_general_ci	varchar(512)
-4.0000	mysql	online_backup	drivers	varchar	100	400	utf8	utf8_general_ci	varchar(100)
-NULL	mysql	online_backup_progress	backup_id	bigint	NULL	NULL	NULL	NULL	bigint(20) unsigned
-4.0000	mysql	online_backup_progress	object	char	30	120	utf8	utf8_general_ci	char(30)
-NULL	mysql	online_backup_progress	start_time	datetime	NULL	NULL	NULL	NULL	datetime
-NULL	mysql	online_backup_progress	stop_time	datetime	NULL	NULL	NULL	NULL	datetime
-NULL	mysql	online_backup_progress	total_bytes	bigint	NULL	NULL	NULL	NULL	bigint(20)
-NULL	mysql	online_backup_progress	progress	bigint	NULL	NULL	NULL	NULL	bigint(20) unsigned
-NULL	mysql	online_backup_progress	error_num	int	NULL	NULL	NULL	NULL	int(11)
-4.0000	mysql	online_backup_progress	notes	char	100	400	utf8	utf8_general_ci	char(100)
 4.0000	mysql	plugin	name	char	64	256	utf8	utf8_bin	char(64)
 4.0000	mysql	plugin	dl	char	128	512	utf8	utf8_bin	char(128)
 4.0000	mysql	proc	db	char	64	256	utf8	utf8_bin	char(64)
@@ -547,6 +548,7 @@ NULL	mysql	time_zone_transition_type	Is_
 4.0000	mysql	user	Create_user_priv	enum	1	4	utf8	utf8_general_ci	enum('N','Y')
 4.0000	mysql	user	Event_priv	enum	1	4	utf8	utf8_general_ci	enum('N','Y')
 4.0000	mysql	user	Trigger_priv	enum	1	4	utf8	utf8_general_ci	enum('N','Y')
+4.0000	mysql	user	Create_tablespace_priv	enum	1	4	utf8	utf8_general_ci	enum('N','Y')
 4.0000	mysql	user	ssl_type	enum	9	36	utf8	utf8_general_ci	enum('','ANY','X509','SPECIFIED')
 1.0000	mysql	user	ssl_cipher	blob	65535	65535	NULL	NULL	blob
 1.0000	mysql	user	x509_issuer	blob	65535	65535	NULL	NULL	blob

=== modified file 'mysql-test/suite/funcs_1/r/is_statistics_mysql.result'
--- a/mysql-test/suite/funcs_1/r/is_statistics_mysql.result	2008-03-10 19:00:02 +0000
+++ b/mysql-test/suite/funcs_1/r/is_statistics_mysql.result	2008-08-21 15:56:17 +0000
@@ -32,7 +32,6 @@ NULL	mysql	host	0	mysql	PRIMARY	2	Db	A	#
 NULL	mysql	ndb_binlog_index	0	mysql	PRIMARY	1	epoch	A	#CARD#	NULL	NULL		BTREE		
 NULL	mysql	ndb_binlog_index	0	mysql	PRIMARY	2	orig_server_id	A	#CARD#	NULL	NULL		BTREE		
 NULL	mysql	ndb_binlog_index	0	mysql	PRIMARY	3	orig_epoch	A	#CARD#	NULL	NULL		BTREE		
-NULL	mysql	online_backup	0	mysql	PRIMARY	1	backup_id	A	#CARD#	NULL	NULL		BTREE		
 NULL	mysql	plugin	0	mysql	PRIMARY	1	name	A	#CARD#	NULL	NULL		BTREE		
 NULL	mysql	proc	0	mysql	PRIMARY	1	db	A	#CARD#	NULL	NULL		BTREE		
 NULL	mysql	proc	0	mysql	PRIMARY	2	name	A	#CARD#	NULL	NULL		BTREE		

=== modified file 'mysql-test/suite/funcs_1/r/is_table_constraints_mysql.result'
--- a/mysql-test/suite/funcs_1/r/is_table_constraints_mysql.result	2008-03-10 19:00:02 +0000
+++ b/mysql-test/suite/funcs_1/r/is_table_constraints_mysql.result	2008-08-21 15:56:17 +0000
@@ -20,7 +20,6 @@ NULL	mysql	name	mysql	help_topic	UNIQUE
 NULL	mysql	PRIMARY	mysql	help_topic	PRIMARY KEY
 NULL	mysql	PRIMARY	mysql	host	PRIMARY KEY
 NULL	mysql	PRIMARY	mysql	ndb_binlog_index	PRIMARY KEY
-NULL	mysql	PRIMARY	mysql	online_backup	PRIMARY KEY
 NULL	mysql	PRIMARY	mysql	plugin	PRIMARY KEY
 NULL	mysql	PRIMARY	mysql	proc	PRIMARY KEY
 NULL	mysql	PRIMARY	mysql	procs_priv	PRIMARY KEY

=== modified file 'mysql-test/suite/funcs_1/r/is_tables_mysql.result'
--- a/mysql-test/suite/funcs_1/r/is_tables_mysql.result	2008-08-14 14:07:27 +0000
+++ b/mysql-test/suite/funcs_1/r/is_tables_mysql.result	2008-08-21 15:56:17 +0000
@@ -75,15 +75,15 @@ AUTO_INCREMENT	NULL
 CREATE_TIME	#CRT#
 UPDATE_TIME	#UT#
 CHECK_TIME	#CT#
-TABLE_COLLATION	utf8_general_ci
+TABLE_COLLATION	utf8_bin
 CHECKSUM	NULL
 CREATE_OPTIONS	#CO#
 TABLE_COMMENT	#TC#
-user_comment	Events
+user_comment	Column privileges
 Separator	-----------------------------------------------------
 TABLE_CATALOG	NULL
 TABLE_SCHEMA	mysql
-TABLE_NAME	func
+TABLE_NAME	db
 TABLE_TYPE	BASE TABLE
 ENGINE	MYISAM_OR_MARIA
 VERSION	10
@@ -102,13 +102,13 @@ TABLE_COLLATION	utf8_bin
 CHECKSUM	NULL
 CREATE_OPTIONS	#CO#
 TABLE_COMMENT	#TC#
-user_comment	User defined functions
+user_comment	Database privileges
 Separator	-----------------------------------------------------
 TABLE_CATALOG	NULL
 TABLE_SCHEMA	mysql
-TABLE_NAME	general_log
+TABLE_NAME	event
 TABLE_TYPE	BASE TABLE
-ENGINE	CSV
+ENGINE	MyISAM
 VERSION	10
 ROW_FORMAT	DYNAMIC_OR_PAGE
 TABLE_ROWS	#TBLR#
@@ -125,11 +125,11 @@ TABLE_COLLATION	utf8_general_ci
 CHECKSUM	NULL
 CREATE_OPTIONS	#CO#
 TABLE_COMMENT	#TC#
-user_comment	General log
+user_comment	Events
 Separator	-----------------------------------------------------
 TABLE_CATALOG	NULL
 TABLE_SCHEMA	mysql
-TABLE_NAME	help_category
+TABLE_NAME	func
 TABLE_TYPE	BASE TABLE
 ENGINE	MYISAM_OR_MARIA
 VERSION	10
@@ -171,11 +171,11 @@ TABLE_COLLATION	utf8_general_ci
 CHECKSUM	NULL
 CREATE_OPTIONS	#CO#
 TABLE_COMMENT	#TC#
-user_comment	help keywords
+user_comment	General log
 Separator	-----------------------------------------------------
 TABLE_CATALOG	NULL
 TABLE_SCHEMA	mysql
-TABLE_NAME	help_relation
+TABLE_NAME	help_category
 TABLE_TYPE	BASE TABLE
 ENGINE	MYISAM_OR_MARIA
 VERSION	10
@@ -217,11 +217,11 @@ TABLE_COLLATION	utf8_general_ci
 CHECKSUM	NULL
 CREATE_OPTIONS	#CO#
 TABLE_COMMENT	#TC#
-user_comment	help topics
+user_comment	help keywords
 Separator	-----------------------------------------------------
 TABLE_CATALOG	NULL
 TABLE_SCHEMA	mysql
-TABLE_NAME	host
+TABLE_NAME	help_relation
 TABLE_TYPE	BASE TABLE
 ENGINE	MYISAM_OR_MARIA
 VERSION	10
@@ -236,15 +236,15 @@ AUTO_INCREMENT	NULL
 CREATE_TIME	#CRT#
 UPDATE_TIME	#UT#
 CHECK_TIME	#CT#
-TABLE_COLLATION	utf8_bin
+TABLE_COLLATION	utf8_general_ci
 CHECKSUM	NULL
 CREATE_OPTIONS	#CO#
 TABLE_COMMENT	#TC#
-user_comment	Host privileges;  Merged with database privileges
+user_comment	keyword-topic relation
 Separator	-----------------------------------------------------
 TABLE_CATALOG	NULL
 TABLE_SCHEMA	mysql
-TABLE_NAME	ndb_binlog_index
+TABLE_NAME	help_topic
 TABLE_TYPE	BASE TABLE
 ENGINE	MYISAM_OR_MARIA
 VERSION	10

=== modified file 'mysql-test/t/backup_errors.test'
--- a/mysql-test/t/backup_errors.test	2008-08-21 11:36:09 +0000
+++ b/mysql-test/t/backup_errors.test	2008-08-21 15:56:17 +0000
@@ -162,8 +162,8 @@ BACKUP DATABASE mysql, information_schem
 
 # Make backup copies of the tables first.
 --echo Making copies of progress tables.
-CREATE TABLE IF NOT EXISTS test.ob_copy LIKE mysql.online_backup;
-CREATE TABLE IF NOT EXISTS test.obp_copy LIKE mysql.online_backup_progress;
+CREATE TABLE IF NOT EXISTS test.ob_copy LIKE mysql.backup_history;
+CREATE TABLE IF NOT EXISTS test.obp_copy LIKE mysql.backup_progress;
 
 # Create a database and put some data in it.
 CREATE DATABASE test_ob_error;
@@ -177,7 +177,7 @@ BACKUP DATABASE test_ob_error TO 'ob_err
 --remove_file $MYSQLTEST_VARDIR/master-data/ob_err.bak
 
 # Drop one of the tables and try a backup.
-DROP TABLE mysql.online_backup;
+DROP TABLE mysql.backup_history;
 
 # Try to backup the database (should be error).
 --echo Backup the database;
@@ -190,11 +190,11 @@ SHOW ERRORS;
 
 # Restore the table
 --echo Restoring the table
-CREATE TABLE mysql.online_backup LIKE test.ob_copy;
+CREATE TABLE mysql.backup_history LIKE test.ob_copy;
 DROP TABLE test.ob_copy;
 
 # Drop one of the tables and try a backup.
-DROP TABLE mysql.online_backup_progress;
+DROP TABLE mysql.backup_progress;
 
 # Try to backup the database (should be error).
 --echo Backup the database;
@@ -207,7 +207,7 @@ SHOW ERRORS;
 
 # Restore the table
 --echo Restoring the table
-CREATE TABLE mysql.online_backup_progress LIKE test.obp_copy;
+CREATE TABLE mysql.backup_progress LIKE test.obp_copy;
 DROP TABLE test.obp_copy;
 
 DROP DATABASE test_ob_error;

=== renamed file 'mysql-test/t/backup_progress.test' => 'mysql-test/t/backup_logs.test'
--- a/mysql-test/t/backup_progress.test	2008-08-08 17:21:31 +0000
+++ b/mysql-test/t/backup_logs.test	2008-08-21 15:56:17 +0000
@@ -7,6 +7,9 @@
 --source include/have_debug_sync.inc
 --source include/have_innodb.inc
 --source include/not_embedded.inc
+--source include/have_debug.inc
+
+SET DEBUG_SYNC= 'RESET';
 
 # bug#33836 backup tables should have charset utf8
 
@@ -16,7 +19,7 @@
 
 SELECT column_name, character_set_name 
 FROM information_schema.columns 
-WHERE table_name LIKE 'online_backup' 
+WHERE table_name LIKE 'backup_history' 
   AND character_set_name LIKE 'utf8' 
 ORDER BY column_name;
 
@@ -24,7 +27,7 @@ ORDER BY column_name;
 
 SELECT column_name, character_set_name 
 FROM information_schema.columns 
-WHERE table_name LIKE 'online_backup_progress' 
+WHERE table_name LIKE 'backup_progress' 
   AND character_set_name LIKE 'utf8' 
 ORDER BY column_name;
 
@@ -36,11 +39,9 @@ ORDER BY column_name;
 # Preparative cleanup.
 #
 --disable_warnings
-SET DEBUG_SYNC= 'reset';
-DROP DATABASE IF EXISTS backup_progress;
-DROP TABLE IF EXISTS backup_progress.t1_res;
+DROP DATABASE IF EXISTS backup_logs;
 --error 0,1
---remove_file $MYSQLTEST_VARDIR/master-data/backup_progress_orig.bak;
+--remove_file $MYSQLTEST_VARDIR/master-data/backup_logs_orig.bak;
 --enable_warnings
 
 connect (con1,localhost,root,,);
@@ -52,34 +53,34 @@ connect (con2,localhost,root,,);
 
 connection con1;
 
-CREATE DATABASE backup_progress;
+CREATE DATABASE backup_logs;
 
 --echo con1: Create table and new users.
 
-CREATE TABLE backup_progress.t1 (a char(30)) ENGINE=MYISAM;
-CREATE TABLE backup_progress.t2 (a char(30)) ENGINE=INNODB;
-CREATE TABLE backup_progress.t3 (a char(30)) ENGINE=MEMORY;
-CREATE TABLE backup_progress.t1_res (id INT) ENGINE=MEMORY;
-
-INSERT INTO backup_progress.t1 VALUES ("01 Test #1 - progress"); 
-INSERT INTO backup_progress.t1 VALUES ("02 Test #1 - progress"); 
-INSERT INTO backup_progress.t1 VALUES ("03 Test #1 - progress"); 
-INSERT INTO backup_progress.t1 VALUES ("04 Test #1 - progress"); 
-INSERT INTO backup_progress.t1 VALUES ("05 Test #1 - progress"); 
-INSERT INTO backup_progress.t1 VALUES ("06 Test #1 - progress"); 
-INSERT INTO backup_progress.t1 VALUES ("07 Test #1 - progress"); 
-
-INSERT INTO backup_progress.t2 VALUES ("01 Test #1 - progress"); 
-INSERT INTO backup_progress.t2 VALUES ("02 Test #1 - progress"); 
-INSERT INTO backup_progress.t2 VALUES ("03 Test #1 - progress"); 
-INSERT INTO backup_progress.t2 VALUES ("04 Test #1 - progress"); 
-INSERT INTO backup_progress.t2 VALUES ("05 Test #1 - progress"); 
-INSERT INTO backup_progress.t2 VALUES ("06 Test #1 - progress"); 
-
-INSERT INTO backup_progress.t3 VALUES ("01 Test #1 - progress"); 
-INSERT INTO backup_progress.t3 VALUES ("02 Test #1 - progress"); 
-INSERT INTO backup_progress.t3 VALUES ("03 Test #1 - progress"); 
-INSERT INTO backup_progress.t3 VALUES ("04 Test #1 - progress"); 
+CREATE TABLE backup_logs.t1 (a char(30)) ENGINE=MYISAM;
+CREATE TABLE backup_logs.t2 (a char(30)) ENGINE=INNODB;
+CREATE TABLE backup_logs.t3 (a char(30)) ENGINE=MEMORY;
+CREATE TABLE backup_logs.t1_res (id INT) ENGINE=MEMORY;
+
+INSERT INTO backup_logs.t1 VALUES ("01 Test #1 - progress"); 
+INSERT INTO backup_logs.t1 VALUES ("02 Test #1 - progress"); 
+INSERT INTO backup_logs.t1 VALUES ("03 Test #1 - progress"); 
+INSERT INTO backup_logs.t1 VALUES ("04 Test #1 - progress"); 
+INSERT INTO backup_logs.t1 VALUES ("05 Test #1 - progress"); 
+INSERT INTO backup_logs.t1 VALUES ("06 Test #1 - progress"); 
+INSERT INTO backup_logs.t1 VALUES ("07 Test #1 - progress"); 
+
+INSERT INTO backup_logs.t2 VALUES ("01 Test #1 - progress"); 
+INSERT INTO backup_logs.t2 VALUES ("02 Test #1 - progress"); 
+INSERT INTO backup_logs.t2 VALUES ("03 Test #1 - progress"); 
+INSERT INTO backup_logs.t2 VALUES ("04 Test #1 - progress"); 
+INSERT INTO backup_logs.t2 VALUES ("05 Test #1 - progress"); 
+INSERT INTO backup_logs.t2 VALUES ("06 Test #1 - progress"); 
+
+INSERT INTO backup_logs.t3 VALUES ("01 Test #1 - progress"); 
+INSERT INTO backup_logs.t3 VALUES ("02 Test #1 - progress"); 
+INSERT INTO backup_logs.t3 VALUES ("03 Test #1 - progress"); 
+INSERT INTO backup_logs.t3 VALUES ("04 Test #1 - progress"); 
 
 --echo Do backup of database
 
@@ -92,7 +93,7 @@ SET DEBUG_SYNC= 'after_backup_validated 
 SET DEBUG_SYNC= 'after_backup_binlog       SIGNAL phase2    WAIT_FOR finish';
 
 --echo con2: Send backup command.
-send BACKUP DATABASE backup_progress to 'backup_progress_orig.bak';
+send BACKUP DATABASE backup_logs to 'backup_logs_orig.bak';
 
 connection con1;
 
@@ -100,27 +101,27 @@ connection con1;
 SET DEBUG_SYNC= 'now WAIT_FOR started';
 
 --echo con1: Display progress
-SELECT MAX(backup_id) INTO @bup_id FROM mysql.online_backup WHERE command LIKE "BACKUP DATABASE backup_progress%";
-INSERT INTO backup_progress.t1_res (id) VALUES (@bup_id);
-SELECT backup_state FROM mysql.online_backup AS ob JOIN backup_progress.t1_res as t1 ON ob.backup_id = t1.id;
+SELECT MAX(backup_id) INTO @bup_id FROM mysql.backup_progress;
+INSERT INTO backup_logs.t1_res (id) VALUES (@bup_id);
+SELECT notes FROM mysql.backup_progress AS ob JOIN backup_logs.t1_res as t1 ON ob.backup_id = t1.id;
 
 --echo con1: Let backup step to running state.
 SET DEBUG_SYNC= 'now SIGNAL do_run WAIT_FOR phase1';
 
 --echo con1: Display progress
-SELECT backup_state FROM mysql.online_backup AS ob JOIN backup_progress.t1_res as t1 ON ob.backup_id = t1.id;
+SELECT notes FROM mysql.backup_progress AS ob JOIN backup_logs.t1_res as t1 ON ob.backup_id = t1.id;
 
 --echo con1: Let backup do the backup phase1.
 SET DEBUG_SYNC= 'now SIGNAL backup WAIT_FOR validated';
 
 --echo con1: Display progress
-SELECT backup_state FROM mysql.online_backup AS ob JOIN backup_progress.t1_res as t1 ON ob.backup_id = t1.id;
+SELECT notes FROM mysql.backup_progress AS ob JOIN backup_logs.t1_res as t1 ON ob.backup_id = t1.id;
 
 --echo con1: Let backup do the backup phase2.
 SET DEBUG_SYNC= 'now SIGNAL do_phase2 WAIT_FOR phase2';
 
 --echo con1: Display progress
-SELECT backup_state FROM mysql.online_backup AS ob JOIN backup_progress.t1_res as t1 ON ob.backup_id = t1.id;
+SELECT notes FROM mysql.backup_progress AS ob JOIN backup_logs.t1_res as t1 ON ob.backup_id = t1.id;
 
 --echo con1: Let backup finish.
 SET DEBUG_SYNC= 'now SIGNAL finish';
@@ -130,26 +131,24 @@ connection con2;
 --replace_column 1 #
 reap;
 
+connection con1;
+
 #Show results
 --replace_column 1 # 2 # 3 # 4 # 10 # 11 # 12 # 15 #
---query_vertical SELECT ob.* FROM mysql.online_backup AS ob JOIN backup_progress.t1_res AS t1 ON ob.backup_id = t1.id;
+--query_vertical SELECT ob.* FROM mysql.backup_history AS ob JOIN backup_logs.t1_res AS t1 ON ob.backup_id = t1.id;
 --replace_column 1 # 3 # 4 #
-SELECT obp.* FROM mysql.online_backup_progress AS obp JOIN backup_progress.t1_res AS t1 ON obp.backup_id = t1.id;
-
-connection con1;
-
---echo Do restore of database
+SELECT obp.* FROM mysql.backup_progress AS obp JOIN backup_logs.t1_res AS t1 ON obp.backup_id = t1.id;
 
+DELETE FROM backup_logs.t1_res;
+ 
 connection con2;
 
-DELETE FROM backup_progress.t1_res;
- 
 --echo con2: Activate sync points for the backup statement.
 SET DEBUG_SYNC= 'after_backup_log_init      SIGNAL started WAIT_FOR do_run';
 SET DEBUG_SYNC= 'after_backup_start_restore SIGNAL running WAIT_FOR finish';
 
 --echo con2: Send restore command.
-send RESTORE FROM 'backup_progress_orig.bak';
+send RESTORE FROM 'backup_logs_orig.bak';
 
 connection con1;
 
@@ -157,16 +156,16 @@ connection con1;
 SET DEBUG_SYNC= 'now WAIT_FOR started';
 
 --echo con1: Display progress
-select * from backup_progress.t1_res;
-SELECT MAX(backup_id) INTO @bup_id FROM mysql.online_backup WHERE command LIKE "RESTORE FROM%";
-INSERT INTO backup_progress.t1_res (id) VALUES (@bup_id);
-SELECT backup_state FROM mysql.online_backup AS ob JOIN backup_progress.t1_res as t1 ON ob.backup_id = t1.id;
+select * from backup_logs.t1_res;
+SELECT MAX(backup_id) INTO @bup_id FROM mysql.backup_progress;
+INSERT INTO backup_logs.t1_res (id) VALUES (@bup_id);
+SELECT notes FROM mysql.backup_progress AS ob JOIN backup_logs.t1_res as t1 ON ob.backup_id = t1.id;
 
 --echo con1: Let restore step to running state.
 SET DEBUG_SYNC= 'now SIGNAL do_run WAIT_FOR running';
 
 --echo con1: Display progress
-SELECT backup_state FROM mysql.online_backup AS ob JOIN backup_progress.t1_res as t1 ON ob.backup_id = t1.id;
+SELECT notes FROM mysql.backup_progress AS ob JOIN backup_logs.t1_res as t1 ON ob.backup_id = t1.id;
 
 --echo con1: Let restore do its job and finish.
 SET DEBUG_SYNC= 'now SIGNAL finish';
@@ -176,21 +175,53 @@ connection con2;
 --replace_column 1 #
 reap;
 
+SET DEBUG_SYNC= 'now SIGNAL complete';
+
+connection con1;
+
+SET DEBUG_SYNC= 'now WAIT_FOR complete';
+
 #Show results
-DELETE FROM backup_progress.t1_res;
-SELECT MAX(backup_id) INTO @bup_id FROM mysql.online_backup WHERE command LIKE "RESTORE FROM%";
-INSERT INTO backup_progress.t1_res (id) VALUES (@bup_id);
+DELETE FROM backup_logs.t1_res;
+SELECT MAX(backup_id) INTO @bup_id FROM mysql.backup_history WHERE command LIKE "RESTORE FROM%";
+INSERT INTO backup_logs.t1_res (id) VALUES (@bup_id);
 --replace_column 1 # 2 # 3 # 4 # 10 # 11 # 12 # 15 #
---query_vertical SELECT ob.* FROM mysql.online_backup AS ob JOIN backup_progress.t1_res AS t1 ON ob.backup_id = t1.id;
+--query_vertical SELECT ob.* FROM mysql.backup_history AS ob JOIN backup_logs.t1_res AS t1 ON ob.backup_id = t1.id;
 --replace_column 1 # 3 # 4 #
-SELECT obp.* FROM mysql.online_backup_progress AS obp JOIN backup_progress.t1_res AS t1 ON obp.backup_id = t1.id;
+SELECT obp.* FROM mysql.backup_progress AS obp JOIN backup_logs.t1_res AS t1 ON obp.backup_id = t1.id;
 
-connection con1;
+SET DEBUG_SYNC= 'RESET';
+
+#
+# Now test read of backupid with known id using debug insertion
+#
+SET SESSION debug="d,set_backup_id";
+
+--remove_file $MYSQLTEST_VARDIR/master-data/backup_logs_orig.bak
+
+#
+# The first backup will cause the value to be set to 500 and written to file.
+# The second backup will read the value (500) and increment it.
+#--replace_column 1 #
+BACKUP DATABASE backup_logs to 'backup_logs_orig.bak';
+
+SET SESSION debug="d";
+
+--remove_file $MYSQLTEST_VARDIR/master-data/backup_logs_orig.bak
+--echo The backup id for this command should be 501.
+BACKUP DATABASE backup_logs to 'backup_logs_orig.bak';
+
+--remove_file $MYSQLTEST_VARDIR/master-data/backup_logs_orig.bak
+--echo The backup id for this command should be 502.
+BACKUP DATABASE backup_logs to 'backup_logs_orig.bak';
+
+--remove_file $MYSQLTEST_VARDIR/master-data/backup_logs_orig.bak
+--echo The backup id for this command should be 503.
+BACKUP DATABASE backup_logs to 'backup_logs_orig.bak';
 
 #
 # Cleanup.
 #
-SET DEBUG_SYNC= 'reset';
-DROP DATABASE backup_progress;
---remove_file $MYSQLTEST_VARDIR/master-data/backup_progress_orig.bak
+DROP DATABASE backup_logs;
+--remove_file $MYSQLTEST_VARDIR/master-data/backup_logs_orig.bak
 

=== added file 'mysql-test/t/backup_logs_output.test'
--- a/mysql-test/t/backup_logs_output.test	1970-01-01 00:00:00 +0000
+++ b/mysql-test/t/backup_logs_output.test	2008-08-21 15:56:17 +0000
@@ -0,0 +1,239 @@
+#
+# Test backup log output options
+#
+# This test tests the --log-backup-output options for writing backup log
+# information. The choices are FILE | TABLE | FILE,TABLE | NONE
+#
+
+--source include/not_embedded.inc
+
+connect (con1,localhost,root,,,,);
+--echo con1
+connection con1;
+
+--echo Display backup variables
+SHOW VARIABLES LIKE 'backup_history_log';
+SHOW VARIABLES LIKE 'backup_progress_log';
+SHOW VARIABLES LIKE 'log_backup_output';
+
+--echo '---Checking backup logs when log_backup_output is NONE---'
+--echo '---and the backup logs are turned off                 ---'
+
+SET @@global.log_backup_output = 'NONE';
+SET @@global.backup_history_log = 'OFF';
+SET @@global.backup_progress_log = 'OFF';
+
+--echo Display backup variables
+SHOW VARIABLES LIKE 'backup_history_log';
+SHOW VARIABLES LIKE 'backup_progress_log';
+SHOW VARIABLES LIKE 'log_backup_output';
+
+TRUNCATE TABLE mysql.backup_history;
+TRUNCATE TABLE mysql.backup_progress;
+
+--echo Show the size of the logs
+SELECT count(*) FROM mysql.backup_history;
+SELECT count(*) FROM mysql.backup_progress;
+
+--disable_warnings
+DROP DATABASE IF EXISTS bup_log;
+--enable_warnings
+
+--echo Create a database and back it up
+CREATE DATABASE bup_log;
+CREATE TABLE bup_log.t1(a INT);
+INSERT INTO bup_log.t1 VALUES (1), (2), (3);
+
+--replace_column 1 #
+BACKUP DATABASE bup_log TO 'bup_log.bak';
+
+--echo Show the size of the logs
+SELECT count(*) FROM mysql.backup_history;
+SELECT count(*) FROM mysql.backup_progress;
+
+FLUSH BACKUP LOGS;
+--file_exists $MYSQLTEST_VARDIR/master-data/backup_history.log
+--file_exists $MYSQLTEST_VARDIR/master-data/backup_progress.log
+
+--error 0,1
+--remove_file $MYSQLTEST_VARDIR/master-data/bup_log.bak
+
+--echo '---Checking backup logs when log_backup_output is TABLE---'
+
+SET @@global.log_backup_output = 'TABLE';
+
+--echo turning backup logs back on
+SET @@global.backup_history_log = 'ON';
+SET @@global.backup_progress_log = 'ON';
+
+--echo Display backup variables
+SHOW VARIABLES LIKE 'backup_history_log';
+SHOW VARIABLES LIKE 'backup_progress_log';
+SHOW VARIABLES LIKE 'log_backup_output';
+
+TRUNCATE TABLE mysql.backup_history;
+TRUNCATE TABLE mysql.backup_progress;
+
+--replace_column 1 #
+BACKUP DATABASE bup_log TO 'bup_log.bak';
+
+--echo Show the size of the logs
+SELECT count(*) FROM mysql.backup_history;
+SELECT count(*) FROM mysql.backup_progress;
+
+FLUSH BACKUP LOGS;
+--file_exists $MYSQLTEST_VARDIR/master-data/backup_history.log
+--file_exists $MYSQLTEST_VARDIR/master-data/backup_progress.log
+
+--error 0,1
+--remove_file $MYSQLTEST_VARDIR/master-data/bup_log.bak
+
+--echo '---Checking backup logs when log_backup_output is TABLE---'
+--echo '---and the progress log is turned off                   ---'
+
+SET @@global.backup_history_log = 'ON';
+SET @@global.backup_progress_log = 'OFF';
+
+--echo Display backup variables
+SHOW VARIABLES LIKE 'backup_history_log';
+SHOW VARIABLES LIKE 'backup_progress_log';
+SHOW VARIABLES LIKE 'log_backup_output';
+
+TRUNCATE TABLE mysql.backup_history;
+TRUNCATE TABLE mysql.backup_progress;
+
+--echo Show the size of the logs
+SELECT count(*) FROM mysql.backup_history;
+SELECT count(*) FROM mysql.backup_progress;
+
+--replace_column 1 #
+BACKUP DATABASE bup_log TO 'bup_log.bak';
+
+--echo Show the size of the logs
+SELECT count(*) FROM mysql.backup_history;
+SELECT count(*) FROM mysql.backup_progress;
+
+FLUSH BACKUP LOGS;
+--file_exists $MYSQLTEST_VARDIR/master-data/backup_history.log
+--file_exists $MYSQLTEST_VARDIR/master-data/backup_progress.log
+
+--error 0,1
+--remove_file $MYSQLTEST_VARDIR/master-data/bup_log.bak
+
+--echo '---Checking backup logs when log_backup_output is TABLE---'
+--echo '---and the history log is turned off                 ---'
+
+SET @@global.backup_history_log = 'OFF';
+SET @@global.backup_progress_log = 'ON';
+
+--echo Display backup variables
+SHOW VARIABLES LIKE 'backup_history_log';
+SHOW VARIABLES LIKE 'backup_progress_log';
+SHOW VARIABLES LIKE 'log_backup_output';
+
+TRUNCATE TABLE mysql.backup_history;
+TRUNCATE TABLE mysql.backup_progress;
+
+--echo Show the size of the logs
+SELECT count(*) FROM mysql.backup_history;
+SELECT count(*) FROM mysql.backup_progress;
+
+--replace_column 1 #
+BACKUP DATABASE bup_log TO 'bup_log.bak';
+
+--echo Show the size of the logs
+SELECT count(*) FROM mysql.backup_history;
+SELECT count(*) FROM mysql.backup_progress;
+
+FLUSH BACKUP LOGS;
+--file_exists $MYSQLTEST_VARDIR/master-data/backup_history.log
+--file_exists $MYSQLTEST_VARDIR/master-data/backup_progress.log
+
+--error 0,1
+--remove_file $MYSQLTEST_VARDIR/master-data/bup_log.bak
+
+--echo '---Checking backup logs when log_backup_output is FILE---'
+
+SET @@global.log_backup_output = 'FILE';
+
+--echo turning backup logs back on
+SET @@global.backup_history_log = 'ON';
+SET @@global.backup_progress_log = 'ON';
+
+--echo Display backup variables
+SHOW VARIABLES LIKE 'backup_history_log';
+SHOW VARIABLES LIKE 'backup_progress_log';
+SHOW VARIABLES LIKE 'log_backup_output';
+
+TRUNCATE TABLE mysql.backup_history;
+TRUNCATE TABLE mysql.backup_progress;
+
+--replace_column 1 #
+BACKUP DATABASE bup_log TO 'bup_log.bak';
+
+--echo Show the size of the logs
+SELECT count(*) FROM mysql.backup_history;
+SELECT count(*) FROM mysql.backup_progress;
+
+FLUSH BACKUP LOGS;
+--file_exists $MYSQLTEST_VARDIR/master-data/backup_history.log
+--file_exists $MYSQLTEST_VARDIR/master-data/backup_progress.log
+
+# Check contents of logs for data. 
+--error 0
+--exec grep -q "BACKUP DATABASE bup_log TO 'bup_log.bak'" $MYSQLTEST_VARDIR/master-data/backup_history.log
+--error 0
+--exec grep -q "complete" $MYSQLTEST_VARDIR/master-data/backup_progress.log
+
+--error 0,1
+--remove_file $MYSQLTEST_VARDIR/master-data/bup_log.bak
+
+--echo '---Checking backup logs when log_backup_output is TABLE, FILE---'
+
+SET @@global.log_backup_output = 'TABLE,FILE';
+
+--echo Display backup variables
+SHOW VARIABLES LIKE 'backup_history_log';
+SHOW VARIABLES LIKE 'backup_progress_log';
+SHOW VARIABLES LIKE 'log_backup_output';
+
+TRUNCATE TABLE mysql.backup_history;
+TRUNCATE TABLE mysql.backup_progress;
+
+#
+# BUG#33364 - uncomment when implemented
+#
+# Purge the backup logs
+#PURGE BACKUP LOGS;
+
+--replace_column 1 #
+BACKUP DATABASE bup_log TO 'bup_log.bak';
+
+--echo Show the size of the logs
+SELECT count(*) FROM mysql.backup_history;
+SELECT count(*) FROM mysql.backup_progress;
+
+FLUSH BACKUP LOGS;
+--file_exists $MYSQLTEST_VARDIR/master-data/backup_history.log
+--file_exists $MYSQLTEST_VARDIR/master-data/backup_progress.log
+
+#
+# BUG#33364 - uncomment when implemented
+#
+# Check contents of logs for data. 
+#--error 0
+#--exec grep -q "BACKUP DATABASE bup_log TO 'bup_log.bak'" $MYSQLTEST_VARDIR/master-data/backup_history.log
+#--error 0
+#--exec grep -q "complete" $MYSQLTEST_VARDIR/master-data/backup_progress.log
+
+--error 0,1
+--remove_file $MYSQLTEST_VARDIR/master-data/bup_log.bak
+
+--echo Cleanup
+DROP DATABASE bup_log;
+
+SET @@global.log_backup_output = 'TABLE';
+
+--error 0,1
+--remove_file $MYSQLTEST_VARDIR/master-data/bup_log.bak
+

=== modified file 'mysql-test/t/backup_no_be.test'
--- a/mysql-test/t/backup_no_be.test	2008-07-09 18:37:42 +0000
+++ b/mysql-test/t/backup_no_be.test	2008-08-21 15:56:17 +0000
@@ -8,7 +8,7 @@
 # Test uses error injection activated with 'backup_test_dummy_be_factory' keyword.
 # The code is injected into has_native_backup() function in backup_info.cc.
 # When activated, it overwrites the native MyISAM backup factory with a dummy one 
-# which never creates an engine. This change is permanent and can not be reversed by 
+# which never creates a driver. This change is permanent and can not be reversed by 
 # disabling the error injection code. The only way to restore the original situation 
 # is by restarting the server. Therefore:
 #
@@ -44,14 +44,14 @@ SHOW WARNINGS;
 
 # See what engines were used for BACKUP
 
-SELECT max(backup_id) INTO @id FROM mysql.online_backup 
+SELECT max(backup_id) INTO @id FROM mysql.backup_history 
 WHERE command LIKE 'BACKUP DATABASE db1 %';
 
 # Note: right now default engine will be used (as below) because there is no
 # native backup for MyISAM. But when it is added, the SELECT below should list native 
 # MYISAM engine.
 
-SELECT drivers FROM mysql.online_backup WHERE backup_id=@id;
+SELECT drivers FROM mysql.backup_history WHERE backup_id=@id;
 
 # Now see what happens when injected code is activated and MyISAM uses the dummy
 # factory function.
@@ -60,7 +60,7 @@ SET SESSION debug="d,backup_test_dummy_b
 SELECT @@debug;
 
 # The following BACKUP command should generate a warning but otherwise
-# should complete using the default backup engine.
+# should complete using the default backup driver.
 # We disable warnings temporarily and show them with SHOW WARNINGS instead. This is to 
 # avoid showing message codes (which change sometimes)
 
@@ -76,10 +76,10 @@ SHOW WARNINGS;
 
 # See what engines were used for BACKUP
 
-SELECT max(backup_id) INTO @id FROM mysql.online_backup 
+SELECT max(backup_id) INTO @id FROM mysql.backup_history 
 WHERE command LIKE 'BACKUP DATABASE db1 %';
 
-SELECT drivers FROM mysql.online_backup WHERE backup_id=@id;
+SELECT drivers FROM mysql.backup_history WHERE backup_id=@id;
 
 # check that we can restore from the created image.
 

=== modified file 'mysql-test/t/log_state.test'
--- a/mysql-test/t/log_state.test	2008-03-31 10:53:35 +0000
+++ b/mysql-test/t/log_state.test	2008-08-21 15:56:17 +0000
@@ -248,7 +248,8 @@ SET GLOBAL general_log_file = 'bug32748.
 SET GLOBAL slow_query_log_file = 'bug32748.slow.log';
 
 --echo
-SHOW VARIABLES LIKE '%log_file';
+show variables like 'general_log_file';
+show variables like 'slow_query_log_file';
 
 --echo
 SET GLOBAL general_log_file = @general_log_file_saved;

=== modified file 'mysql-test/t/mysqldump.test'
--- a/mysql-test/t/mysqldump.test	2008-06-28 11:00:59 +0000
+++ b/mysql-test/t/mysqldump.test	2008-08-21 15:56:17 +0000
@@ -1382,7 +1382,7 @@ insert into u1 values (4);
 create view v1 (c1) as select * from t1;
 
 # Backup should not fail for Bug #21527. Flush priviliges test begins.
---exec $MYSQL_DUMP --skip-comments --add-drop-table --flush-privileges --ignore-table=mysql.general_log --ignore-table=mysql.slow_log --ignore-table=mysql.online_backup --ignore-table=mysql.online_backup_progress --databases mysqldump_myDB mysql > $MYSQLTEST_VARDIR/tmp/bug21527.sql
+--exec $MYSQL_DUMP --skip-comments --add-drop-table --flush-privileges --ignore-table=mysql.general_log --ignore-table=mysql.slow_log --ignore-table=mysql.backup_history --ignore-table=mysql.backup_progress --databases mysqldump_myDB mysql > $MYSQLTEST_VARDIR/tmp/bug21527.sql
 
 # Clean up
 connection root;

=== modified file 'mysql-test/t/system_mysql_db_fix30020.test'
--- a/mysql-test/t/system_mysql_db_fix30020.test	2007-11-30 06:02:04 +0000
+++ b/mysql-test/t/system_mysql_db_fix30020.test	2008-08-21 15:56:17 +0000
@@ -102,7 +102,7 @@ DROP TABLE db, host, user, func, plugin,
 procs_priv, servers, help_category, help_keyword, help_relation, help_topic, proc,
 time_zone, time_zone_leap_second, time_zone_name, time_zone_transition,
 time_zone_transition_type, general_log, slow_log, event, ndb_binlog_index,
-online_backup, online_backup_progress;
+backup_history, backup_progress;
 
 -- enable_query_log
 

=== modified file 'mysql-test/t/system_mysql_db_fix40123.test'
--- a/mysql-test/t/system_mysql_db_fix40123.test	2007-11-30 06:04:31 +0000
+++ b/mysql-test/t/system_mysql_db_fix40123.test	2008-08-21 15:56:17 +0000
@@ -76,7 +76,7 @@ CREATE TABLE time_zone_leap_second (   T
 -- disable_query_log
 
 # Drop all tables created by this test
-DROP TABLE db, host, user, func, plugin, tables_priv, columns_priv, procs_priv, servers, help_category, help_keyword, help_relation, help_topic, proc, time_zone, time_zone_leap_second, time_zone_name, time_zone_transition, time_zone_transition_type, general_log, slow_log, event, ndb_binlog_index, online_backup, online_backup_progress;
+DROP TABLE db, host, user, func, plugin, tables_priv, columns_priv, procs_priv, servers, help_category, help_keyword, help_relation, help_topic, proc, time_zone, time_zone_leap_second, time_zone_name, time_zone_transition, time_zone_transition_type, general_log, slow_log, event, ndb_binlog_index, backup_history, backup_progress;
 
 -- enable_query_log
 

=== modified file 'mysql-test/t/system_mysql_db_fix50030.test'
--- a/mysql-test/t/system_mysql_db_fix50030.test	2008-07-21 03:55:09 +0000
+++ b/mysql-test/t/system_mysql_db_fix50030.test	2008-08-21 15:56:17 +0000
@@ -82,7 +82,7 @@ INSERT INTO servers VALUES ('test','loca
 -- disable_query_log
 
 # Drop all tables created by this test
-DROP TABLE db, host, user, func, plugin, tables_priv, columns_priv, procs_priv, servers, help_category, help_keyword, help_relation, help_topic, proc, time_zone, time_zone_leap_second, time_zone_name, time_zone_transition, time_zone_transition_type, general_log, slow_log, event, ndb_binlog_index, online_backup, online_backup_progress;
+DROP TABLE db, host, user, func, plugin, tables_priv, columns_priv, procs_priv, servers, help_category, help_keyword, help_relation, help_topic, proc, time_zone, time_zone_leap_second, time_zone_name, time_zone_transition, time_zone_transition_type, general_log, slow_log, event, ndb_binlog_index, backup_history, backup_progress;
 
 -- enable_query_log
 

=== modified file 'mysql-test/t/system_mysql_db_fix50117.test'
--- a/mysql-test/t/system_mysql_db_fix50117.test	2008-07-21 03:55:09 +0000
+++ b/mysql-test/t/system_mysql_db_fix50117.test	2008-08-21 15:56:17 +0000
@@ -101,7 +101,7 @@ CREATE TABLE IF NOT EXISTS ndb_binlog_in
 -- disable_query_log
 
 # Drop all tables created by this test
-DROP TABLE db, host, user, func, plugin, tables_priv, columns_priv, procs_priv, servers, help_category, help_keyword, help_relation, help_topic, proc, time_zone, time_zone_leap_second, time_zone_name, time_zone_transition, time_zone_transition_type, general_log, slow_log, event, ndb_binlog_index, online_backup, online_backup_progress;
+DROP TABLE db, host, user, func, plugin, tables_priv, columns_priv, procs_priv, servers, help_category, help_keyword, help_relation, help_topic, proc, time_zone, time_zone_leap_second, time_zone_name, time_zone_transition, time_zone_transition_type, general_log, slow_log, event, ndb_binlog_index, backup_history, backup_progress;
 
 -- enable_query_log
 

Thread
bzr commit into mysql-6.0-backup branch (cbell:2681) WL#4296Chuck Bell21 Aug
  • Re: bzr commit into mysql-6.0-backup branch (cbell:2681) WL#4296Øystein Grøvlen27 Aug
    • RE: bzr commit into mysql-6.0-backup branch (cbell:2681) WL#4296Chuck Bell27 Aug
      • RE: bzr commit into mysql-6.0-backup branch (cbell:2681) WL#4296Vladislav Vaintroub27 Aug
      • Re: bzr commit into mysql-6.0-backup branch (cbell:2681) WL#4296Øystein Grøvlen28 Aug
        • RE: bzr commit into mysql-6.0-backup branch (cbell:2681) WL#4296Chuck Bell28 Aug
    • RE: bzr commit into mysql-6.0-backup branch (cbell:2681) WL#4296Chuck Bell27 Aug
      • Re: bzr commit into mysql-6.0-backup branch (cbell:2681) WL#4296Øystein Grøvlen28 Aug
    • RE: bzr commit into mysql-6.0-backup branch (cbell:2681) WL#4296Chuck Bell27 Aug