1. 내용
1.1 환경
- MariaDB Version : 10.1.12
- DB 서버 2대 이중화 구성
1.2 내용
- Innobackupex 로 백업된 파일을 이용하여 Master 서버 DB 복구. 복구 이후 MariaDB Connection 실패
2. 원인분석
2.1 로그 분석 (error log)
- 해당 에러로그는 InnoDB 데이터파일이 손상되었을 경우 발생되는 에러로그
InnoDB: Warning: purge reached the head of the history list,
InnoDB: but its length is still reported as 2907435
...
2.2 innobackupex
- apply-log 작업시 에러 발생. 이미 백업 시점에서 데이터파일이 손상되었음
IMPORTAT: Please check that the apply-log run completes successfully.
At the end of a successful apply-log run innobackupex
prints "completed OK!".
... 중략 ...
InnoDB: Waiting for purge to start
InnoDB: Purge reached the head of the history list, but its length is still reported as 2908868! Make a detailed bug report, and submit it to http://bugs.mysql.com
InnoDB: Purge reached the head of the history list, but its length is still reported as 2908868! Make a detailed bug report, and submit it to http://bugs.mysql.com
InnoDB: Purge reached the head of the history list, but its length is still reported as 2908868! Make a detailed bug report, and submit it to http://bugs.mysql.com
... 중략 ...
InnoDB: Starting shutdown...
InnoDB: Shutdown completed; log sequence number 457136439472
190330 04:10:47 completed OK
3. 해결방법
3.1 Slave 서버 전체 데이터 백업
- mysqldump 유틸리티 전체 백업
3.2 Master 서버 DB 재 설치
3.3 Master 서버 전체 데이터 복구
- mysqldump 로 백업한 데이터 전체 복구 진행