I'm running Postgres 8.1 on a CentOS 5 system with 4 GB of RAM. Whenever I set shared_buffers
above 320 MB, it won't run.
I've checked SHMMAX
and it's at 4294967295 which is the max allowed for a 32-bit/4 GB system. Below are some of the other memory related settings:
max_connections = 225
shared_buffers = 327680
work_mem = 524288
max_fsm_pages = 500000
max_fsm_relations = 10000
Any suggestions on what could improve this?
Best Answer
Just a misunderstanding I guess. The unit for the given number is blocks (or buffers), not 1 kb like you assume.
Quoting the manual for
shared_buffers
:Bold emphasis mine.
Not 320 MB. In modern Postgres the syntax with appended unit is preferred:
320MB
, but I don't think that's implemented in the ancient Postgres 8.1, yet. For 320 MB set the GUC to:Have you considered installing a modern version of Postgres? (Like has been hinted in the comments ever so gently). Postgres 8.1 was released 10 years ago.