Hi there,

I've got a problem with importing .osm files into a postgis database.

I think i set up the database correcly is, I used the pgsql_simple_schema_0.6.sql schema from osmosis.
I also used the 900913.sql file.


When i try to import files like this:

osmosis --read-xml file="madagascar.osm" --write-apidb host="localhost" database="osm5" user="postgres" password="12345"


I'll get the following output/Error messages:

#################################################

May 2, 2010 2:06:42 PM org.openstreetmap.osmosis.core.Osmosis run
INFO: Osmosis Version 0.35
May 2, 2010 2:06:42 PM org.java.plugin.ObjectFactory loadProperties
FINE: no jpf.properties file found in ${java.home}/lib (/usr/lib/jvm/java-6-openjdk/jre/lib/jpf.properties) nor in CLASSPATH, using standard properties
May 2, 2010 2:06:42 PM org.java.plugin.ObjectFactory loadProperties
FINE: loaded jpf.properties from jar:file:/home/alex/Desktop/osmosis-0.35/lib/default/jpf-1.5.jar!/org/java/plugin/standard/jpf.properties
May 2, 2010 2:06:42 PM org.java.plugin.ObjectFactory findProperty
FINE: property org.java.plugin.ObjectFactory found in properties file
May 2, 2010 2:06:42 PM org.java.plugin.ObjectFactory newInstance
FINE: object factory instance created - org.java.plugin.standard.standardobjectfact...@10a2d64 May 2, 2010 2:06:42 PM org.java.plugin.standard.StandardObjectFactory getImplClassName FINE: implementation class for org.java.plugin.registry.PluginRegistry is org.java.plugin.registry.xml.PluginRegistryImpl
May 2, 2010 2:06:42 PM org.java.plugin.registry.xml.ManifestParser <init>
INFO: got SAX parser factory - org.apache.xerces.jaxp.saxparserfactoryi...@12b7eea May 2, 2010 2:06:42 PM org.java.plugin.registry.xml.PluginRegistryImpl configure
INFO: configured, stopOnError=false, isValidating=true
May 2, 2010 2:06:42 PM org.java.plugin.standard.StandardObjectFactory createRegistry FINE: registry instance created - org.java.plugin.registry.xml.pluginregistryi...@99353f May 2, 2010 2:06:42 PM org.java.plugin.standard.StandardObjectFactory getImplClassName FINE: implementation class for org.java.plugin.PathResolver is org.java.plugin.standard.StandardPathResolver May 2, 2010 2:06:42 PM org.java.plugin.standard.StandardObjectFactory createPathResolver FINE: path resolver instance created - org.java.plugin.standard.standardpathresol...@1112783 May 2, 2010 2:06:42 PM org.java.plugin.standard.StandardObjectFactory getImplClassName FINE: implementation class for org.java.plugin.standard.PluginLifecycleHandler is org.java.plugin.standard.StandardPluginLifecycleHandler May 2, 2010 2:06:42 PM org.java.plugin.standard.StandardPluginLifecycleHandler configure
FINE: probeParentLoaderLast parameter value is false
May 2, 2010 2:06:42 PM org.java.plugin.standard.StandardObjectFactory createLifecycleHandler FINE: life cycle handler instance created - org.java.plugin.standard.standardpluginlifecyclehand...@1238bd2 May 2, 2010 2:06:42 PM org.openstreetmap.osmosis.core.TaskRegistrar loadJPFPlugins
FINE: Searching for JPF plugins.
May 2, 2010 2:06:42 PM org.openstreetmap.osmosis.core.TaskRegistrar loadJPFPlugins
FINE: Registering the core plugin.
May 2, 2010 2:06:42 PM org.java.plugin.registry.xml.ManifestParser$1 resolveEntity FINE: entity resolved to plug-in manifest DTD, publicId=-//JPF//Java Plug-in Manifest 1.0, systemId=http://jpf.sourceforge.net/plugin_1_0.dtd May 2, 2010 2:06:42 PM org.java.plugin.registry.xml.ManifestHandler startElement
FINE: startElement - []/[]/[plugin]
May 2, 2010 2:06:42 PM org.java.plugin.registry.xml.ManifestHandler startElement
FINE: startElement - []/[]/[extension-point]
May 2, 2010 2:06:42 PM org.java.plugin.registry.xml.ManifestHandler startElement
FINE: startElement - []/[]/[parameter-def]
May 2, 2010 2:06:42 PM org.java.plugin.registry.xml.ManifestHandler endElement
FINE: endElement - []/[]/[parameter-def]
May 2, 2010 2:06:42 PM org.java.plugin.registry.xml.ManifestHandler startElement
FINE: startElement - []/[]/[parameter-def]
May 2, 2010 2:06:42 PM org.java.plugin.registry.xml.ManifestHandler endElement
FINE: endElement - []/[]/[parameter-def]
May 2, 2010 2:06:42 PM org.java.plugin.registry.xml.ManifestHandler endElement
FINE: endElement - []/[]/[extension-point]
May 2, 2010 2:06:42 PM org.java.plugin.registry.xml.ManifestHandler endElement
FINE: endElement - []/[]/[plugin]
May 2, 2010 2:06:42 PM org.java.plugin.registry.xml.PluginRegistryImpl register
FINE: manifest files parsed, plugins.size=1, fragments.size=0
May 2, 2010 2:06:42 PM org.java.plugin.registry.xml.PluginRegistryImpl register
FINE: plug-ins versions checked, plugins.size=1
May 2, 2010 2:06:42 PM org.java.plugin.registry.xml.PluginRegistryImpl register
FINE: plug-in fragments versions checked, fragments.size=0
May 2, 2010 2:06:42 PM org.java.plugin.registry.xml.PluginRegistryImpl registerPlugin FINE: registering plug-in, URL - jar:file:/home/alex/Desktop/osmosis-0.35/osmosis.jar!/org/openstreetmap/osmosis/core/plugin/plugin.xml May 2, 2010 2:06:42 PM org.java.plugin.registry.xml.ExtensionPointImpl$ParameterDefinitionImpl <init> FINE: object instantiated: {PluginExtensionPoint.ParameterDefinition: extpointuid=org.openstreetmap.osmosis.core.plugin.c...@task; id=class} May 2, 2010 2:06:42 PM org.java.plugin.registry.xml.ExtensionPointImpl$ParameterDefinitionImpl <init> FINE: object instantiated: {PluginExtensionPoint.ParameterDefinition: extpointuid=org.openstreetmap.osmosis.core.plugin.c...@task; id=name} May 2, 2010 2:06:42 PM org.java.plugin.registry.xml.ExtensionPointImpl <init> FINE: object instantiated: {ExtensionPoint: uid=org.openstreetmap.osmosis.core.plugin.c...@task} May 2, 2010 2:06:42 PM org.java.plugin.registry.xml.PluginDescriptorImpl <init> FINE: object instantiated: {PluginDescriptor: [email protected]} May 2, 2010 2:06:42 PM org.java.plugin.registry.xml.PluginRegistryImpl register
INFO: plug-in and fragment descriptors registered - 1
May 2, 2010 2:06:42 PM org.java.plugin.registry.xml.PluginRegistryImpl dump
FINE: PLUG-IN REGISTRY DUMP:
-------------- DUMP BEGIN -----------------
    Plug-ins: 1
{PluginDescriptor: [email protected]}
    Fragments: 0
