Peter Körner schrieb:
Soo jetzt melde ich mich hier auch mal auf der Liste, Sven hat mich ja schonmal erwähnt. Ich habe grade einen planet-import im hstore-modus gestartet, das logfile kann eingesehen / verfolgt werden: tail -c100 -f /osm/planet_osm_hstore.import.log
Endlich ist er durch, hat wirklich lange gedauert. Heute Vormittag habe ich dann die Tag- und Pending-Indexe angelegt und die Planet-Datenbank sollte jetzt nutzbar sein. Im Anhang mal ein paar Laufzeiten für Tag-Only-Queries. Die sind, wenn man mal vom Query-Cache absieht, phänomenal schlecht. Ich hoffe, dass das besser wird, wenn wir zum rendern immer nur relativ kleine geographische Bereiche selektieren. Für die interessierten habe ich auch noch was zum Speicherplatzverbrauch angehängt. Lg, Peter hstore-rendering=> explain analyze select * from planet_osm_hstore_point where (tags ? 'tactile_paving') and (tags->'tactile_paving' = 'yes'); QUERY PLAN --------------------------------------------------------------------------------------------------------------------------------------------------- Bitmap Heap Scan on planet_osm_hstore_point (cost=1199.23..63438.92 rows=91 width=285) (actual time=349.077..40768.106 rows=1779 loops=1) Recheck Cond: (tags ? 'tactile_paving'::text) Filter: ((tags -> 'tactile_paving'::text) = 'yes'::text) -> Bitmap Index Scan on planet_osm_hstore_point_tags (cost=0.00..1199.21 rows=18197 width=0) (actual time=259.824..259.824 rows=3060 loops=1) Index Cond: (tags ? 'tactile_paving'::text) Total runtime: 40769.683 ms (6 Zeilen) hstore-rendering=> explain analyze select * from planet_osm_hstore_point where ((tags ? 'traffic_signals:sound') and (tags->'traffic_signals:sound' = 'yes')) or ((tags ? 'traffic_signals:vibration') and (tags->'traffic_signals:vibration' = 'yes')); QUERY PLAN ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- Bitmap Heap Scan on planet_osm_hstore_point (cost=2398.51..117486.30 rows=182 width=285) (actual time=240.538..13791.933 rows=445 loops=1) Recheck Cond: ((tags ? 'traffic_signals:sound'::text) OR (tags ? 'traffic_signals:vibration'::text)) Filter: (((tags ? 'traffic_signals:sound'::text) AND ((tags -> 'traffic_signals:sound'::text) = 'yes'::text)) OR ((tags ? 'traffic_signals:vibration'::text) AND ((tags -> 'traffic_signals:vibration'::text) = 'yes'::text))) -> BitmapOr (cost=2398.51..2398.51 rows=36395 width=0) (actual time=177.850..177.850 rows=0 loops=1) -> Bitmap Index Scan on planet_osm_hstore_point_tags (cost=0.00..1199.21 rows=18197 width=0) (actual time=138.243..138.243 rows=517 loops=1) Index Cond: (tags ? 'traffic_signals:sound'::text) -> Bitmap Index Scan on planet_osm_hstore_point_tags (cost=0.00..1199.21 rows=18197 width=0) (actual time=39.601..39.601 rows=173 loops=1) Index Cond: (tags ? 'traffic_signals:vibration'::text) Total runtime: 13792.710 ms (9 Zeilen) hstore-rendering=> analyze planet_osm_hstore_point; hstore-rendering=> explain analyze select count(*) from planet_osm_hstore_point where (tags ? 'amenity') and (tags->'amenity' = 'restaurant'); QUERY PLAN ------------------------------------------------------------------------------------------------------------------------------------------------------------ Aggregate (cost=63590.20..63590.21 rows=1 width=0) (actual time=531199.646..531199.647 rows=1 loops=1) -> Bitmap Heap Scan on planet_osm_hstore_point (cost=1199.60..63589.97 rows=91 width=0) (actual time=861.815..531145.289 rows=103681 loops=1) Recheck Cond: (tags ? 'amenity'::text) Filter: ((tags -> 'amenity'::text) = 'restaurant'::text) -> Bitmap Index Scan on planet_osm_hstore_point_tags (cost=0.00..1199.58 rows=18246 width=0) (actual time=659.492..659.492 rows=1806955 loops=1) Index Cond: (tags ? 'amenity'::text) Total runtime: 531206.997 ms (7 Zeilen) hstore-rendering=> select * from planet_osm_size; name | kind | size ---------------------------------+-------+------------ planet_osm_hstore_ways | table | 44 GB planet_osm_hstore_nodes | table | 39 GB planet_osm_hstore_ways_nodes | index | 25 GB planet_osm_hstore_line | table | 23 GB planet_osm_hstore_nodes_pkey | index | 12 GB planet_osm_hstore_point | table | 7798 MB planet_osm_hstore_polygon | table | 7144 MB planet_osm_hstore_line_tags | index | 4576 MB planet_osm_hstore_roads | table | 2821 MB planet_osm_hstore_point_tags | index | 2047 MB planet_osm_hstore_line_index | index | 1891 MB planet_osm_hstore_ways_pkey | index | 1553 MB planet_osm_hstore_polygon_tags | index | 1162 MB planet_osm_hstore_point_index | index | 1062 MB planet_osm_hstore_ways_pending | index | 931 MB planet_osm_hstore_line_pkey | index | 705 MB planet_osm_hstore_polygon_index | index | 645 MB planet_osm_hstore_roads_tags | index | 412 MB planet_osm_hstore_point_pkey | index | 390 MB planet_osm_hstore_rels | table | 385 MB planet_osm_hstore_ways_idx | index | 267 MB planet_osm_hstore_polygon_pkey | index | 222 MB planet_osm_hstore_roads_index | index | 179 MB planet_osm_hstore_rels_parts | index | 144 MB planet_osm_hstore_roads_pkey | index | 70 MB planet_osm_hstore_rels_pending | index | 10160 kB planet_osm_hstore_rels_pkey | index | 10152 kB planet_osm_hstore_rels_idx | index | 8192 bytes planet_osm_size | view | 0 bytes (29 Zeilen)