PostgreSQL server for Django applications under Ubuntu

Written by Guillermo Garron .
Date: 2013-05-09 17:47:13 -0400


In case you are trying to install a Django application that may need a database, one really powerful is PostgreSQL, but to be able to use it, you firs need to install it.

Under Ubuntu these are the steps neede to acomplish that.

sudo apt-get install postgresql libpq-dev

Then the psycopg2 Python library.

sudo pip install psycopg2


sudo easy_install psycopg2

Finally in your or add this (something like this)

    'default': {
        'ENGINE': 'django.db.backends.postgresql_psycopg2',
        'NAME': 'db_name',                      
        'USER': 'db_user',
        'PASSWORD': 'db_user_password',
        'HOST': ''

Now you are ready to run your app.


If you enjoyed the article, please share it

twitter | facebook | google+ | linkedin | email | reddit

comments powered by Disqus



My name is Guillermo Garron. I am telecommunications engineer from Bolivia

I like technology a lot, and this site is mainly dedicated to that

Social feeds

rss | twitter | email | google+

Posts via email

If you use the letter icon above and subscribe to my tinyletter newsletter, you will get one to two emails, related to this site, or not. If what you want is to get the posts of this site via email, use the form below

Enter your email address:

Delivered by FeedBurner