Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

pg_dump -U postgres chf_hydra -Fp > chf_hydra_dump.sql  (dumps a text file with SQL statements to generate the database, does not allow levels of recovery)

 


To import a backup copy:

In Postgres make a blank database chf_hydra

pg_restore -d chf_hydra -U postgres chf_hydra.dump
or
psql chf_hydra < chf_hydra_dump.sql 


Then set permissions

psql -U postgres
GRANT Create,Connect,Temporary ON DATABASE chf_hydra TO chf_pg_hydra;

The postgres account password is in ansible-vault (groupvars/all)