[Tilesathome] MySQL optimization

Sebastian Spaeth Sebastian at SSpaeth.de
Thu Jul 26 11:40:32 BST 2007


Following a talk with TomH (to whom the credit has to go), I replaced 
the mySQL statements that update the tiles meta data and the blank tiles 
information.

The gist of the change is to use:
"INSERT INTO `tiles_blank` (%s) values (%s) ON DUPLICATE KEY UPDATE... "
rather than blindly do "replace into `tiles_blank` (%s) values (%s);"

The exact diff can be seen here:
http://trac.openstreetmap.org/changeset?new=sites%2Fother%2FtilesAtHome%2FUpload%2FRun%2Findex.php%403748&old=sites%2Fother%2FtilesAtHome%2FUpload%2FRun%2Findex.php%403745

This should speed up tiles updating. Next on my list is to move the 
mySQL data base files on an idle disk and improve the munin stats for 
processed tiles.

spaetz




More information about the Tilesathome mailing list