1

I'm using the Geoserver REST interface to create new coverage stores and add geotiff files to it.

I have a zip file with multiple tiff files in it, one for each band, and would like to have them all stored under the same coverage store. The main goal is then to be able to combine bands using the coverage view.

My problem: the coverage store seems to only accept one tiff file at a time.

How can I add multiple tif files to a coverage store?

  • I ended up combining the bands into one TIFF file using gdal_merge and the -separate flag. Still interested in an answer though ;-) – Thomas Oct 4 '16 at 13:23
1

You need to specify CoverageNameCollectorSPI in your indexer.properties:

CoverageNameCollectorSPI=org.geotools.gce.imagemosaic.namecollector.FileNameRegexNameCollectorSPI:regex=_(B[018][0-9A])

This reads the band from the filename. Change the Regex to your needs, file ending is ignored.

enter image description here

You can then create Coverage Views based on that.

See the docs and this very underrated ;-) related question.

0

Try using image mosaic plugin. The plugin combines granules into a one layer ie mosaic. you should have no trouble using this.

  • OP already uses image mosaic. – pLumo Aug 24 '17 at 15:41

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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