Re: How to increace nightly backup speed

From: Martijn van Oosterhout <kleptog(at)svana(dot)org>
To: Andrus <eetasoft(at)online(dot)ee>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: How to increace nightly backup speed
Date: 2006-11-28 16:14:40
Message-ID: 20061128161440.GF29938@svana.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Tue, Nov 28, 2006 at 03:29:44PM +0200, Andrus wrote:
> > If you've got excess CPU capacity at night, I wonder if -Z1 or -Z2
> > would speed the backup since it reduces the amount of data written
> > to disk.
>
> Where to find study which pg_dump compares backup speed and backup size by
> using various -Z options ?

pg_dump uses zlib, you should be able to find statistic on that.

> I'm wondering by -Z9 increases backup speed.
> Info-zip zip.exe -9 config option does not decrease compiression speed

I don't beleive that. The whole point of increasing the compression
level is that it spends longer on the data to compress it better. It
you could compress it better in the same time, you'd just do it and not
make it optional.

> I'm really wondering why -Z9 decreases backup speed significantly.

Level 9 is the absolute maximum compression level, it tries really hard
to make the data small, but it's usually not that much better than level
6.

If you're transferring over a 100Mb network, I wouldn't recommend going
higher than level 3. It is not unheard of that increasing the
compression makes the process take longer, because you're saturating
the CPU while your network is idle.

Also, if you have a multicore system, it may be worth having pg_dump
not compress but piping the output through gzip, then you can use both
processors simultaneously.

Have a nice day,
--
Martijn van Oosterhout <kleptog(at)svana(dot)org> http://svana.org/kleptog/
> From each according to his ability. To each according to his ability to litigate.

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Tom Lane 2006-11-28 16:16:52 Re: Datafiles binary portable?
Previous Message Karsten Hilbert 2006-11-28 16:13:35 Re: How to implement backup protocol