Code review comment for lp:~sergei.glushchenko/percona-xtrabackup/xb-tools

Revision history for this message
Sergei Glushchenko (sergei.glushchenko) wrote :

I did some testing of entry points in xtrabackup and here are my findings:

In 'backup' mode:
Page printer fails. In order for it to work following initialization should be done first:
 buf_pool_init();
 dict_ind_init();
 dict_boot(FALSE);
 dict_check_tablespaces_and_store_max_id(FALSE);
and IBUF should initialized in order to print IBUF pages
Log printer also fails.
 recv_sys_create()
is needed.

In 'prepare' mode:
For page printer to work:
 dict_ind_init();
 dict_boot(FALSE);
 dict_check_tablespaces_and_store_max_id(FALSE);
Log printer work just fine

In 'stats' mode:
Both page and log printers work OK.

I don't think we should initialize all these systems every time when running xtrabackup. However it would be nice to make log and page printers more useable inside xtrabackup. Maybe we should make some initialization function for these tools which used could call from gdb before using log or page printer.

I also found that by making create_new_db flag meaningful breaks second '--prepare' run (in open_or_create_log_file). XtraBackup doesn't create new log files because of when datafiles been found, create_new_db=FALSE is passed. So I reverted a change with create_new_db.

« Back to merge proposal