pg_dumpbinary v2.11 released

Posted on 2023-05-28 by Gilles Darold
Related Open Source

Zurich, Switzerland - May 25th, 2023

pg_dumpbinary

pg_dumpbinary dumps a PostgreSQL database to a binary format. The resulting dump must be restored using pg_restorebinary, which is provided.

pg_dumpbinary 2.11 was released today, it fixes a major issue at restore time.

  • Fix restoration of extensions tables from the dumps. Data from these tables was not restored since the use of pg_restore pre-data section to retrieve the list of tables from the dump. pg_dumpbinary now create a new file into the dump directory: extensions-tables.lst. At restore time, command line filters on schemas and tables are also applied on this list if you need to exclude some of them.
  • Assume backward compatibility with old dumps that does not have the file extensions-tables.lst generated.

A full list of changes and acknowledgments can be found here

pg_dumpbinary is useful when:

  • You have bytea that can not be exported by pg_dump because the total size of the escape/hex output exceeds 1Gb.
  • You have custom type that stores \0 internally in bytea but data are exported by pg_dump as char/varchar/text. In this case pg_dump truncates all data after the first '\0', resulting in data loss.
  • Other cases where a binary output format is useful.

In these kinds of cases pg_dumpbinary helps by dumping the PostgreSQL database in a binary format. In all other cases the pg_dump/pg_restore commands distributed with PostgreSQL are preferred.

See the documentation for a more complete description of available features.

Links & Credits

pg_dumpbinary is an Open Source project from LzLabs GmbH. Contributions and ideas are welcome. Send your ideas, features requests, or patches using GitHub's tools.

Links :