3

I am using a simple query the one that is in the examples which returns all data in the bounding box. Currently using overpass-api.de/api/. I have been trying for a couple of days thinking that server may be overloaded but i still get this error

enter image description here

enter image description here

  • Maybe your bounding box / viewing area is just too large? What are you trying to do? What is your ultimate goal? – scai May 17 '17 at 6:54
  • What i´m trying to do is to download Europe as a continent with some arab and some asian countries. I wanted to download not fully zoomed , but let´s say about 8 -9 zoom. – Marian Pepa May 17 '17 at 10:41
  • 1
    This is the wrong approach. If you need OSM data for a large area then simply download one of the country or area extracts. – scai May 17 '17 at 10:56
3

Don't use Overpass API for downloading large areas. Instead choose one of the country or area extracts.

| improve this answer | |
  • Yeah i could do it country by country , you are right. I also was wondering how do i download these extracts only zoomed to 9 any suggestion ? – Marian Pepa May 17 '17 at 11:10
  • 1
    OSM data is independent from zoom levels and usually always includes all details. Zoom level specific settings can usually be found in the stylesheets of renderers but not in the data itself. – scai May 17 '17 at 11:19
  • 2
    @scai: fyi: we have people downloading 1,5GB+ of OSM data, so technically speaking your statement is not exactly matching reality. OTOH, if there's a suitable extract available, that would of course be the better option as it reduces server load. – mmd May 17 '17 at 11:26
  • @mmd I just intended to avoid unnecessary traffic on your servers but if you are fine with that then good to know :) – scai May 17 '17 at 11:45
4

By default Overpass API has a certain memory limit in place, to control the overall memory consumption of queries. However, you can easily override that default by providing the maxsize parameter, like shown in the following example. The increased maxsize limit would allow queries up to 2GB. The maximum possible value is a configuration setting on the server.

/*
This is a simple map call.
It returns all data in the bounding box.
*/
[out:xml][maxsize:2000000000];
(
  node({{bbox}});
  <;
);
out meta;

Also, downloading huge amounts of data in overpass turbo and displaying the results in the browser window is highly discouraged, as it will likely crash your browser. Be sure to use Export -> raw data directly from Overpass API instead to save the results in a file.

| improve this answer | |
  • I am new in this and i am trying to learn step by step. What i do not understand in this , is the part that when i try to export raw data from Overpass API it only downloads an "interpreter" unknown file type which i do not know what to do with. – Marian Pepa May 17 '17 at 10:44
  • 2
    It's OSM XML format, just rename interpreter to something like myfile.osm. – mmd May 17 '17 at 10:46
  • @mmd, is it possible to export more than 2GB query? When changing maxsize I get an error, but 2GB throws a "runtime error: Query run out of memory using about 4838 MB of RAM" – Jane Jun 3 '19 at 10:17
  • Increasing the limit above 2GB may be limited by the server configuration and not possible. If you get the error, you need to go for a smaller area. Besides, the error message is a clear indication that you should look into using some OSM extract instead, especially if you're planning to download everything in a very large area: download.geofabrik.de - – mmd Jun 3 '19 at 11:26
  • I've specified the region (Russia), but I need only for villages "node[place=village]" and I don't know how to filter the query. The head of my query is [out:json][maxsize:2000000000]; area["ISO3166-1"="RU"][admin_level=2]; Do you have any idea what way I am to filter villages only? – Jane Jun 3 '19 at 12:45

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.