MySQL文件系统快照还原失败

时间:2019-06-24 12:58:14

标签: mysql backup innodb

我正在拍摄AWS EBS卷的快照,该快照是文件系统快照。该卷由mysql使用,安装在/ var / lib / mysql中。当我使用备份的卷运行另一个mysql实例时,它无法还原到正确的状态。

我尝试将缓存大小和缓存限制设置为零。这样,当我从数据库中读取数据时,它是从实际磁盘中读取的,而不是缓存(这是我希望的,除非我错了)

SET GLOBAL query_cache_limit=0;
SET GLOBAL query_cache_size=0;

这些是我使用已安装的卷快照启动新的mysql容器时的日志:

2019-06-23 11:09:30 0 [Note] mysqld (mysqld 5.6.44) starting as process 1 ...
2019-06-23 11:09:30 1 [Note] Plugin 'FEDERATED' is disabled.
2019-06-23 11:09:30 1 [Note] InnoDB: Using atomics to ref count buffer pool pages
2019-06-23 11:09:30 1 [Note] InnoDB: The InnoDB memory heap is disabled
2019-06-23 11:09:30 1 [Note] InnoDB: Mutexes and rw_locks use GCC atomic builtins
2019-06-23 11:09:30 1 [Note] InnoDB: Memory barrier is not used
2019-06-23 11:09:30 1 [Note] InnoDB: Compressed tables use zlib 1.2.11
2019-06-23 11:09:30 1 [Note] InnoDB: Using Linux native AIO
2019-06-23 11:09:30 1 [Note] InnoDB: Using CPU crc32 instructions
2019-06-23 11:09:30 1 [Note] InnoDB: Initializing buffer pool, size = 128.0M
2019-06-23 11:09:30 1 [Note] InnoDB: Completed initialization of buffer pool
2019-06-23 11:09:30 1 [Note] InnoDB: Highest supported file format is Barracuda.
2019-06-23 11:09:30 1 [Note] InnoDB: The log sequence numbers 1633877 and 1633877 in ibdata files do not match the log sequence number 1633887 in the ib_logfiles!
2019-06-23 11:09:30 1 [Note] InnoDB: Database was not shutdown normally!
2019-06-23 11:09:30 1 [Note] InnoDB: Starting crash recovery.
2019-06-23 11:09:30 1 [Note] InnoDB: Reading tablespace information from the .ibd files...
2019-06-23 11:09:30 1 [Note] InnoDB: Restoring possible half-written data pages 
2019-06-23 11:09:30 1 [Note] InnoDB: from the doublewrite buffer...
2019-06-23 11:09:30 1 [Note] InnoDB: 128 rollback segment(s) are active.
2019-06-23 11:09:30 1 [Note] InnoDB: Waiting for purge to start
2019-06-23 11:09:30 1 [Note] InnoDB: 5.6.44 started; log sequence number 1633887
2019-06-23 11:09:30 1 [Note] Server hostname (bind-address): '*'; port: 3306
2019-06-23 11:09:30 1 [Note] IPv6 is available.
2019-06-23 11:09:30 1 [Note]   - '::' resolves to '::';
2019-06-23 11:09:30 1 [Note] Server socket created on IP: '::'.
2019-06-23 11:09:30 1 [Warning] Insecure configuration for --pid-file: Location '/var/run/mysqld' in the path is accessible to all OS users. Consider choosing a different directory.
2019-06-23 11:09:30 1 [Warning] 'proxies_priv' entry '@ root@demo-7744bc55cd-swsft' ignored in --skip-name-resolve mode.
2019-06-23 11:09:30 1 [Note] Event Scheduler: Loaded 0 events
2019-06-23 11:09:30 1 [Note] mysqld: ready for connections.
Version: '5.6.44'  socket: '/var/run/mysqld/mysqld.sock'  port: 3306  MySQL Community Server (GPL)

我希望获得与快照时相同的mysql状态。

0 个答案:

没有答案