On Tue, Sep 28, 2010 at 12:31 PM, Nakor <[email protected]> wrote: > On 09/27/2010 08:42 PM, Brett Henderson wrote: > > On Tue, Sep 28, 2010 at 10:25 AM, Nakor <[email protected] <mailto: >> [email protected]>> wrote: >> >> On 09/24/2010 09:52 AM, Nakor wrote: >> >> Brett, >> >> I should have read the whole documentation first. I am using >> --write-pgsql . I'll let it continue (as I am now over 200 Gb) >> and see how it goes. Next time I need to import I will >> probably just import the US vs the whole planet. Thanks for >> your input it gives a rough idea. >> >> Thanks, >> >> N. >> >> >> It finished in 7 days and 17hours. The DB is 260Gb. Note that some >> speed loss is probably due to the fact that the only disk where I >> had space to store the DB is encrypted. >> >> Okay, cool. >> >> Which version of the schema are you using? Is it the version 5 schema >> that comes with Osmosis 0.36, or the version 6 schema that comes with >> Osmosis 0.37-SNAPSHOT? The version 6 schema takes much longer to import if >> you have the optional bbox or linestring columns on the ways table, but the >> query performance is much improved due to table CLUSTERing. >> >> Brett >> >> >> I am using 0.36 and have the bbox column activated. > > BTW is there a way to migrate an existing DB from a schema version to > another or is the only route re-importing the whole base? >
Yep, I have provided migration scripts for the last couple of upgrades. But I'd recommend running each step in the script manually in case one step fails. The latest version drops the tags tables so you need to make sure all prior steps execute successfully before the drops. The version 6 schema is quite different to the version 5 schema because it uses hstore columns for tags instead of separate tables. It drastically improves performance on large result sets. It will take a number of days to complete the upgrade though ... I don't expect the schema to change further before Osmosis 0.37 is released, but I still have at least one bug in Osmosis code that queries the database. Bounding box queries don't work if the bbox column is added to the ways table, only if the linestring column is added. > > Also what is the benefit of the linestring column? > It depends on what you're doing. It's a full geometry of each way which allows you to run proper PostGIS queries against them. I particularly like it because it allows bounding box style queries to include ways crossing a bounding box but without nodes inside the box. Brett
_______________________________________________ osmosis-dev mailing list [email protected] http://lists.openstreetmap.org/listinfo/osmosis-dev