Memory TOTAL/FREE/MAX: 35717120/31713048/500891648
-------------- DUMP END -----------------

May 2, 2010 2:06:42 PM org.java.plugin.registry.xml.PluginRegistryImpl$RegistryChangeDataImpl dump
FINE: PLUG-IN REGISTRY CHANGES DUMP:
-------------- DUMP BEGIN -----------------
    Added plug-ins: 1
        org.openstreetmap.osmosis.core.plugin.Core
    Removed plug-ins: 0
    Modified plug-ins: 0
    Added extensions: 0
    Removed extensions: 0
    Modified extensions: 0
Memory TOTAL/FREE/MAX: 35717120/31713048/500891648
-------------- DUMP END -----------------

May 2, 2010 2:06:42 PM org.java.plugin.registry.xml.PluginRegistryImpl fireEvent
FINE: propagating registry change event
May 2, 2010 2:06:42 PM org.java.plugin.registry.xml.PluginRegistryImpl fireEvent
FINE: registry change event propagated
May 2, 2010 2:06:42 PM org.java.plugin.standard.StandardPluginClassLoader getUrls FINE: Code URL's populated for plug-in {PluginDescriptor: [email protected]}:

May 2, 2010 2:06:42 PM org.java.plugin.standard.StandardPluginManager activatePlugin
INFO: plug-in started - [email protected]
May 2, 2010 2:06:42 PM org.openstreetmap.osmosis.core.TaskRegistrar loadJPFPlugins
FINE: Registering the extension plugins.
May 2, 2010 2:06:42 PM org.openstreetmap.osmosis.core.Osmosis run
INFO: Preparing pipeline.
May 2, 2010 2:06:42 PM org.openstreetmap.osmosis.core.pipeline.common.Pipeline prepare
FINE: Building tasks.
May 2, 2010 2:06:42 PM org.openstreetmap.osmosis.core.pipeline.common.Pipeline buildTasks
FINE: Created task "1-read-xml"
May 2, 2010 2:06:42 PM org.openstreetmap.osmosis.core.pipeline.common.Pipeline buildTasks
FINE: Created task "2-write-apidb"
May 2, 2010 2:06:42 PM org.openstreetmap.osmosis.core.pipeline.common.Pipeline prepare
FINE: Connecting tasks.
May 2, 2010 2:06:42 PM org.openstreetmap.osmosis.core.pipeline.common.PipeTasks putTask FINE: Task "1-read-xml" produced unnamed pipe stored at level 1 in the default pipe stack. May 2, 2010 2:06:42 PM org.openstreetmap.osmosis.core.pipeline.common.Pipeline connectTasks
FINE: Connected task "1-read-xml"
May 2, 2010 2:06:42 PM org.openstreetmap.osmosis.core.pipeline.common.PipeTasks retrieveTask FINE: Task "2-write-apidb" consumed unnamed pipe stored at level 1 in the default pipe stack. May 2, 2010 2:06:42 PM org.openstreetmap.osmosis.core.pipeline.common.Pipeline connectTasks
FINE: Connected task "2-write-apidb"
May 2, 2010 2:06:42 PM org.openstreetmap.osmosis.core.Osmosis run
INFO: Launching pipeline execution.
May 2, 2010 2:06:42 PM org.openstreetmap.osmosis.core.pipeline.common.ActiveTaskManager execute
FINE: Launching task 1-read-xml in a new thread.
May 2, 2010 2:06:42 PM org.openstreetmap.osmosis.core.pipeline.common.PassiveTaskManager execute
FINE: Task 2-write-apidb is passive, no execution required.
May 2, 2010 2:06:42 PM org.openstreetmap.osmosis.core.Osmosis run
INFO: Pipeline executing, waiting for completion.
May 2, 2010 2:06:42 PM org.openstreetmap.osmosis.core.pipeline.common.ActiveTaskManager waitForCompletion
FINE: Waiting for task 1-read-xml to complete.
May 2, 2010 2:06:42 PM org.openstreetmap.osmosis.core.pipeline.common.ActiveTaskManager waitForCompletion
SEVERE: Thread for task 1-read-xml failed
org.openstreetmap.osmosis.core.OsmosisRuntimeException: Unable to create resultset. at org.openstreetmap.osmosis.core.apidb.common.DatabaseContext.executeQuery(DatabaseContext.java:429) at org.openstreetmap.osmosis.core.apidb.v0_6.impl.SchemaVersionValidator.validateDBVersion(SchemaVersionValidator.java:82) at org.openstreetmap.osmosis.core.apidb.v0_6.impl.SchemaVersionValidator.validateVersion(SchemaVersionValidator.java:55) at org.openstreetmap.osmosis.core.apidb.v0_6.ApidbWriter.initialize(ApidbWriter.java:288) at org.openstreetmap.osmosis.core.apidb.v0_6.ApidbWriter.process(ApidbWriter.java:1046) at org.openstreetmap.osmosis.core.xml.v0_6.impl.BoundElementProcessor.end(BoundElementProcessor.java:85) at org.openstreetmap.osmosis.core.xml.v0_6.impl.OsmHandler.endElement(OsmHandler.java:107) at org.apache.xerces.parsers.AbstractSAXParser.endElement(Unknown Source) at org.apache.xerces.parsers.AbstractXMLDocumentParser.emptyElement(Unknown Source) at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanStartElement(Unknown Source) at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(Unknown Source) at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)
    at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
    at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
    at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
    at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source)
