Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

imported data by using Osm2pgsql, to get rid off all problems related to data conversion, i stored this as latlong (-l parameter).I created stylesheet, and i tested with python script and it was working (so both data and stylesheet should be fine). Here comes problem..., when i tried to use it with open layers, i got my basic layer covered by pinkish "image not found" tile, but when i try to access tile by calling cgi script "http://localhost/tc/tilecache.cgi/1.0.0/osm/5/31/26.png" i have nicely generated tile

is any one have idea what i'm doing wrong? files:


    <Map background-color="#00000000" srs="+proj=latlong +datum=WGS84">
  <Style name="roadStyle">

      <LineSymbolizer stroke="#ff0000" stroke-width="100" />


  <Layer name="roads" srs="+proj=latlong +datum=WGS84">
     <Parameter name="table">
       (select way,highway from planet_osm_line where highway in ('motorway','motorway_link','trunk','trunk_link','primary','primary_link','secondary','secondary_link','tertiary','tertiary_link','residential','unclassified') order by z_order) as roads

    <Parameter name="type">postgis</Parameter>

    <Parameter name="user">www-data</Parameter>
    <Parameter name="password">gis</Parameter>
    <Parameter name="dbname">gis</Parameter>
    <Parameter name="estimate_extent">true</Parameter>







definition of my layers

var map = new OpenLayers.Map('map',
        numZoomLevels: 12,
        projection: new OpenLayers.Projection("EPSG:4326"),
        displayProjection: new OpenLayers.Projection("EPSG:4326")

var layer = new OpenLayers.Layer.WMS( "VMap0", 
                "tilecache.cgi?", {layers: 'basic', format: 'image/png' } );
var tms = new OpenLayers.Layer.WMS( "osm","tilecache/tilecache.cgi?",
      { layers:'osm',  format: 'image/png'},{ isBaseLayer: false}  );  
share|improve this question

Not enough reputation so can't add a comment.

There can be multiple reasons behind it,

Firstly, did you check the server logs? Apache for instance. Might be an issue with the permissions.

Also, I am not much aware of TileCache have been using ModTile and Renderd ( so not aware of the logging of TileCache. Can you check tilecache logs?

Also, make sure you have configured your server (Apache in my case) properly with TileCache

Hope that helps.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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