[OpenStreetMap] #4613: Installing fresh openstreetmap database fails

OpenStreetMap trac at noreply.openstreetmap.org
Mon Oct 8 03:18:17 BST 2012


#4613: Installing fresh openstreetmap database fails
-----------------------+-------------------------
  Reporter:  yurivict  |      Owner:  rails-dev@…
      Type:  defect    |     Status:  new
  Priority:  minor     |  Milestone:
 Component:  website   |    Version:
Resolution:            |   Keywords:
-----------------------+-------------------------

Comment (by jfire):

 That particular error indicates you need to install the btree_gist
 extension. For Postgres > 9 the command is `psql -d openstreetmap -c
 "CREATE EXTENSION btree_gist;"`.

 In general you want to be running `rake db:setup` to initialize a new
 development database rather than `rake db:migrate`, which will create the
 database from `db/schema.rb` or `db/structure.sql` (the latter, in the
 case of the OSM Rails app). Unfortunately, our `db/structure.sql`has some
 hard-coded paths which need to be adjusted in order to run successfully.
 This took me a while to figure out when I was first getting going. It
 would make things easier for new contributors if we could customize the
 `db:setup` task such that it worked out of the box, perhaps by generating
 `db/structure.sql` from a `db/structure.sql.erb` file. However, that would
 also necessitate either manually editing `db/structure.sql.erb` when the
 schema changes, or also customizing the `db:structure:dump` task to write
 the .erb file.

-- 
Ticket URL: <https://trac.openstreetmap.org/ticket/4613#comment:1>
OpenStreetMap <http://www.openstreetmap.org/>
OpenStreetMap is a free editable map of the whole world



More information about the rails-dev mailing list