this compresses with zlib. restore does not take into account for roles, so you’ll need to define them if you plan to restore onto a different location. The restore also tries to define plpgsql which is already present in my situation. it is merely a warning so that is fine.
pg_dump -F c -b -D -f “mydb.sql” mydb
pg_restore -d mydb -F c mydb.sql
Leave a Reply