I think you need to add some parameters to the LAYER METADATA section of your mapfile. Like this:<br><br> METADATA<br> "wms_srs" "EPSG:4326 EPSG:102004 EPSG:900913"<br> "wms_name" "states"<br>
"wms_server_version" "1.1.1"<br> "wms_format" "image/png"<br> "wms_onlineresource" "<a href="http://localhost/cgi-bin/mapserv?map=/var/www/mapfiles/states/states.map&">http://localhost/cgi-bin/mapserv?map=/var/www/mapfiles/states/states.map&</a>"<br>
END<br>--<br><br><div class="gmail_quote">On Sat, Oct 25, 2008 at 5:36 AM, Christopher Schmidt <span dir="ltr"><<a href="mailto:crschmidt@metacarta.com">crschmidt@metacarta.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div><div></div><div class="Wj3C7c">On Sat, Oct 25, 2008 at 02:21:38PM +0200, Damiano Morosi wrote:<br>
> Hi all,<br>
><br>
> this is the first time I use Tilecache. I'm trying to generate tiles for a<br>
> Map (that I can visualize successfully in OpenLayers with Mapserver). The<br>
> .map file is as following:<br>
><br>
> ----<br>
><br>
> #<br>
> # Start of map file<br>
> #<br>
> #<br>
> NAME NAVSTREETS<br>
> STATUS ON<br>
> SIZE 600 600<br>
> SYMBOLSET "/var/www/maps/symbols.sym"<br>
> EXTENT 12 41 13 42<br>
><br>
> SHAPEPATH "/var/www/shapes/"<br>
> IMAGETYPE png<br>
> IMAGECOLOR 150 150 150<br>
><br>
> #<br>
> # Start of web interface definition<br>
> #<br>
> WEB<br>
> #MINSCALE 2000000<br>
> #MAXSCALE 50000000<br>
> IMAGEPATH "/tmp/ms_tmp/"<br>
> IMAGEURL "/ms_tmp/"<br>
> METADATA<br>
> "wms_title" "navstreet map"<br>
> "wms_onlineresource" "<a href="http://213.199.15.252/cgi-bin/mapserv?map=ms.map&" target="_blank">http://213.199.15.252/cgi-bin/mapserv?map=ms.map&</a>"<br>
><br>
> END<br>
> TEMPLATE "test.html"<br>
> END<br>
><br>
> # Layers<br>
><br>
> LAYER<br>
> METADATA<br>
> "queryable" "true"<br>
> "wms_title" "GreenA"<br>
> END<br>
><br>
> TEMPLATE "test.html"<br>
><br>
> NAME GreenA<br>
> TYPE POLYGON<br>
> STATUS ON<br>
><br>
> DATA LandUseA<br>
> CLASS<br>
> NAME "Streets"<br>
> OUTLINECOLOR 0 255 0<br>
> COLOR 0 255 0<br>
> END<br>
> END # layer<br>
><br>
> END # MAP<br>
><br>
> ----<br>
><br>
> The following is my tilecache.cfg file:<br>
><br>
> ----<br>
><br>
> [cache]<br>
> base = /tmp/tilecache<br>
> type = Disk<br>
><br>
> [basic]<br>
> layers = GreenA<br>
> spherical_mercator = no<br>
> data_extent = 12,41,13,42<br>
> extension = png<br>
> url = <a href="http://213.199.15.252/cgi-bin/mapserv?map=ms.map" target="_blank">http://213.199.15.252/cgi-bin/mapserv?map=ms.map</a><br>
> metatile = no<br>
> bbox = 12,41,13,42<br>
> type = WMS<br>
><br>
> ----<br>
><br>
> The layer is deriving from a shapefile. Then I try the command:<br>
><br>
> python tilecache_seed.py "<a href="http://213.199.15.252/cgi-bin/tilecache.cgi" target="_blank">http://213.199.15.252/cgi-bin/tilecache.cgi</a>?"<br>
> basic 0 5<br>
><br>
> and I get the error<br>
><br>
> msWMSLoadGetMapParams(): WMS server error. Invalid SRS given : SRS must be<br>
> valid for all requested layers.<br>
><br>
> The point is that I don't want to project my map, so as far as I know, I<br>
> haven't to set a projection object in mapfile. Is it mandatory to fullfill<br>
> the tilecache requisites? How can I produce tiles from map that are usable<br>
> by OpenLayers?<br>
<br>
</div></div>You need to set up your mapfile for WMS.<br>
<br>
<a href="http://mapserver.gis.umn.edu/docs/howto/wms_server" target="_blank">http://mapserver.gis.umn.edu/docs/howto/wms_server</a><br>
<a href="http://mapserver.gis.umn.edu/docs/howto/wms_server/#setup-a-mapfile-for-your-wms" target="_blank">http://mapserver.gis.umn.edu/docs/howto/wms_server/#setup-a-mapfile-for-your-wms</a><br>
<div class="Ih2E3d"><br>
> Thank you all,<br>
><br>
> Damiano Morosi<br>
<br>
</div>> _______________________________________________<br>
> Tilecache mailing list<br>
> <a href="mailto:Tilecache@openlayers.org">Tilecache@openlayers.org</a><br>
> <a href="http://openlayers.org/mailman/listinfo/tilecache" target="_blank">http://openlayers.org/mailman/listinfo/tilecache</a><br>
<font color="#888888"><br>
<br>
--<br>
Christopher Schmidt<br>
MetaCarta<br>
_______________________________________________<br>
Tilecache mailing list<br>
<a href="mailto:Tilecache@openlayers.org">Tilecache@openlayers.org</a><br>
<a href="http://openlayers.org/mailman/listinfo/tilecache" target="_blank">http://openlayers.org/mailman/listinfo/tilecache</a><br>
</font></blockquote></div><br>