Is there some way to select the page size of a Postgres database?
I know that the page size is usually 8K. I also read this email thread from 2003. I don't know that pg_controldata
will work as I don't have access to the filesystem that the database is hosted on.
Best Answer
If you don't have access to
pg_controldata
...There is a simple way:
The manual:
To verify
Create a dummy table with only 1 small row: one data page is allocated. Then check the size of the "main" relation fork with
pg_relation_size()
So the page size is 8 kB, which is hardly surprising like you mentioned. The manual: