Обсуждение: [ADMIN] pg_dump with custom format without compression
Hi all, I'm using pg_dump with custom format "c" on some databases containing already compressed large binaries, like Zip, compressed PDF etc. So I don't benefit of the compression of format "c" much, but creating a dump takes about twice as much time compared to uncompressed format "t". Is there any way to use format "c" without any compression, so I get somewhat the same processing time like with format "t"? From the docs it sounds that format "c" is the most flexible when it comes to restore and I would simply like to keep all the options it provides, just in case. So if not compression is only possible with "t", I might as well decide to use that and live with its theoretical shortcomings on restore. Thanks! Mit freundlichen Grüßen, Thorsten Schöning -- Thorsten Schöning E-Mail: Thorsten.Schoening@AM-SoFT.de AM-SoFT IT-Systeme http://www.AM-SoFT.de/ Telefon...........05151- 9468- 55 Fax...............05151- 9468- 88 Mobil..............0178-8 9468- 04 AM-SoFT GmbH IT-Systeme, Brandenburger Str. 7c, 31789 Hameln AG Hannover HRB 207 694 - Geschäftsführer: Andreas Muchow
On 4/8/2017 4:58 AM, Thorsten Schöning wrote: > Hi all, > > I'm using pg_dump with custom format "c" on some databases containing > already compressed large binaries, like Zip, compressed PDF etc. So I > don't benefit of the compression of format "c" much, but creating a > dump takes about twice as much time compared to uncompressed format > "t". > > Is there any way to use format "c" without any compression, so I get > somewhat the same processing time like with format "t"? > > From the docs it sounds that format "c" is the most flexible when it > comes to restore and I would simply like to keep all the options it > provides, just in case. So if not compression is only possible with > "t", I might as well decide to use that and live with its theoretical > shortcomings on restore. > > Thanks! > > Mit freundlichen Grüßen, > > Thorsten Schöning > Try setting the compression level. I myself use "--compress=1", which gives me decent compression for very little cost in backup speed. -- Michael Heaney JCVI
Guten Tag Michael Heaney, am Samstag, 8. April 2017 um 12:22 schrieben Sie: > Try setting the compression level. I myself use "--compress=1", which > gives me decent compression for very little cost in backup speed. Thanks, I feel so stupid. :-) Scrolled so many times over the docs and didn't recognize that. Mit freundlichen Grüßen, Thorsten Schöning -- Thorsten Schöning E-Mail: Thorsten.Schoening@AM-SoFT.de AM-SoFT IT-Systeme http://www.AM-SoFT.de/ Telefon...........05151- 9468- 55 Fax...............05151- 9468- 88 Mobil..............0178-8 9468- 04 AM-SoFT GmbH IT-Systeme, Brandenburger Str. 7c, 31789 Hameln AG Hannover HRB 207 694 - Geschäftsführer: Andreas Muchow
alternative :
t
tar
Output a tar-format archive suitable for input into pg_restore.
The tar format is compatible with the directory format:
extracting a tar-format archive produces a valid
directory-format archive. However, the tar format does not
support compression. Also, when using tar format the relative
order of table data items cannot be changed during restore
example :
pg_dump -U postgres -h faiserver -F t -f aaa.tar -d warehouse_db
Actually, in my experience, compress would finish more quickly due to much smaller disk consumption size under modern cpu model.
Steven4
2017-04-08 19:31 GMT+08:00 Thorsten Schöning <tschoening@am-soft.de>:
Guten Tag Michael Heaney,
am Samstag, 8. April 2017 um 12:22 schrieben Sie:
> Try setting the compression level. I myself use "--compress=1", which
> gives me decent compression for very little cost in backup speed.
Thanks, I feel so stupid. :-) Scrolled so many times over the docs and
didn't recognize that.
Mit freundlichen Grüßen,
Thorsten Schöning
--
Thorsten Schöning E-Mail: Thorsten.Schoening@AM-SoFT.de
AM-SoFT IT-Systeme http://www.AM-SoFT.de/
Telefon...........05151- 9468- 55
Fax...............05151- 9468- 88
Mobil..............0178-8 9468- 04
AM-SoFT GmbH IT-Systeme, Brandenburger Str. 7c, 31789 Hameln
AG Hannover HRB 207 694 - Geschäftsführer: Andreas Muchow--
Sent via pgsql-admin mailing list (pgsql-admin@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-admin