![](/img/trans.png)
[英]Can not copy data from s3 to redshift cluster in a private subnet
[英]Can not connect to my Redshift cluster in private subnet
我已经使用Linux Bastion Host Quick Start 中讨论的建议方法设置了 VPC。
我还在其中一个私有子网中创建了一个 Redshift 集群,并创建了没有规则限制的专用安全组。 这适用于 Redshift 的入站和出站规则,我正在分配所有流量和端口 (0.0.0.0/0)。 我什至为公共子网上的公共 EC2 实例做同样的事情。
我可以成功 ssh 到我的公共堡垒实例,但从那里我无法 telnet 到我的 Redshift 端点。
[ec2-user@ip-10-0-141-20 ~]$ telnet ******.redshift.amazonaws.com 5439
Trying 10.0.20.169...
Connected to ******.redshift.amazonaws.com.
Escape character is '^]'.
Connection closed by foreign host.
我不确定我的配置有什么问题。 在 Redshift 中,我禁用了公共访问和 VPC 路由。
我假设你的情况是:
一种方法是:
ssh-add keypair.pem
ssh -A ec2-user@BASTION-IP -L 5439:xyz.redshift.amazonaws.com:5439
(这表示:将本地端口 5439 转发到堡垒,应该将流量发送到端口 5439 上的 Redshift 集群)
server=localhost
和port=5439
以及您的登录凭据连接到 Redshift如果上述方法不起作用,请检查以下事项:
0.0.0.0/0
如果仍然出错,您可以通过在 Bastion 上安装psql
并尝试连接到 Redshift 来测试 Redshift 连接。 (Redshift 是从 PostgreSQL 分叉出来的,所以它的行为类似)。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.