To add to the information and the link that Fabrizio have posted:
Redshift is designed to be accessible from a VPC, and while tunneling to an EC2 instance from your local machine is possible, this isn't really that straight forward (and also adds latency between you and the cloud).
It will be more convenient if you work directly from an EC2 instance instead of the local machine - by this I mean running your python code there and not locally.
Hope this was useful. Regards
from the error it seems that you cannot still reach the Amazon Redshift cluster.
Could you please try to clarify:
- where are you running the Python job? (from inside the cloud or from your laptop?)
- who deployed the cluster? Can you clarify if it run in a public or private subnet? (has the subnet access to the internet or no)
- how have you modified the security groups?
In case you are running from your local laptop and the Redshift cluster is in a private subnet , you could try to review the this knowledge base article.
hope this helps
DMS 3.4.7 Fails on some tables upload to Redshift : Access denied to KMS keyasked 3 months ago
Kafka to RedshiftAccepted Answerasked 2 years ago
Transfer from S3 to Redshift and filter specific keyasked 10 months ago
Connecting AppSync with Redshift via Data APIasked 2 years ago
use Redshift Spectrum to query both Redshift table and s3 fileAccepted Answerasked 2 years ago
Using redshift-data boto3 to make cross account redshift callsasked 8 months ago
Where to find AWS Redshift Release Notes?asked 6 months ago
Connecting to Redshift with Python - Operation Timed Outasked 7 months ago
RedShift Serverless timeout when connecting with pythonasked 13 days ago
Migrating partitioned table from postgres to Redshift with pglogicalasked 10 days ago