Kubernetes 卷快照对比。 sql备份?

Kubernetes volume snapshot Vs. sql backup?

我在 Kubernetes pod 中 运行ning 数据库。我正计划 运行 K8s 作业从 pod 自动备份数据库。

我还可以编写 shell 脚本来获取卷 (PV) 的快照。

哪种方法更好用?在紧急情况下,哪个可以节省时间恢复数据?

您可以使用Stash by AppsCode,这是备份 Kubernetes 卷的绝佳解决方案。

查看支持的版本 here

Stash by AppsCode is a Kubernetes operator for restic. If you are running production workloads in Kubernetes, you might want to take backup of your disks. Traditional tools are too complex to setup and maintain in a dynamic compute environment like Kubernetes. restic is a backup program that is fast, efficient and secure with few moving parts. Stash is a CRD controller for Kubernetes built around restic to address these issues. Using Stash, you can backup Kubernetes volumes mounted in following types of workloads:

Deployment, DaemonSet, ReplicaSet, ReplicationController, StatefulSet

在使用 Script or HELM 安装 stash 后,您需要关注 不熟悉Backup and Restore的说明

我觉得很有用