EnterpriseDB have kindly created a one-click installer for PostgreSQL, but unfortunately it doesn’t work out-of-the-box, at least not on my MacBook Pro. The problem is down to the amount of shared memory that is configured in OS X; by default it is 4Mb, and PostgreSQL requires 32Mb:
The error message suggests looking at the README file, which actually doesn’t exist. Luckily, there’s a simple fix; to increase the shared memory to the required 32Mb, create or edit the /etc/sysctl.conf
file and include the following lines:
kern.sysv.shmall=8192 kern.sysv.shmseg=64 kern.sysv.shmmni=256 kern.sysv.shmmin=1 kern.sysv.shmmax=33554432
Reboot your machine for the settings to take effect, and re-launch the PostgreSQL installer which should now work as normal.