Skip to content

Instantly share code, notes, and snippets.

@afraz-khan
Created February 10, 2022 11:29
Show Gist options
  • Save afraz-khan/e0970a7be2642f23dc2a05a964d3c279 to your computer and use it in GitHub Desktop.
Save afraz-khan/e0970a7be2642f23dc2a05a964d3c279 to your computer and use it in GitHub Desktop.
Create new database in existing AWS RDS Postgresql Instance.

Log into your RDS Instance

  • Open a terminal into your local machine.
  • Get hold of credentials of any existing database in your RDS instance.
  • Log into the instance with those DB credentials using below command:
      psql \
       --host=<DB instance endpoint> \
       --port=<port> \
       --username=<master username> \
       --password \
       --dbname=<database name>
    

Create New Database

  • Create new database into your existing RDS instance with below command:
    CREATE DATABASE <DB name>;
    

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment