Re: Restore of pg_dump taking a long time...

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

 



Tom Lane wrote:

There's not much you can do to improve the performance of a restore
already in progress.  Next time you might want to think about kicking up
maintenance_work_mem before you start it; that's about the only thing
you can really do to speed up index builds.

I have found that increasing maintenance_work_mem can decrease index
build speed on large tables:

maintenance_work_mem    32768    262144     1048576     2097151
---------------------------------------------------------------
index 400M rows (min)      55        61          68          70
index  45M rows (min)    4.03      4.22        4.88        2.55

These timings were done on a machine with 8GB ram and postgresql 8.1.3
(from the RPMs on postgresql.org).  Each time is an average of three
runs; before each run, postgres was shut down and the filesystem with
/var/lib/pgsql was remounted to clear the filesystem cache.

I'm assuming that the times are increasing because there is less
memory available for the filesystem cache.  Similarly, I assume that
the runs on the smaller table with maintenance_work_mem = 2097151
are faster because everything fits in that space.

-- todd


[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