0

I need to cascade a WMTS service via MapServer. I used gdal_translate to obtain an XML file. The XML file loads correctly in QGIS.

Meanwhile, when I test MapServer I get the following error :

msDrawRasterLayerLow(): Unable to access file. Corrupt, empty or missing file '[...].xml' for layer 'global_png'. Cannot parse CRS 'urn:ogc:def:crs:EPSG:2154'

gdalinfo and gdal_translate don't return error. I needed to define GDAL_DATA environnement variable. I tryed to define PROJ_LIB too but this didn't solve or modify the error message.

Here is the mapfile layer:

LAYER

    NAME "global_png"
    STATUS ON
    
    TYPE RASTER
    UNITS METERS
    DEBUG 5
    
    DATA "file.xml"
    EXTENT 200635.1160934336 6775687.697226753 344228.7212134335 6895858.930506754
    
    
    METADATA    
        "wms_srs"       "EPSG:2154"
        "wms_title"    "title (png)"
        "wms_format"    "image/png"
        "wms_name"      "global_png"
        
    END # METADATA
    
END
4
  • 1
    Please write a minimal but complete mapfile that others can use easily for testing. If the WMTS service that you use is not open then use some open WMTS instead, for example demo.mapserver.org/mapcache/wmts/…
    – user30184
    Commented Oct 24, 2023 at 13:50
  • Where do you set the projection in the map file? In the GetCapabilities response does mapserver report any errors?
    – nmtoken
    Commented Oct 24, 2023 at 17:00
  • It looks that the WMTS service i try to cascade encounters a malfunction. My question should be standby.
    – jonath_gis
    Commented Oct 25, 2023 at 7:17
  • Could you you make it work?
    – user30184
    Commented Apr 15 at 17:49

0

Your Answer

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

Browse other questions tagged or ask your own question.