at org.apache.xerces.jaxp.SAXParserImpl$JAXPSAXParser.parse(Unknown Source)
    at org.apache.xerces.jaxp.SAXParserImpl.parse(Unknown Source)
    at javax.xml.parsers.SAXParser.parse(SAXParser.java:195)
at org.openstreetmap.osmosis.core.xml.v0_6.XmlReader.run(XmlReader.java:108)
    at java.lang.Thread.run(Thread.java:636)
Caused by: org.postgresql.util.PSQLException: ERROR: relation "schema_migrations" does not exist at org.postgresql.core.v3.QueryExecutorImpl.receiveErrorResponse(QueryExecutorImpl.java:1592) at org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:1327) at org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:192) at org.postgresql.jdbc2.AbstractJdbc2Statement.execute(AbstractJdbc2Statement.java:451) at org.postgresql.jdbc2.AbstractJdbc2Statement.executeWithFlags(AbstractJdbc2Statement.java:336) at org.postgresql.jdbc2.AbstractJdbc2Statement.executeQuery(AbstractJdbc2Statement.java:235) at org.openstreetmap.osmosis.core.apidb.common.DatabaseContext.executeQuery(DatabaseContext.java:424)
    ... 20 more
May 2, 2010 2:06:42 PM org.openstreetmap.osmosis.core.pipeline.common.PassiveTaskManager waitForCompletion
FINE: Task 2-write-apidb is passive, no completion wait required.
May 2, 2010 2:06:42 PM org.openstreetmap.osmosis.core.Osmosis main
SEVERE: Execution aborted.
org.openstreetmap.osmosis.core.OsmosisRuntimeException: One or more tasks failed. at org.openstreetmap.osmosis.core.pipeline.common.Pipeline.waitForCompletion(Pipeline.java:146)
    at org.openstreetmap.osmosis.core.Osmosis.run(Osmosis.java:85)
    at org.openstreetmap.osmosis.core.Osmosis.main(Osmosis.java:30)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:616)
at org.codehaus.plexus.classworlds.launcher.Launcher.launchStandard(Launcher.java:329) at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:239) at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:409) at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:352)
    at org.codehaus.classworlds.Launcher.main(Launcher.java:31)



#####################################################################


sorry for the long message, but im not sure which parts are important...


OS is Ubuntu 10.04, Postgres Version 8.4, Osmosis 0.35


I hope someone has got an idea.

Thanks


_______________________________________________
osmosis-dev mailing list
[email protected]
http://lists.openstreetmap.org/listinfo/osmosis-dev

Reply via email to