iAm*_*ric 6 database backup database-backups docker barman
我有一个 kubernetes 集群,有一个运行 postgres 数据库的 pod,所以在 Docker 中。显然,我已经将数据安装在主机上了。
我想设置 Barman 来为数据库提供备份解决方案。
我阅读了有关酒保的文档。根据http://docs.pgbarman.org/release/2.0/的设计和架构部分,我想采用以下架构,因为我有一个大型数据库,并且增量备份符合我们的要求。这对于流式备份策略来说是不可能的(场景 1:通过流式协议备份),即使他们说这对于 Docker 环境更好
我的问题是当 postgres 在 Docker 中运行时如何设置?由于文件已安装在主机上,我可以仅在主机上使用 ssh 来继续备份吗?
感谢你的回答
您无法通过 ssh 连接到主机来继续,因为它必须由容器中运行的 PostgreSQL 服务器启动和协调。
You can however setup passwordless ssh connectivity (with ssh keys) along with streaming connectivity between PostgreSQL & Barman containers and implement the stated architecture.
This entails building & running a PostgreSQL container with ssh server & rsync along with barman.
There are many versions of implementations out there that have done it, but if you wanted to do something from the scratch & keep the image simple, please take a look at the implementation of the above shared in the below git repo,
https://github.com/softwarebrahma/PostgreSQL-Disaster-Recovery-With-Barman
Thanks
| 归档时间: |
|
| 查看次数: |
3104 次 |
| 最近记录: |