[postgis-users] Ubuntu and Postgresql9.1.3-2
Brian H Wilson
brian at wildsong.biz
Thu May 24 07:27:38 PDT 2012
On 05/24/2012 05:13 AM, José María Amuedo wrote:
> I understand all steps I have to following to get the installation, but:
>
> Do we know if someone installed PostGIS 2 with PostgreSQL 9.1.3-2 in
> Ubuntu 12_04 LTS????
>
> Thanks
It happens my new desktop has a recent Ubuntu 12.04 install (AWESOME new
computer! :-), and I don't usually run PostGIS on it (I keep it on a
server in the other room) so I removed the postgres client previously
installed on the desktop like this
sudo apt-get -f remove postgresql-client postgresql-client-common
Next I tried these instructions on the computer I am sitting at, from
the first link I sent yesterday
sudo apt-get install python-software-properties
sudo apt-add-repository ppa:sharpie/for-science
sudo apt-get update
sudo apt-get install postgresql-9.1-postgis
Now I have
psql --version
psql (PostgreSQL) 9.1.3
contains support for command-line editing
I also have two versions of GDAL installed now, for what it's worth,
postgres at laysan:~$ /usr/bin/gdalinfo --version
GDAL 1.7.3, released 2010/11/10
postgres at laysan:~$ /usr/local/bin/gdalinfo --version
GDAL 2.0dev, released 2011/12/29
I have found having different versions of things can be a problem, hence
I usually just install things from sources to get all the features and
most up tp date gdal possible. But for now I press on...
In the past I have always used the procedure outlined on my wiki to add
PostGIS to PostgreSQL. Therefore creating a geodatabase meant using a
template. Today I try the command you suggested.
This is where I have a problem -- using EXTENSION
postgres at laysan:~$ createdb test
postgres at laysan:~$ psql test
psql (9.1.3)
Type "help" for help.
test=# CREATE EXTENSION postgis;
ERROR: function st_asgml(integer, geography, integer, integer, text,
text) does not exist
test=#
Seems like I got further than you José but still encountered a problem.
No time to look at it now but I think for you, remove all the old
packages and try the above. Get rid of the 8.4 postgres and 1.5 postgis
using "sudo apt-get -f remove packagename" as I did with the client
above. THen try again.
Brian
More information about the postgis-users
mailing list