Re: Re: Idea: recycle WAL segments, don't delete/recreate 'em

Поиск
Список
Период
Сортировка
От Bruce Momjian
Тема Re: Re: Idea: recycle WAL segments, don't delete/recreate 'em
Дата
Msg-id 200107181535.f6IFZeJ11647@candle.pha.pa.us
обсуждение исходный текст
Ответ на Re: Re: Idea: recycle WAL segments, don't delete/recreate 'em  (Gunnar Rønning <gunnar@polygnosis.com>)
Список pgsql-hackers
> * Bruce Momjian <pgman@candle.pha.pa.us> wrote:
> 
> | Most Unix filesystems will not allocate disk blocks until you write in
> | them.  If you just seek out past end-of-file, the file pointer is moved
> | but the blocks are unallocated.  This is how 'ls' can show a 1gb file
> | that only uses 4k of disk space.
> 
> Does this imply that we could get a performance gain by preallocating space
> for indexes and data itself as well ? I've seen that other database products
> have a setup step where you have to specify the size of the database. 
> 
> Or does PostgreSQL do any other tricks to prevent fragmentation of data ?

If we stored all our tables in one file that would be needed. Since we
use the OS to do the defragmenting, I don't think it is an issue.  We do
allocate in 8k chunks to allow the OS to allocate full filesystem blocks
already.  Not sure if preallocating even more would help.

--  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 по дате отправления:

Предыдущее
От: Philip Warner
Дата:
Сообщение: Re: pg_depend
Следующее
От: Bruce Momjian
Дата:
Сообщение: Re: pg_depend