wiktorn / Overpass-API

Overpass API docker image
MIT License
133 stars 47 forks source link

"the page you are looking for is currently unavailable" #81

Closed RyanDeRose-TomTom closed 9 months ago

RyanDeRose-TomTom commented 2 years ago

I have the container running and continuously processing changes, but when I do this query:

curl "http://localhost:12346/api/interpreter?data=node(3470507586)%3Bout%20geom%3B"

I get:

<!DOCTYPE html>
<html>
<head>
<title>Error</title>
<style>
    body {
        width: 35em;
        margin: 0 auto;
        font-family: Tahoma, Verdana, Arial, sans-serif;
    }
</style>
</head>
<body>
<h1>An error occurred.</h1>
<p>Sorry, the page you are looking for is currently unavailable.<br/>
Please try again later.</p>
<p>If you are the system administrator of this resource then you should check
the error log for details.</p>
<p><em>Faithfully yours, nginx.</em></p>
</body>
</html>

It mentions some error log, but I can't find one anywhere. There is a changes.log which just lists the changes it has processed so far.

wiktorn commented 2 years ago

Please provide docker logs for this container (like last 20 lines or whatever you think is relevant).

EDIT: also please provide some details about environment that you're running this container on.

RyanDeRose-TomTom commented 2 years ago

Sorry for delayed reply; I had to run off to the dentist right after posting.

Environment is Ubuntu 18.04 with all prerequisites installed (from here: https://wiki.openstreetmap.org/wiki/Overpass_API/Installation#Ubuntu_or_Debian_6.0_.28squeeze.29_or_Debian_7.0_.28wheezy.29)

The logs repeat this pattern:

2021-12-14 21:11:47 INFO: Using replication server at https://planet.openstreetmap.org/replication/minute/
2021-12-14 21:11:47 DEBUG: Using given sequence ID 4844410
2021-12-14 21:11:47 DEBUG: Starting download at ID 4844411 (max 100 MB)
2021-12-14 21:11:48 DEBUG: Downloaded change 4844411. (102299 kB available in download buffer)
/app/bin/update_from_dir --osc-dir=/db/diffs --version=2021-12-14T21:10:54Z --flush-size=16
Reading XML file ... finished reading nodes. Flushing to database ...... done.
Reading XML file ... finished reading ways. Flushing to database ....2021/12/14 21:11:53 [crit] 34#34: *1121 connect() to unix:/nginx/fcgiwrap.socket failed (2: No such file or directory) while connecting to upstream, client: 127.0.0.1, server: localhost, request: "GET /api/interpreter?data=[out:json];node(1);out; HTTP/1.1", upstream: "fastcgi://unix:/nginx/fcgiwrap.socket:", host: "localhost"
127.0.0.1 - - [14/Dec/2021:21:11:53 +0000] "GET /api/interpreter?data=[out:json];node(1);out; HTTP/1.1" 502 494 "-" "curl/7.64.0"
.. done.
Reading XML file ... finished reading relations. 2021/12/14 21:12:23 [crit] 34#34: *1123 connect() to unix:/nginx/fcgiwrap.socket failed (2: No such file or directory) while connecting to upstream, client: 127.0.0.1, server: localhost, request: "GET /api/interpreter?data=[out:json];node(1);out; HTTP/1.1", upstream: "fastcgi://unix:/nginx/fcgiwrap.socket:", host: "localhost"
127.0.0.1 - - [14/Dec/2021:21:12:23 +0000] "GET /api/interpreter?data=[out:json];node(1);out; HTTP/1.1" 502 494 "-" "curl/7.64.0"
Flushing to database ....... done.
Update complete.
There are still some updates remaining
2021-12-14 21:12:27 INFO: Using replication server at https://planet.openstreetmap.org/replication/minute/
2021-12-14 21:12:27 DEBUG: Using given sequence ID 4844411
2021-12-14 21:12:27 DEBUG: Starting download at ID 4844412 (max 100 MB)
2021-12-14 21:12:27 DEBUG: Downloaded change 4844412. (102170 kB available in download buffer)
/app/bin/update_from_dir --osc-dir=/db/diffs --version=2021-12-14T21:11:56Z --flush-size=16
Reading XML file ... finished reading nodes. Flushing to database ...... done.
Reading XML file ... finished reading ways. Flushing to database .....2021/12/14 21:12:53 [crit] 34#34: *1125 connect() to unix:/nginx/fcgiwrap.socket failed (2: No such file or directory) while connecting to upstream, client: 127.0.0.1, server: localhost, request: "GET /api/interpreter?data=[out:json];node(1);out; HTTP/1.1", upstream: "fastcgi://unix:/nginx/fcgiwrap.socket:", host: "localhost"
127.0.0.1 - - [14/Dec/2021:21:12:53 +0000] "GET /api/interpreter?data=[out:json];node(1);out; HTTP/1.1" 502 494 "-" "curl/7.64.0"

So there is actually some problem finding this fcgiwrap.socket file, but I have no idea what it is.

wiktorn commented 2 years ago

What I can see here is healthchecks calls that are failing. Looks like the updates are working though.

Can you restart the container and show the logs that show from restart until the first healtheck ("GET /api/interpreter?data=[out:json];node(1);out; HTTP/1.1)?

Also, what filesystem backs /db volume?

RyanDeRose-TomTom commented 2 years ago

Restarted the container. From that query, I get:

 GET "/api/interpreter?data=[out:json];node(1);out;" HTTP/1.1
<html><body><h1>403 Forbidden</h1>
Request forbidden by administrative rules.
</body></html>

The volume is back by a mounted drive with xfs filesystem

wiktorn commented 2 years ago

From the logs I suspect that dispatcher did not start. Without logs showing why it did not start I cannot help you.