I set up a local postgis database with osmosis using pgsnapshot schema as described here.

The problem occurs when I try to update the database with latest minutely change sets as described here.

When I run the command osmosis --rri --wxc something.gz (which is supposed to put all the changes between the previous sequence number and the most up-to-date into the file something.gz ) I get the following error:

SEVERE: Thread for task 1-rri failed
org.openstreetmap.osmosis.core.OsmosisRuntimeException: Unable to read the state from the server.
        at org.openstreetmap.osmosis.replication.common.ServerStateReader.getServerState(ServerStateReader.java:116)
        at org.openstreetmap.osmosis.replication.common.ServerStateReader.getServerState(ServerStateReader.java:50)
        at org.openstreetmap.osmosis.replication.v0_6.BaseReplicationDownloader.runImpl(BaseReplicationDownloader.java:290)
        at org.openstreetmap.osmosis.replication.v0_6.BaseReplicationDownloader.run(BaseReplicationDownloader.java:383)
        at java.lang.Thread.run(Thread.java:745)
Caused by: java.io.FileNotFoundException: http://planet.openstreetmap.org/minute-replicate/state.txt
        at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1625)
        at org.openstreetmap.osmosis.replication.common.ServerStateReader.getServerState(ServerStateReader.java:97)
        ... 4 more
  • Seems like the correct URL of the minutely state file is planet.osm.org/replication/minute/state.txt. – scai Apr 28 '15 at 10:51
  • Yes, that was the url where I got the initial state. The url in configuration.txt which osmosis setup itself was the one found in exception. I changed it to planet.osm.org/replication/minute/ and it appears to have worked. Thanks! – Stepi Apr 28 '15 at 16:06

Command osmosis --rrii creates a file configuration.txt with a wrong url apparently. Changing it to planet.osm.org/replication/minute/ for minutely updates fixes the problem.

  • 1
    If this is a bug then consider creating a bug report for osmosis. – scai Apr 28 '15 at 18:38

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.