Re: weird performances problem

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

 



On Fri, Nov 18, 2005 at 12:35:06AM +0100, Guillaume Smet wrote:
> sort_mem = 32768

I would be very suspicious of that much memory for sort.  Please see
the docs for what that does.  That is the amount that _each sort_ can
allocate before spilling to disk.  If some set of your users are
causing complicated queries with, say, four sorts apiece, then each
user is potentially allocating 4x that much memory.  That's going to
wreak havoc on your disk buffers (which are tricky to monitor on most
systems, and impossible on some).

This'd be the first knob I'd twiddle, for sure.

A

-- 
Andrew Sullivan  | ajs@xxxxxxxxxxxxxxx
It is above all style through which power defers to reason.
		--J. Robert Oppenheimer

---------------------------(end of broadcast)---------------------------
TIP 9: In versions below 8.0, the planner will ignore your desire to
       choose an index scan if your joining column's datatypes do not
       match

[Postgresql General]     [Postgresql PHP]     [PHP Users]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Yosemite]

  Powered by Linux