x

osm2pgsql kein Datenexport


  1. osm2pgsql kein Datenexport · Mehmet_C (Gast) · 15.05.2009 21:07 · [flux]

    Moin,

    weiß einer warum, nach dem Eingeben des nachfolgend aufgeführten Befehls, keine Daten in die Datenbank oder in die angegebene Datei (export.sql) geschrieben werden?

    C:\osm2pgsql>osm2pgsql -U postgres -d routing osnabrueck.osm > export.sql

    Ausgabe:

    osm2pgsql SVN version 0.55-20081113 $Rev: 10464 $

    Using projection SRS 900913 (Spherical Mercator)
    Setting up table: planet_osm_point
    Setting up table: planet_osm_line
    Setting up table: planet_osm_polygon
    Setting up table: planet_osm_roads
    Mid: Ram, scale=100

    Reading in file: jo.osm
    StartElement: Unknown element name: bounds
    EndElement: Unknown element name: bounds
    Processing: Node(12k) Way(1k) Relation(0k)
    Node stats: total(12644), max(393897777)
    Way stats: total(1858), max(34338222)
    Relation stats: total(7), max(93919)

    Writing way(0k)

    Danke im voraus und Grüße


    System: Windows XP, PostgreSQL 8.3, PostGIS 1.3.5


    • Re: osm2pgsql kein Datenexport · MontyM (Gast) · 17.05.2009 15:10 · [flux]

      Ich mache das immer ohne pipe (>).

      z.B.: osm2pgsql -s -c -d postgis -U postgres -W oberpfalz.osm.bz2


    • Re: osm2pgsql kein Datenexport · Mehmet_C (Gast) · 17.05.2009 17:01 · [flux]

      hi,

      ne geht auch so nicht. Es wird nichts in die Datenbank reingeschrieben.

      mit der Option -s bekomme ich das hier angezeigt:

      C:\osm2pgsql>osm2pgsql -m -s -c -d routing -U postgres -W jo.osm
      osm2pgsql SVN version 0.55-20081113 $Rev: 10464 $

      Password:
      Using projection SRS 900913 (Spherical Mercator)
      Setting up table: planet_osm_point
      Setting up table: planet_osm_line
      Setting up table: planet_osm_polygon
      Setting up table: planet_osm_roads
      Mid: pgsql, scale=100, cache=800MB, maxblocks=102401*zd
      Setting up table: planet_osm_nodes

          • WARNING: intarray contrib module not installed
          • The resulting database will not be usable for applying diffs.

      NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index "planet_osm_nodes
      _pkey" for table "planet_osm_nodes"
      Setting up table: planet_osm_ways
      NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index "planet_osm_ways_
      pkey" for table "planet_osm_ways"
      Setting up table: planet_osm_rels
      NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index "planet_osm_rels_
      pkey" for table "planet_osm_rels"

      Reading in file: jo.osm
      StartElement: Unknown element name: bounds
      EndElement: Unknown element name: bounds
      WARNING: Found Out of order node 295281240 (2385512,600) - this will impact the
      cache efficiency
      Processing: Node(12k) Way(1k) Relation(0k)
      Node stats: total(12648), max(401325204)
      Way stats: total(1858), max(34338222)
      Relation stats: total(7), max(93919)

      Going over pending ways
      processing way (0k)

      Going over pending relations

      node cache: stored: 3051(24.12%), storage efficiency: 0.58%, hit rate: 21.69%

      Funzt irgendwie nicht...


    • Re: osm2pgsql kein Datenexport · MontyM (Gast) · 17.05.2009 22:12 · [flux]

      Hast du die 900913.sql eingespielt? (EPSG von 900913)


    • Re: osm2pgsql kein Datenexport · Mehmet_C (Gast) · 17.05.2009 23:25 · [flux]

      Jep, habe es mit

      psql -d routing -f 900913.sql

      eingelesen. Die Ausgabe war dann INSERT 0 1.

      Hmm, an den eingelesenen Daten (osnabrueck.osm) liegt es nicht... Beim ersten Versuch kam die OSM-Datei von JOSM, und beim anderen mal durch das Exportieren von openstreetmap.org, beide verursachen denselben Fehler - nichts wird in die PostGis-Tabelle geschrieben.


    • Re: osm2pgsql kein Datenexport · lutz (Gast) · 18.05.2009 08:22 · [flux]

      hallo,

      das problem gab es schonmal,

      http://www.mail-archive.com/talk@openst … 10327.html
      http://www.nabble.com/Carriage-Return-c … 37161.html

      kann dir aber auch nicht helfen, bei meiner suse läuft alles wunderbar.

      vieleicht neu installieren? andere version?.....

      mfg lutz


    • Re: osm2pgsql kein Datenexport · MontyM (Gast) · 18.05.2009 18:17 · [flux]

      Funktioniert es mit einer normalen osm Datei von hier http://download.geofabrik.de/osm/europe/germany

      Ansonsten hab ich keine Idee mehr.


    • Re: osm2pgsql kein Datenexport · Mehmet_C (Gast) · 18.05.2009 20:53 · [flux]

      Moin,

      ich habe mal testweise bremen.osm.bz2 genommen.. Ergebnis ist am Ende


      Writing way(6k)


      Aber dennoch wird nichts in die Tabelle geschrieben. Sehr merkwürdig.

      Wie bist du denn genau vorgegangen ? Beschreib mal bitte alle Dinge, die du gemacht hast..

      So bei mir:
      1.) PostgreSQL 8.3, dann PostGIS 1.3.5 installiert
      2.) osm2pgsql runtergeladen und in einem Ordner entpackt
      3.) Projektion 900913 in die mit pgAdmin III erstellte (mit template_postgis) Datenbank eingelesen
      4.) osm2pgsql Befehl ausgeführt

      --> failure


    • Re: osm2pgsql kein Datenexport · lutz (Gast) · 18.05.2009 21:28 · [flux]

      hallo,

      unter linux ist der ablauf so:

      su - postgres

      createuser username

      createdb -E UTF8 -O username gis

      createlang plpgsql gis

      Connects to database and creates the following 4 tables:

      - planet_osm_point
      - planet_osm_line
      - planet_osm_roads
      - planet_osm_polygon

      psql -d gis -f /usr/share/postgis/lwpostgis.sql

      echo "ALTER TABLE geometry_columns OWNER TO username; ALTER TABLE
      spatial_ref_sys OWNER TO username;" | psql -d gis

      psql -d gis -f /osm2pgsql/900913.sql

      osm2pgsql -m -d gis germany.osm.bz2

      mfg lutz