Ubuntu中安装postgis

如何在Ubuntu服务器的命令行下安装Postgis呢,弄了很久,终于解决了。


首先要确认安装好了postgresql


1. sudo apt-get install postgresql-8.3-postgis


2. sudo su postgres

    createdb postgis_template

    createlang plpgsql postgis_template

    psql -d postgis_template -f /usr/share/postgresql-8.3-postgis/lwpostgis.sql

    psql -d postgis_template -f /usr/share/postgresql-8.3-postgis/spatial_ref_sys.sql

 

这样就安装好了,这比自己下载下来编译简单多了

 

参考链接http://www.paolocorti.net/2008/01/30/installing-postgis-on-ubuntu/

 

 

转载自:https://blog.csdn.net/lanshan_84/article/details/83456497

You may also like...

退出移动版