<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="Generator" content="Microsoft Word 15 (filtered medium)">
<style><!--
/* Font Definitions */
@font-face
{font-family:"Cambria Math";
panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
{font-family:Calibri;
panose-1:2 15 5 2 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0cm;
margin-bottom:.0001pt;
font-size:12.0pt;
font-family:"Times New Roman",serif;}
a:link, span.MsoHyperlink
{mso-style-priority:99;
color:blue;
text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
{mso-style-priority:99;
color:purple;
text-decoration:underline;}
span.Shkpostityyli17
{mso-style-type:personal;
font-family:"Calibri",sans-serif;
color:#1F497D;}
span.Shkpostityyli18
{mso-style-type:personal-reply;
font-family:"Calibri",sans-serif;
color:#1F497D;}
.MsoChpDefault
{mso-style-type:export-only;
font-size:10.0pt;}
@page WordSection1
{size:612.0pt 792.0pt;
margin:72.0pt 72.0pt 72.0pt 72.0pt;}
div.WordSection1
{page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
</head>
<body lang="FI" link="blue" vlink="purple">
<div class="WordSection1">
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D;mso-fareast-language:EN-US">Hi,<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D;mso-fareast-language:EN-US"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D;mso-fareast-language:EN-US">I copied your XML definition file and made a test with GDAL. My command was:<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D;mso-fareast-language:EN-US">gdal_translate -outsize 400 400 rest.xml out.tif --debug o<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D;mso-fareast-language:EN-US"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D;mso-fareast-language:EN-US">Result is an error:<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D;mso-fareast-language:EN-US"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D;mso-fareast-language:EN-US">0ERROR 1: GDALWMS: Unable to download block 0, 0.<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D;mso-fareast-language:EN-US"> URL: http://maps.six.nsw.gov.au/arcgis/rest/services/sixmaps/LPI_Imagery_Best/<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D;mso-fareast-language:EN-US">MapServer<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D;mso-fareast-language:EN-US"> /export?f=image&bbox=15300000.00000000,-5070000.00000000,17810000.00000000,-<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D;mso-fareast-language:EN-US">2950000.00000000&size=256,256&dpi=&imageSR=3857&bboxSR=3857&format=image/jpeg&la<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D;mso-fareast-language:EN-US">yerdefs=&layers=&transparent=false&time=&layerTimeOptions=&dynamicLayers=<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D;mso-fareast-language:EN-US"> HTTP status code: 400, error: (null).<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D;mso-fareast-language:EN-US">Add the HTTP status code to <ZeroBlockHttpCodes> to ignore that error (see http:<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D;mso-fareast-language:EN-US">//www.gdal.org/frmt_wms.html).<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D;mso-fareast-language:EN-US">ERROR 1: rest.xml, band 1: IReadBlock failed at X offset 0, Y offset 0
<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D;mso-fareast-language:EN-US"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D;mso-fareast-language:EN-US">With another proxy I get similar error but different code<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D;mso-fareast-language:EN-US">HTTP status code: 0, error: (null).<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D;mso-fareast-language:EN-US"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D;mso-fareast-language:EN-US">The request is OK and shows a map when sent through a browser.<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D;mso-fareast-language:EN-US"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D;mso-fareast-language:EN-US">Fiddler proxy gives a short explanation about what goes wrong and it says that the request headers can’t be parsed. I
do not understand what it means but it looks obvious that the issue is in GDAL, not in Mapserver.<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D;mso-fareast-language:EN-US"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D;mso-fareast-language:EN-US">Even R. may be reading but you can also send mail to gdal-dev list. Include your XML file and ask why gdal_translate -outsize
400 400 rest.xml out.tif --debug o<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D;mso-fareast-language:EN-US">gives an error.<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D;mso-fareast-language:EN-US"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D;mso-fareast-language:EN-US"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D;mso-fareast-language:EN-US">-Jukka Rahkonen-<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D;mso-fareast-language:EN-US"><o:p> </o:p></span></p>
<div>
<div style="border:none;border-top:solid #E1E1E1 1.0pt;padding:3.0pt 0cm 0cm 0cm">
<p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif">Robert Sanson wrote:<br>
<br>
<o:p></o:p></span></p>
</div>
</div>
<p class="MsoNormal"><span lang="EN-US"><o:p> </o:p></span></p>
<div>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D">Hi<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D">I am trying to cascade a remote ESRI REST image service via my Mapserver mapfile.<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D">Here is my XML file:<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"><GDAL_WMS><o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"> <Service name="AGS"><o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"> <ServerUrl><o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D">
<a href="http://maps.six.nsw.gov.au/arcgis/rest/services/sixmaps/LPI_Imagery_Best/MapServer">
http://maps.six.nsw.gov.au/arcgis/rest/services/sixmaps/LPI_Imagery_Best/MapServer</a><o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"> </ServerUrl><o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"> <BBoxOrder>xyXY</BBoxOrder><o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"> <SRS>3857</SRS><o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"> <ImageFormat>image/jpeg</ImageFormat><o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"> </Service><o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"> <DataWindow><o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"> <UpperLeftX>1.53E7</UpperLeftX><o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"> <UpperLeftY>-2950000.0</UpperLeftY><o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"> <LowerRightX>1.781E7</LowerRightX><o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"> <LowerRightY>-5070000.0</LowerRightY><o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"> <SizeX>256</SizeX><SizeY>256</SizeY><o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"> </DataWindow><o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"></GDAL_WMS><o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D">Here is my mapfile layer:<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D">LAYER<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"> NAME sixmaps<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"> GROUP 'highres'<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"> TYPE RASTER<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"> STATUS ON<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"> DATA "/mnt/gisdata/data/aus/sixmaps.xml"<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"> PROCESSING "OVERSAMPLE_RATIO=1.0"<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"> PROJECTION<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"> "init=epsg:3857"<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"> END<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"> METADATA<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"> "wms_title" "sixmaps"<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"> "wms_name" "sixmaps"<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"> "wms_srs" "EPSG:3857"<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"> END<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D">END<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D">When I try and request a map using a WMS GetMap request, this is the error message I get:<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"><?xml version='1.0' encoding="ISO-8859-1" standalone="no" ?><o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"><!DOCTYPE ServiceExceptionReport SYSTEM "<a href="http://schemas.opengis.net/wms/1.1.1/exception_1_1_1.dtd">http://schemas.opengis.net/wms/1.1.1/exception_1_1_1.dtd</a>"><o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"><ServiceExceptionReport version="1.1.1"><o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"><ServiceException><o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D">msDrawMap(): Image handling error. Failed to draw layer named 'sixmaps'.<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D">drawGDAL(): Unable to access file. GDALDatasetRasterIO() failed: GetBlockRef failed at X block offset 0, Y block offset 0<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"></ServiceException><o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"></ServiceExceptionReport><o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D">Can anyone point out where the problem is?<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D">Many thanks,<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-NZ" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1F497D"><br>
Robert L. Sanson<o:p></o:p></span></p>
</div>
</div>
</body>
</html>