[OSM-dev] MySQL on dev

Frederik Ramm frederik at remote.org
Wed May 16 13:19:04 BST 2007


> Still, I get a bit curious when I learn from the Munin graphs [1]
> that a MySQL server on "dev" processes 90 "replace" queries per
> *second*.

Tile upload, most likely. Remember that for every rendering request  
dispatched, there will be in the region of 2,000 tiles uploaded (two  
layers, one from zoom 12-17, one from zoom 12-16). Tile meta data is  
kept in the MySQL data base.

 From Upload/tile2.php:

   # Each element in TileList is a snippet of values  
(x,y,z,type,size) for each tile
   foreach($TileList as $SqlSnippet){

     $Fields = "x, y, z, type, size, date, user, version";
     $Values = sprintf("%s, now(), %d, %d", $SqlSnippet, $UserID,  

     $SQL = sprintf("replace into `tiles_meta` (%s) values (%s);",  
$Fields, $Values);


Frederik Ramm  ##  eMail frederik at remote.org  ##  N49°00.09' E008°23.33'

More information about the dev mailing list