您现在访问的是微软AZURE全球版技术文档网站,若需要访问由世纪互联运营的MICROSOFT AZURE中国区技术文档网站,请访问 https://docs.azure.cn.
在 Azure Database for MySQL 中进行备份和还原Backup and restore in Azure Database for MySQL
3/27/2020
本文内容
Azure Database for MySQL 可自动创建服务器备份并将其存储在用户配置的本地冗余或异地冗余存储中。Azure Database for MySQL automatically creates server backups and stores them in user configured locally redundant or geo-redundant storage. 备份可以用来将服务器还原到某个时间点。Backups can be used to restore your server to a point-in-time. 备份和还原是任何业务连续性策略的基本组成部分,因为它们可以保护数据免遭意外损坏或删除。Backup and restore are an essential part of any business continuity strategy because they protect your data from accidental corruption or deletion.
备份Backups
Azure Database for MySQL 对数据文件和事务日志进行备份。Azure Database for MySQL takes backups of the data files and the transaction log. 可以通过这些备份将服务器还原到所配置的备份保留期中的任意时间点。These backups allow you to restore a server to any point-in-time within your configured backup retention period. 默认的备份保留期为七天。The default backup retention period is seven days. 可以选择将其配置为长达 35 天。所有备份都使用 AES 256 位加密进行加密。All backups are encrypted using AES 256-bit encryption.
这些备份文件不公开给用户,因此无法导出。These backup files are not user-exposed and cannot be exported. 这些备份只能用于 Azure Database for MySQL 中的还原操作。These backups can only be used for restore operations in Azure Database for MySQL. 可以使用 mysqldump 复制数据库。You can use mysqldump to copy a database.
备份类型和频率取决于服务器的后端存储。The backup type and frequency is depending on the backend storage for the servers.
备份类型和频率Backup type and frequency
基本存储服务器Basic storage servers
基本存储是支持基本层服务器的后端存储。The Basic storage is the backend storage supporting Basic tier servers. 基本存储服务器上的备份是基于快照的。Backups on Basic storage servers are snapshot-based. 每天执行一次完整数据库快照。A full database snapshot is performed daily. 不会对基本存储服务器执行任何差异备份,所有快照备份都仅为完整数据库备份。There are no differential backups performed for basic storage servers and all snapshot backups are full database backups only.
事务日志备份每五分钟进行一次。Transaction log backups occur every five minutes.
存储容量最大达 4 TB 的常规用途存储服务器General purpose storage servers with up to 4-TB storage
常规用途存储是支持常规用途和内存优化层服务器的后端存储。The General purpose storage is the backend storage supporting General Purpose and Memory Optimized tier server. 对于常规用途存储容量最大达 4 TB 的服务器,完整备份每周进行一次。For servers with general purpose storage up to 4 TB, full backups occur once every week. 差异备份一天进行两次。Differential backups occur twice a day. 事务日志备份每五分钟进行一次。Transaction log backups occur every five minutes. 存储容量最大达 4 TB 的常规用途存储上的备份不是基于快照的,并且在备份时会消耗 IO 带宽。The backups on general purpose storage up to 4-TB storage are not snapshot-based and consumes IO bandwidth at the time of backup. 对于 4 TB 存储上的大型数据库 (> 1 TB),建议考虑:For large databases (> 1 TB) on 4-TB storage, we recommend you consider
为备份 IO 预配更多 IOPProvisioning more IOPs to account for backup IOs OR
或者,如果基础存储基础结构在你的首选 Azure 区域中可用,则可以迁移到支持存储容量最大达 16 TB 的常规用途存储。Alternatively, migrate to general purpose storage that supports up to 16-TB storage if the underlying storage infrastructure is available in your preferred Azure regions. 支持最大 16 TB 存储的常规用途存储不产生额外的费用。There is no additional cost for general purpose storage that supports up to 16-TB storage. 若要获得有关迁移到 16 TB 存储的帮助,请从 Azure 门户创建支持工单。For assistance with migration to 16-TB storage, please open a support ticket from Azure portal.
存储容量最大达 16 TB 的常规用途存储服务器General purpose storage servers with up t