<div dir="ltr">Dea all<br><br>I am sure , my computer can access <br><a href="http://labs.metacarta.com/wms/vmap0">http://labs.metacarta.com/wms/vmap0</a><br><br>my tilecache.cfg is default one, <br>I only have changed this section <br>
<br>[cache]<br>type=DiskCache<br>base= c:\tilecache2<br><br>I have one question, do i need run setup.py in terminal? what s that for ?<br>I saw some tutorials which do not mention this setp?<br><br>Thanks in advance<br><br>
Xiaoyu<br><br><div class="gmail_quote">On Fri, Jul 18, 2008 at 12:02 PM, Guillaume Sueur &lt;<a href="mailto:guillaume.sueur@neogeo-online.net">guillaume.sueur@neogeo-online.net</a>&gt; wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
seems like the tilecache layer you are trying to generate is mis-configured. See the URLError(err). Check your tilecache.cfg, and your http access to the wms layers set into it.<br>
<br>
Guillaume<br>
<br>
Xiaoyu Guan a écrit :<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">
Hi Tibor:<br>
Thanks for your advise.<br>
as you mentioned, I just try the two link<br>
<br>
from <a href="http://127.0.0.1/tilecache/tilecache.py/1.0.0/" target="_blank">http://127.0.0.1/tilecache/tilecache.py/1.0.0/</a><br>
I got xml codes like this<br>
<br>
&lt;TileMapService version=&quot;1.0.0&quot;&gt;<br>
−<br>
&lt;TileMaps&gt;<br>
&lt;TileMap href=&quot;<a href="http://127.0.0.1/tilecache/tilecache.py/1.0.0/basic/" target="_blank">http://127.0.0.1/tilecache/tilecache.py/1.0.0/basic/</a>&quot; srs=&quot;EPSG:4326&quot; title=&quot;basic&quot; profile=&quot;global-geodetic&quot;/&gt;<br>

