I created a serverless Aurora-Postgresql RDS cluster on AWS in a VPC, and a Linux EC2 instance to access it from, also in the VPC. I have a binary file dump.bin I dumped from a prior database with pg_dump -Fc that I want to use to restore the new database to the state of the old one. Inside the EC2 instance, I can run pg_dump against the new database with no issues, which creates a dump of the unconfigured database. I can even run pg_restore --version, and it prints pg_restore (PostgreSQL) 10.17. But when I run pg_restore with arguments to connect to the database and actually try to commit the restore, the program simply hangs indefinitely with no output.
This is the command I am running:
pg_restore --host=<rds-instance-dns-host>.us-east-2.rds.amazonaws.com --port=5432 --username=postgres --file=dump.bin --verbose