These are some notes for running Oneiric on a development machine.
Make sure all old Postgres installations are purged:
sudo apt-get purge postgresql postgresql-8.4
sudo apt-get install postgresql
Turning off the fsync option will make Postgres run faster as it won't insist that all database changes are written to disk. Clearly do not do this if you care about the data you are writing to Postgres. This shouldn't be a problem on any development machine as they're all test databases.
Edit the server configuration:
sudo nano /etc/postgres/9.1/main/postgresql.conf
fsync = off
sudo service postgresql restart
Making proper use of ident authentication means that you can access Postgres without needing to use a password. Many of our Postgres set up scripts for projects assume that you have ident configured as a Postgres superuser.
Run psql as the postgres user to add in your configuration:
sudo -u postgres psql
And now we need to configure ident authentication — my user name is kirit, change to whatever you log in to Ubuntu as:
create role kirit login superuser; create database kirit with owner=kirit;
Exit psql and try again with your own account:
You should now be able to see the postgres prompt again.
I have a Django user that I use across projects:
create role "Django" login superuser password 'django';
From here you can set up the databases or add other roles that you need normally.