1

I try to set up an OSM tile server using tirex on a server running Ubuntu server 16.04 LTS 64-bit. In the style definition (opentopomap.xml) there are several gdal data sources definied. E.g. the following color relief layer:

<Layer name="relief-5000">
<StyleName>relief-5000</StyleName>
<Datasource>
    <Parameter name="type">gdal</Parameter>
    <Parameter name="file">dem/relief-5000.tif</Parameter>
    <Parameter name="format">tiff</Parameter>
</Datasource>

At the relative path to the style-file (dem/relief-5000.tif) I have the tiff file with the following access rights:

-rwxr-xr-x 1 postgres postgres 8866 Feb  5 01:29 relief-5000.tif*

My tirex user is in the postgres group and should be able to read the layer's file

uid=112(tirex) gid=119(tirex) groups=119(tirex),118(postgres)

But when I start tirex and check /var/log/daemon.log I get the following error message:

Feb  5 10:27:23 ubuntu-server tirex-backend-mapnik[4739]: 
Renderer started (name=mapnik)

Feb  5 10:27:23 ubuntu-server tirex-backend-mapnik[4739]: 
cannot add /etc/tirex/renderer/mapnik/opentopomap.conf

Feb  5 10:27:23 ubuntu-server tirex-backend-mapnik[4739]: 
Could not create datasource for type: 'gdal' 
(no datasource plugin directories have been successfully registered)  
encountered during parsing of layer 'relief-5000' in Layer at line 24 of 
'/usr/share/osm-styles/OpenTopoMap/mapnik/opentopomap.xml'

I have installed the packages gdal-bin python-gdal libgdal-dev. Is there any special configuration for gdal datasources required or a possibility to get more fine grained log-messages to estimate the reason, why this datasource file cannot be accessed?

1 Answer 1

2

After some further investigation of this issue I found the solution: Mapnik's data sources weren't recognized at all.

Workaround: in

/etc/tirex/renderer/mapnik.conf

change:

plugindir=/usr/lib/mapnik/3.0/input # mapnik-config --input-plugins
1
  • Thank you, my installation didn't have the 3.0 version in the path.
    – Alan
    Commented Aug 14, 2018 at 19:02

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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