Re: TIL: In pg_dump, beware the combo of "-Fd" and "-Z"

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Jan 19, 2021 at 2:11 PM Ron <ronljohnsonjr@xxxxxxxxx> wrote:
Since the -Z default is "6"

It is?  Where do you see this?

https://www.postgresql.org/docs/12/app-pgdump.html

"-Z 0..9" 
"the default is to compress at a moderate level."

This sentence fragment does not exist in isolation, defaults are relative to the specific format and, apparently, only apply when this option is omitted.

What's also interesting is that this section doesn't mention what it does with directory format backups, though it does mention custom format.

Agreed, figured that directory is basically custom so they share the same default unless this parameter overrides it.
The whole thing reads:

"Specify the compression level to use. Zero means no compression. For the custom archive format, this specifies compression of individual table-data segments, and the default is to compress at a moderate level. For plain text output, setting a nonzero compression level causes the entire output file to be compressed, as though it had been fed through gzip; but the default is not to compress. The tar archive format currently does not support compression at all."

Nowhere in that is an omitted value for -Z given a default value (nor is value omission noted as being allowed).

In short, the observed behavior seems fine and the documentation just needs to better match reality.

David J.


[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux