summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVlad Lesin <vlad_lesin@mail.ru>2020-05-12 13:57:09 +0300
committerVlad Lesin <vlad_lesin@mail.ru>2020-05-12 18:44:36 +0300
commit218d20ffe3d4e833eb20a75d880fec1c1507b221 (patch)
treea8f9971d9eb01e30ee9c357247e01493ddc6c7b4
parent0e6a5786d4fc0e96c34ccee2c59a707e3debb3b3 (diff)
downloadmariadb-git-218d20ffe3d4e833eb20a75d880fec1c1507b221.tar.gz
MDEV-22398: mariabackup.innodb_xa_rollback fails on repeat
Flush LSN to system tablespace on innodb shutdown if XA is rolled back by mariabackup.
-rw-r--r--storage/innobase/srv/srv0start.cc6
1 files changed, 5 insertions, 1 deletions
diff --git a/storage/innobase/srv/srv0start.cc b/storage/innobase/srv/srv0start.cc
index 41a1d42f649..e8a6a10d39d 100644
--- a/storage/innobase/srv/srv0start.cc
+++ b/storage/innobase/srv/srv0start.cc
@@ -2777,11 +2777,15 @@ innodb_shutdown()
ut_ad(!srv_undo_sources);
switch (srv_operation) {
+ case SRV_OPERATION_RESTORE_ROLLBACK_XA:
+ if (dberr_t err = fil_write_flushed_lsn(log_sys->lsn))
+ ib::error() << "Writing flushed lsn " << log_sys->lsn
+ << " failed; error=" << err;
+ /* fall through */
case SRV_OPERATION_BACKUP:
case SRV_OPERATION_RESTORE:
case SRV_OPERATION_RESTORE_DELTA:
case SRV_OPERATION_RESTORE_EXPORT:
- case SRV_OPERATION_RESTORE_ROLLBACK_XA:
fil_close_all_files();
break;
case SRV_OPERATION_NORMAL: