> [...] > Right, the file is fully written under a temp name, and then > rename()'d This makes sense and is almost certainly not the cause of the problem. Although there is a lot more data being written to that file than I would have thought. One of Sun's kernel engineers has come up with a solution that seems to have fixed the problem. Instead of increasing work_mem (which we still might do) we've mounted a swapfs partition over the pg temp directory: # mount | grep pgsql_tmp /export/data/pgsql/data/base/64920741/pgsql_tmp on swap [...] This has actually reduced the disk activity considerably. So far, the blocking problem seems to have gone. Now to find some Postgres DBAs in Sydney to do some review / tuning of our memory settings. :-) Dan -- Confidential: This email is intended only for the person or entity to which it is addressed. The information contained in this email may be confidential and privileged. Any retransmission, review, dissemination or other use of, or taking of any action in reliance upon, this information by persons or entities other than the intended recipient is prohibited. If you received this email in error, please let us know by reply and destroy all copies of it. Thank you.