This is a static archive of our old OpenStreetMap Help Site. Please post any new questions and answers at community.osm.org.

Recommended way to set up a Cron job or Systemd service to keep Nominatim updated?

1

Subject says it all. The update method mentioned in the docs, ./utils/update.php --import-osmosis-all seems to be designed to be a forked process as it will keep running after an update until the sleep timeout then do it again. How can I convert this into a Systemd service?

Similarly, if I'm using Cron, do I just have it run ./utils/update.php --import-osmosis no more often than the update interval specified in settings/local.php? Is there a way to disable its built-in sleep so it just checks immediately? (This is how cron jobs seem to be intended to work, as cron handles the sleeping/scheduling.)

--check-for-updates returns immediately, but does it only do a check or will it download updates if there are any?

asked 01 Aug '20, 02:02

RenegadeTech's gravatar image

RenegadeTech
46225
accept rate: 0%

edited 02 Aug '20, 01:36

I'm guessing you're talking about nominatim here?

(01 Aug '20, 02:07) SomeoneElse ♦

Oops, yes, sorry. Fixed.

(01 Aug '20, 02:45) RenegadeTech

Source code available on GitHub .