How to restart the server automatically on failure?

Sometimes graphhopper’s server dies. How could I make it restart automatically?

GraphHopper does not die without a reason.
What do the logs say? Did you ensure that the OOM killer of the operating system did not kill it? Did you assign the JVM enough RAM (Xmx)?

1 Like

OOM killer? Logs don’t give any details about this. My config: “-Xmx2500m -Xms50m”

What size has your graph folder?

Also make sure you are using the latest GraphHopper version.

out of memory killer. E.g.

grep -i killed /var/log/syslog
... Out of memory: Killed process ... (java) ...
1 Like

grep -i killed /var/log/syslog - empty

Graph folder (.osm-gh) is 106M in size.

Sorry, no idea what the problem could be. Likely some configuration or hardware issue and not due to GraphHopper itself. As we have it in production for years and never something like this happened without a reason…

Anyone has any ideas? It keeps happening…

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.