May 2019
Intermediate to advanced
600 pages
20h 46m
English
What time was pg_dump taken? The snapshot for pg_dump is taken at the beginning of a backup. The file modification time will tell you when the dump finished. The dump is consistent at the time of the snapshot, so you may need to know that time.
If you are making a script dump, you can do a verbose dump, as follows:
pg_dump -v
This adds the time to the top of the script. Custom dumps store the start time as well, and that can be accessed using the following command:
pg_restore --schema-only -v dumpfile 2>/dev/null | head | grep Started-- Started on 2018-06-03 09:05:46 BST
Read now
Unlock full access