Tag Archives: PostGIS

Notes on PostGIS and Geoserver

This is a post to remind me of some of the things that I did to get a VM set up with a vanilla install of PostGIS and Geoserver. More will be posted once I get the extensions up and working and data into the system.

The first thing to do is get your OS set up and running nicely inside of VirtualBox or whatever VM software you use. I have been trying out a few lightweight Linux distributions recently including Lubuntu and Elementary OS. I just keep on coming back to WattOS though which is, in my opinion, one of the best lightweight distributions around. It is stable, looks clean, has a wide range of software available and for the purposes of what I am looking to do, has an intuitive GUI. I used the 32-bit WattOS 7 distribution and installed the Linux VBAdditions into the VM.


Then from inside the running virtual distribution you need to download the http://www.enterprisedb.com install file for PostgreSQL. If it needs unzipping then do so. You should end up with a filename.run file. Change the permissions to 777 or use the following command:

sudo +x filename.run

Then run the file:

sudo ./filename.run

Accept the default locations (/opt/PostgreSQL/9.3/data), set up the password that you want for the server, accept the port number (5432) and then launch the StackBuilder when prompted. All of these values can be changed depending on the type of installation that you are looking to do. In the StackBuilder choose Spatial Extensions > PostGIS 2.1 for PostgreSQL9.3 v2.1. Allow the installer to download and install what it needs to (you’ll need to enter your PostgreSQL password to verify the install). The WattOS menu should then contain an entry for PostgreSQL that includes pgAdminIII, StackBuilder and documentation.


I went through a whole load of faff trying to get a working install of Geoserver running until I decided to read the manual and saw that there was what looked like a painless way to do it. So I did it, and it was simples.

Download the relevant Web Archive file (http://geoserver.org/display/GEOS/Download) and extract it. Install tomcat:

sudo apt-get install tomcat7

Copy the WAR file into the relevant directory and it all just works:

sudo cp geoserver.war /var/lib/tomcat7/webapps



Tagged , , , ,