Re: Postgresql Page Layout details - Mailing list pgsql-general

From Richard Huxton
Subject Re: Postgresql Page Layout details
Date
Msg-id 47CFB6B2.6000609@archonet.com
Whole thread Raw
In response to Re: Postgresql Page Layout details  (Najib Abi Fadel <nabifadel@yahoo.com>)
List pgsql-general
Najib Abi Fadel wrote:
> Concerning the 8KB page size, as i understood postgres
> Page Size is different from the file system Block
> size.
> If the system block size is 4kB are there any
> mechanism that guaranties that a postgres page is
> stored on 2 adjacent file system blocks ?

That's the job of the filesystem, and is a problem that could affect any
file that's 5KB or larger.

> Cause otherwise performance may suffer since accessing
> 1 page in postgres  may require reading 2 distant
> blocks!

Yes. And how many users would a filesystem have if it did that on a
regular basis :-)

> According to my understanding of how file system
> works, a file system block is the unit of exchange
> between the hard disk and the main memory.

Yes. Well, it's the unit of exchange between the filesystem and the
disk. Otherwise you couldn't have different filesystem block sizes. And
you could probably argue that a multi-disk RAID setup's stripe-size is a
more logical unit to work with.

--
   Richard Huxton
   Archonet Ltd

pgsql-general by date:

Previous
From: Najib Abi Fadel
Date:
Subject: Re: Postgresql Page Layout details
Next
From: Thomas Pundt
Date:
Subject: Re: ER Diagram design tools (Linux)