Version 1 (modified by astephen, 11 years ago) (diff)


Getting started with COWS server and COWS client

This page provides a quick overview on how to get started with a COWS server and COWS client applications.

Setting up an example COWS server

Here is a basic set of instructions for setting up a cowsserver instance with an example dataset. In the examples below it is assumed your test dataset CSML file has been called mydataset.xml. Note that this assumes you have installed all the dependencies and that their scripts are in your path:

  1. Create your CSML file describing an example NetCDF file:
# I'm going to use a NetCDF file called '' in $MYDATA dir
# I'll create my CSML file describing that data as '$MYDATA/mydataset.xml'

$ cd $MYDATA
$ csmlscan -i mydataset -N "My Dataset" -o mydataset.xml
# Which writes: $MYDATA/mydataset.xml
  1. Modify the pylons app configuration file development.ini to point at local paths and the required port:


  1. Go to the top-level directory containing the development.ini file and start the service:

The service can be run using paster or mod_wsgi, this example uses paster.

$ paster serve development.ini
  1. Now open a browser and look at the top-level catalogue page:

Note that the URL http://<host>:<port>/ will route to the "catalogue" controller in the pylons app that shows, for each dataset (CSML file), the following links:

  * WMS GetCapabilities - http://<host>:<port>/<dataset_id>/wms?service=WMS&request=GetCapabilities&id=None
  * WCS GetCapabilities - http://<host>:<port>/<dataset_id>/wcs?service=WCS&request=GetCapabilities&id=None
  * WMS GetCapabilities - http://<host>:<port>/<dataset_id>/wfs?service=WFS&request=GetCapabilities&id=None

  * WMS GetCapabilities -
  * WCS GetCapabilities -
  * WMS GetCapabilities -
  1. Make a WMS GetLegend call:

If you investigate the layer names in the WMS GetCapabilities document (see above) then you can use a layer name to generate a request based on the template below:

  * template - http://<host>:<port>/<dataset_id>/wms?request=GetLegend&layers=<layer_name>
  * example -
  1. Make a WMS GetMap call:

Insertion of the layer name into the template below should return a Map tile:

  * template - http://<host>:<port>/<dataset_id>/wms?SRS=EPSG%3A4326&VERSION=1.1.1&FORMAT=image%2Fpng&SERVICE=WMS&REQUEST=GetMap&STYLES=&EXCEPTIONS=application%2Fvnd.ogc.se_inimage&TIME2794-12-01T00:00:00.0=&LAYERS=<layer_name>&BBOX=-29%2C-20%2C50%2C50&WIDTH=256&HEIGHT=256

  * example -

Setting up an example COWS client application

The main cowsclient is currently the wmsviz controller that is served under http://<host>:<port>/wmsviz.

  1. Modify the development.ini configuration file:

Go to the top-level cowsclient directory and modify the development.ini file and make changes (if you are not using the defaults).

# Example changes to development.ini, if serving data from (host=westerly and port=844):
port = 8443
  1. Modify the avilalable end points:

The cowsclient can be provided with various endpoints (URLs to WMS service capabilities) but can also be given endpoints interactively. Here are a few WMS end points (some of which are secured) that might be useful:

Public WMS endpoints


Secured WMS endpoints

  1. Deploy the service using paster:
$ paster serve development.ini
  1. View the wmsviz controller from a browser:

Open the following page in a browser:

  * template - http://<host>:<port>/wmsviz
  * example  -