&lt;/TileMaps&gt;<br>
&lt;/TileMapService&gt;<br>
<br>
However, I got error when I open next link<br>
<br>
An error occurred: &lt;urlopen error (10060, &#39;Operation timed out&#39;)&gt;<br>
 &nbsp;File &quot;c:\python25\lib\site-packages\TileCache-2.04-py2.5.egg\TileCache\Service.py&quot;, line 224, in modPythonHandler<br>
<br>
 &nbsp; &nbsp;host )<br>
 &nbsp;File &quot;c:\python25\lib\site-packages\TileCache-2.04-py2.5.egg\TileCache\Service.py&quot;, line 208, in dispatchRequest<br>
 &nbsp; &nbsp;return self.renderTile(tile, params.has_key(&#39;FORCE&#39;))<br>
 &nbsp;File &quot;c:\python25\lib\site-packages\TileCache-2.04-py2.5.egg\TileCache\Service.py&quot;, line 138, in renderTile<br>
<br>
 &nbsp; &nbsp;data = layer.render(tile)<br>
 &nbsp;File &quot;c:\python25\lib\site-packages\TileCache-2.04-py2.5.egg\TileCache\Layer.py&quot;, line 437, in render<br>
 &nbsp; &nbsp;return self.renderTile(tile)<br>
 &nbsp;File &quot;c:\python25\lib\site-packages\TileCache-2.04-py2.5.egg\TileCache\Layers\WMS.py&quot;, line 29, in renderTile<br>
<br>
 &nbsp; &nbsp;tile.data, response = wms.fetch()<br>
 &nbsp;File &quot;c:\python25\lib\site-packages\TileCache-2.04-py2.5.egg\TileCache\Client.py&quot;, line 54, in fetch<br>
 &nbsp; &nbsp;response = self.client.open(urlrequest)<br>
 &nbsp;File &quot;C:\Python25\lib\urllib2.py&quot;, line 374, in open<br>
<br>
 &nbsp; &nbsp;response = self._open(req, data)<br>
 &nbsp;File &quot;C:\Python25\lib\urllib2.py&quot;, line 392, in _open<br>
 &nbsp; &nbsp;&#39;_open&#39;, req)<br>
 &nbsp;File &quot;C:\Python25\lib\urllib2.py&quot;, line 353, in _call_chain<br>
 &nbsp; &nbsp;result = func(*args)<br>
<br>
 &nbsp;File &quot;C:\Python25\lib\urllib2.py&quot;, line 1101, in http_open<br>
 &nbsp; &nbsp;return self.do_open(httplib.HTTPConnection, req)<br>
 &nbsp;File &quot;C:\Python25\lib\urllib2.py&quot;, line 1076, in do_open<br>
 &nbsp; &nbsp;raise URLError(err)<br>
<br>
<br>
Seem like the egg, doesnt work<br>
<br>
All the best<br>
<br>
Xiaoyu<br>
<br></div></div><div class="Ih2E3d">
On Fri, Jul 18, 2008 at 11:34 AM, Tibor Arpas &lt;<a href="mailto:tibor.arpas@infinit.sk" target="_blank">tibor.arpas@infinit.sk</a> &lt;mailto:<a href="mailto:tibor.arpas@infinit.sk" target="_blank">tibor.arpas@infinit.sk</a>&gt;&gt; wrote:<br>

<br>
 &nbsp; &nbsp;Hi,<br>
 &nbsp; &nbsp;I cannot really comment on your installation. But regarding the point 4.<br>
 &nbsp; &nbsp;What would you expect after opening<br>
 &nbsp; &nbsp;<a href="http://127.0.0.1/tilecache/tilecache.py" target="_blank">http://127.0.0.1/tilecache/tilecache.py</a> ?The XML looks like<br>
 &nbsp; &nbsp;everything is working fine. Did you try<br>
 &nbsp; &nbsp;<a href="http://127.0.0.1/tilecache/tilecache.py/1.0.0/" target="_blank">http://127.0.0.1/tilecache/tilecache.py/1.0.0/</a> ? And<br>
 &nbsp; &nbsp;<a href="http://127.0.0.1/tilecache/tilecache.py/1.0.0/basic/0/0/0.png" target="_blank">http://127.0.0.1/tilecache/tilecache.py/1.0.0/basic/0/0/0.png</a> ?<br>
 &nbsp; &nbsp;If that would work, your Tilecache installation is fine.<br>
<br>
 &nbsp; &nbsp;Tibor<br>
<br>
 &nbsp; &nbsp;On Fri, Jul 18, 2008 at 11:16 AM, Xiaoyu Guan &lt;<a href="mailto:guanxiaoyu@gmail.com" target="_blank">guanxiaoyu@gmail.com</a><br></div><div><div></div><div class="Wj3C7c">
 &nbsp; &nbsp;&lt;mailto:<a href="mailto:guanxiaoyu@gmail.com" target="_blank">guanxiaoyu@gmail.com</a>&gt;&gt; wrote:<br>
<br>
 &nbsp; &nbsp; &nbsp; &nbsp;Dear all<br>
 &nbsp; &nbsp; &nbsp; &nbsp;I have setup Mod python with Apache 2.2 (Python 2.5) . from the<br>
 &nbsp; &nbsp; &nbsp; &nbsp;test page, I am sure mod python it works<br>
 &nbsp; &nbsp; &nbsp; &nbsp;then I try to setup TileCache 2.04<br>
 &nbsp; &nbsp; &nbsp; &nbsp;after download setuptools-0.6c8-py2.5.egg<br>
 &nbsp; &nbsp; &nbsp; &nbsp;At first, I copy Tilecache 2.04 to /Apache2.2/cgi-bin/, use<br>
 &nbsp; &nbsp; &nbsp; &nbsp;terminal &nbsp;run setup.py, seem like nothing works, then I copy all<br>
 &nbsp; &nbsp; &nbsp; &nbsp;the file to /Apache2.2/htdocs/tilecache , run setup.py again.<br>
<br>
 &nbsp; &nbsp; &nbsp; &nbsp;according to some tutorials online, I have configured my Apache<br>
 &nbsp; &nbsp; &nbsp; &nbsp;like this:<br>
<br>
 &nbsp; &nbsp; &nbsp; &nbsp;1. Add<br>
 &nbsp; &nbsp; &nbsp; &nbsp;&lt;Directory &quot;C:/Program Files/Apache Software<br>
 &nbsp; &nbsp; &nbsp; &nbsp;Foundation/Apache2.2/htdocs/tilecache&quot;&gt;<br>
 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;AddHandler python-program .py<br>
 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;PythonHandler TileCache.Service<br>
 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;PythonOption TileCacheConfig &quot;C:/Program Files/Apache<br>
 &nbsp; &nbsp; &nbsp; &nbsp;Software Foundation/Apache2.2/htdocs/tilecache/tilecache.cfg&quot;<br>
 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;PythonPath &quot;[&#39;c:\Program Files\Apache Software<br>
 &nbsp; &nbsp; &nbsp; &nbsp;Foundation\Apache2.2\htdocs\tilecache&#39;] + sys.path&quot;<br>
 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;PythonDebug On<br>
 &nbsp; &nbsp; &nbsp; &nbsp;&lt;/Directory&gt;<br>
<br>
 &nbsp; &nbsp; &nbsp; &nbsp;to Apache httpd.conf, restart apache, no error<br>
 &nbsp; &nbsp; &nbsp; &nbsp;beside that tilecache.cfg modified like this<br>
<br>
 &nbsp; &nbsp; &nbsp; &nbsp;[cache]<br>
 &nbsp; &nbsp; &nbsp; &nbsp;type=DiskCache<br>
 &nbsp; &nbsp; &nbsp; &nbsp;base= c:\tilecache2<br>
<br>
 &nbsp; &nbsp; &nbsp; &nbsp;2. Change some python script header to &nbsp;#!C:/Python25/python.exe -u<br>
<br>
 &nbsp; &nbsp; &nbsp; &nbsp;3. I changed tilecache.cgi into tilecache.py (under<br>
 &nbsp; &nbsp; &nbsp; &nbsp;/Apache2.2/htdocs/tilecache/)index.html openlayers script like this<br>
 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;var map, layer;<br>
<br>
 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;function init(){<br>
 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;map = new OpenLayers.Map( $(&#39;map&#39;),<br>
 &nbsp; &nbsp; &nbsp; &nbsp;{&#39;maxResolution&#39;: 360/512});<br>
 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;layer = new OpenLayers.Layer.WMS( &quot;VMap0&quot;,<br>
 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&quot;/tilecache/tilecache.py?&quot;, {layers:<br>
 &nbsp; &nbsp; &nbsp; &nbsp;&#39;basic&#39;, format: &#39;image/png&#39; } );<br>
 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;map.addLayer(layer);<br>
 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;map.addControl(new OpenLayers.Control.Permalink());<br>
 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;if (!map.getCenter()) map.zoomToMaxExtent();<br>
 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;}<br>
<br>
 &nbsp; &nbsp; &nbsp; &nbsp;4. when I open <a href="http://127.0.0.1/tilecache/tilecache.py" target="_blank">http://127.0.0.1/tilecache/tilecache.py</a> without<br>
 &nbsp; &nbsp; &nbsp; &nbsp;error message, but follow xml codes<br>
 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot; ?&gt;<br></div></div>
 &nbsp; &nbsp; &nbsp; &nbsp;- &lt;#11b3584e60caad20_11b3574d15372b4f_&gt; &lt;Services&gt;<div class="Ih2E3d"><br>
 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&lt;TileMapService version=&quot;*1.0.0*&quot;<br>
 &nbsp; &nbsp; &nbsp; &nbsp;href=&quot;*<a href="http://127.0.0.1/1.0.0/*" target="_blank">http://127.0.0.1/1.0.0/*</a>&quot; /&gt;<br>
 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&lt;/Services&gt;<br>
<br>
<br>
<br>
 &nbsp; &nbsp; &nbsp; &nbsp;now I could not find where error is ? is there anybody have same<br>
 &nbsp; &nbsp; &nbsp; &nbsp;problems before ?<br>
 &nbsp; &nbsp; &nbsp; &nbsp;Thanks in advance<br>
<br>
 &nbsp; &nbsp; &nbsp; &nbsp;All the best<br>
 &nbsp; &nbsp; &nbsp; &nbsp;--  &nbsp; &nbsp; &nbsp; &nbsp;Xiaoyu Guan (Sam)<br>
 &nbsp; &nbsp; &nbsp; &nbsp;Geo-information Science<br>
 &nbsp; &nbsp; &nbsp; &nbsp;Wageningen UR<br>
<br>
 &nbsp; &nbsp; &nbsp; &nbsp;_______________________________________________<br>
 &nbsp; &nbsp; &nbsp; &nbsp;Tilecache mailing list<br></div>
 &nbsp; &nbsp; &nbsp; &nbsp;<a href="mailto:Tilecache@openlayers.org" target="_blank">Tilecache@openlayers.org</a> &lt;mailto:<a href="mailto:Tilecache@openlayers.org" target="_blank">Tilecache@openlayers.org</a>&gt;<div class="Ih2E3d"><br>

 &nbsp; &nbsp; &nbsp; &nbsp;<a href="http://openlayers.org/mailman/listinfo/tilecache" target="_blank">http://openlayers.org/mailman/listinfo/tilecache</a><br>
<br>
<br>
<br>
<br>
<br>
-- <br>
Xiaoyu Guan (Sam)<br>
Geo-information Science<br>
Wageningen UR<br>
<br>
<br></div>
------------------------------------------------------------------------<div class="Ih2E3d"><br>
<br>
_______________________________________________<br>
Tilecache mailing list<br>
<a href="mailto:Tilecache@openlayers.org" target="_blank">Tilecache@openlayers.org</a><br>
<a href="http://openlayers.org/mailman/listinfo/tilecache" target="_blank">http://openlayers.org/mailman/listinfo/tilecache</a><br>
</div></blockquote>
<br>
-- <br>
<br>
<br>
</blockquote></div><br><br clear="all"><br>-- <br>Xiaoyu Guan (Sam)<br>Geo-information Science<br>Wageningen UR<br>
</div>