Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

What is the easiest way to install postgis on Ubuntu Server 11.10?

apt-get install ...
share|improve this question
add comment

2 Answers

up vote 6 down vote accepted

this package is not available in the official repository so you can use a ppa for a quick and dirty installation.

https://wiki.ubuntu.com/UbuntuGIS

for Ubuntu 11.10 Oneiric the packages are only available in the unstable version of this PPA, to install and use this ppa

sudo add-apt-repository ppa:ubuntugis/ubuntugis-unstable

to update your software list and install the package you are interested of

sudo apt-get update; sudo apt-get install postgis
share|improve this answer
    
OKAY SO FAR SO GOOD. now how do i create a db? (+1).. where did it get installed? –  capdragon Dec 3 '11 at 5:31
    
    
this is a website about Ubuntu, search for a tutorial or something like that on the internet for extra information that does not belongs to the topic of this website. –  Micro Dec 3 '11 at 5:41
    
agreed... probably belongs in the GIS SE –  capdragon Dec 3 '11 at 5:48
    
I can't find any up-to-date tutorials. –  capdragon Dec 3 '11 at 5:49
add comment

As noted in Micro's answer, your best bet for installing PostGIS is the UbuntuGIS PPA. As of the time I'm writing they are distributing PostgreSQL 9.1 and PostGIS 2.0.1. Starting with these versions it became much easier to set up a PostGIS database.

Once PostGIS is installed, how do you create a PostGIS database? Ignore any old docs you find about using template_postgis or importing a bunch of .sql scripts in to your database. All you need to do in the new way is

createdb foo
psql -d foo -c 'create extension postgis'
psql -d foo -c 'create extension postgis_topology'
share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.