Re: Block size: 8K or 16K?

Поиск
Список
Период
Сортировка
От Bruce Momjian
Тема Re: Block size: 8K or 16K?
Дата
Msg-id 200204260528.g3Q5SPE24881@candle.pha.pa.us
обсуждение исходный текст
Ответ на Re: Block size: 8K or 16K?  (Curt Sampson <cjs@cynic.net>)
Список pgsql-hackers
Curt Sampson wrote:
> On Thu, 25 Apr 2002, mlw wrote:
> 
> > ...but my gut tells me that using 16K blocks will increase performance
> > over 8K. Aleady I have seen a sequential scan of a large table go from 20
> > seconds using 8K to 17.3 seconds using 16K.
> 
> You should be able to get the same performance increase with 8K
> blocks by reading two blocks at a time while doing sequential scans.
> That's why I've been promoting this idea of changing postgres to
> do its own read-ahead.
> 
> Of course, Bruce might be right that the OS read-ahead may take
> care of this anyway, but then why would switching to 16K blocks
> improve sequential scans? Possibly because I'm missing something here.

I am almost sure that increasing the block size or doing read-ahead in
the db will only improve performance if someone is performing seeks in
the file at the same time, and hence OS readahead is being turned off.

--  Bruce Momjian                        |  http://candle.pha.pa.us pgman@candle.pha.pa.us               |  (610)
853-3000+  If your life is a hard drive,     |  830 Blythe Avenue +  Christ can be your backup.        |  Drexel Hill,
Pennsylvania19026
 


В списке pgsql-hackers по дате отправления:

Предыдущее
От: Curt Sampson
Дата:
Сообщение: Re: Block size: 8K or 16K?
Следующее
От: Curt Sampson
Дата:
Сообщение: Re: Vote totals for SET in aborted transaction