[OSM-dev] Slow Osmosis

Andreas Kalsch andreaskalsch at gmx.de
Mon Dec 1 13:49:55 GMT 2008


Brett Henderson schrieb:
> Whenever I have seen that error in the past it has been because I have 
> data in the tables already.  Changing table types shouldn't have any 
> effect on duplicate key checks.  It'd be worth double checking to make 
> absolutely sure you have no data in the tables already.
I am very sure. I added an exit ...
>
> Andreas Kalsch wrote:
>> Yes I drop the database completely - part of my shell script:
>>
>> echo 'Create database, create tables ..'
>> mysql -u $mysql_user -p$mysql_pw -e "DROP DATABASE IF EXISTS 
>> $db_name;CREATE DATABASE $db_name DEFAULT CHARACTER SET utf8 COLLATE 
>> utf8_general_ci;"
>>
>> date
>>
>> mysql -u $mysql_user -D $db_name -p$mysql_pw < 
>> jobs/osm_schema_latest_optimized0.sql
... here and checked the database: All tables are existing and empty.
>>
>> echo 'Write to database ..'
>> osmosis/bin/osmosis --read-xml file=$uncompressedFile --write-mysql 
>> host=localhost database=$db_name user=$mysql_user password=$mysql_pw 
>> validateSchemaVersion=no
>>
>> mysql -u $mysql_user -D $db_name -p$mysql_pw < 
>> jobs/osm_schema_latest_optimized1.sql
>>
>> date 
So, probably these constructs (I don't know what thy do), cause trouble:

/*!40000 ALTER TABLE `sessions` DISABLE KEYS */;

(?)

Andi




More information about the dev mailing list