Postgres on OS X Lion

There are issues with Postgres on Mac OS X Lion because it comes with its own Postgres instalation.

 

Here are the steps I took to make my custom postgres instalation to work:

  1. Delete the existing postgres user with the following command:

    sudo dscl . delete /users/postgres
  2. Recreate postgres user in the system preferences (name it postgres, and preferably chose the postgres123 password)
  3. Download and install Postgres 9.2 as you would normally do (http://www.postgresql.org/download/macosx

 

Alternate installation if you have trouble building you can find here.