Using Postgres Backup and Restore

Das Goravani goravanis at
Sun Feb 13 18:17:59 UTC 2022

I want to move a postgres database from one server to another. 
I am reading the Postgres docs about pg_dump and psql to restore.

What I don’t get is basic: Are these commands to be entered on the command line or are they SQL?

Like the instruction from postgres:

Pg_dump dbname > outfile

Is that a command you enter into Terminal on the Mac, the command line?

And is outfile a path? Should you create the actual file at the end of the path?

Or is it meant to be a path that ends with a directory into which you want the file to go?

I’m thinking outfile is a complete path, with the file name given, but not created.. it will create it. That’s what I’m thinking. 

I’m also thinking these are command line commands. 

More information about the omnisdev-en mailing list