postgresql - RDS 到 S3 直接使用 pg_dump(没有中介)

标签 postgresql amazon-web-services amazon-ec2 amazon-s3 amazon-rds

可以在 RDS 或 S3 中运行 pg_dump(无需使用像 ec2 这样的中介来执行命令)

最佳答案

AWS CLI 添加了对 uploads from stdin 的支持, 所以你现在可以选择做这样的事情:

pg_dump ...dbargs... | aws s3 cp - s3://my-bucket/backup-$(date "+%Y-%m-%d-%H-%M-%S")

这并不理想,因为您正在流式传输到本地计算机,然后传输到 s3 - 但它至少是一个命令。

关于postgresql - RDS 到 S3 直接使用 pg_dump(没有中介),我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/22017596/

相关文章:

c++ - 在 PostgreSQL 中使用 C++ 函数

amazon-web-services - 无法 ping ipv6 AWS EC2 实例

amazon-web-services - 使用 AWS Application Load-Balancer (ALB) 到外部资源的基于路径的路由

postgresql - PostgreSQL 函数是事务性的吗?

postgresql - Postgres : while "table has rows" loop. ..

amazon-web-services - 如何在 AWS 中启用 swagger UI

amazon-web-services - 从 CloudFormation 模板中的 DropDownList 选择多个值

python - amazon ec2 centOS 上没有名为 tkinter 的模块

linux - 无法登录到我的 aws spot 实例,即使它正在运行

postgresql - 创建 CSV 文件时,Postgres id 到数组中的名称映射