When it comes to running in the "cloud", I'd probably go for Hetzner. Way way way cheaper than the examples mentioned in this post. I guess the main question is, how much is privacy really worth to you - or what other alternatives are there that meet my demands ie. Mapbox?
Think I'll give this a go, always have wanted to run my own instance of OSM, to see how performant it is/how much traffic you can handle on a single server.
Nice little article about hosting OSM on a desktop.
Including github repo.
I work in e-commerce, and some of my clients have physical stores. Over the years, I've looked into doing this, more or less, but never got too far, as it wasn't clear on what had to be done or run. Everyone seems to be OK with using a Google Maps product in the end (live or static map).
I'll favorite this submission so I'll have something to reference if anyone balks at Google Maps ripping them off, and has a spare server around.
> Even on this smaller extract, these services already use a large portion of my 1TB SSD (667 GB total). Assuming the usage scales proportionally, I would need around 3.7TB of storage for the entire planet. Not to mention the RAM requirements also scaling.
Why? 20TB consumer storage is a thing.
https://www.amazon.com/Western-Digital-20TB-Internal-Drive/d... ($420, heh)
What in the implementation makes the RAM usage explode?
Personally I'd really like to see an OsmAnd based tile server. OsmAnd has a lovely file format that's compact and kept up to date.
>The nuance is in the value that Google Maps brings: expertise, scalability, and proprietary map data.
note that this proprietary map data may be completely beating OSM or being vastly inferior, depending on your use case
Google maps with its massive places data set is just too good. It’s expensive but I find it is always consistently up to date and mostly reliable. Have found some bugs with the places api which I reported, such as it not working for some queries which are off by 0.001 lat/lng
This is awesome, this is why HN rocks! Thanks for sharing!
I do, and my web interface works with noscript/basic (x)html browsers.
How come these map projects still use raster tiles? Are there no open source map projects that render the OSM data to vector data, and renders that vector data on the clients GPU? Maybe raster tiles are better at something I'm missing, but vector maps are easier to style, localize, they're sharper, easier to rotate and zoom smoothly. Maybe it's harder than I think to render it on all sorts of clients including mobile?
When writing this I found out that MapTiler is maintaining MapLibre GL JS, a fork of a Mapbox project to do just that. It would be interesting to see the difference between self hosting raster and vector maps and compare pros and cons. You can even render raster tiles from vector tiles on the server if the client needs it.
I notice an absence of transit directions despite an otherwise robust set of options. I would love to see OpenTripPlanner included in this!
Unfortunately, I am not aware of any open source project that covers the one feature that I still use Google Maps for. Reviews. Does anyone know of any?
I am wondering now if that's something that could be federated well.
>Finally, to get external traffic from the internet connected to my computer (and specifically to Nginx), I had to set up port-forwarding on my router.
FYI: Most providers will not allow this and will disconnect your services for it.
Might be worth noting that Nextcloud offers an OSM maps plugin that handles a lot of this stuff with a single click. I haven't used the service too much, but I was surprised how easy it was to set up.
Vector map of the whole Earth in PMTiles format is only ~65GB and doesn't need any server or database - it's just a static file which you can host wherever you want.
bdon (author of PMTiles) already commented on this thread. I recommend taking a look at https://protomaps.com/docs - compared to this, raster tile servers sound like ancient technology.
> Based on the cheapest instance that matches my own PC's specs
I wonder how much comoute and ram you need for the routing part.
When I worked on a maps stack (no routing and cloud) we would only provision a big compute instance for importing data and seeding (pre-caching) the new tiles. The server itself could be less powerful, though you might have to pay extra for more hard drive space.
I found that Organic Maps (https://organicmaps.app
) is a good open-source OSM-based alternative to Google Maps. Please check it out.
I did a similar thing but with graphhopper for routing since it supports gtfs for public transit. I was just barely able to host tiles for and travelroute Sweden on a 16GB M1 MBP. It wasn’t fun though, graphhopper felt yanky and the travel time isochrones looked very jagged and not quite right. OSM style tiles were fine to host though with enough disk. Routing is the tricky part, especially public transit.
This is cool and all, but I don't quite understand the point. You're not serving maps as part of a business case, what is your use case? I use OSM exclusively, for car navigation, topographical information, waterways and some custom overlay data and I run Osmand on my phone and store all the data for the entire US locally. If you're just planning trips and navigating around in your car, why run a server for it, especially one that powerful?
If you just want map tiles you don't really need much of anything. I run a map service on cheapest hetzner box, cost €4.50/month. Sure its not massive scale, but it would cost about $1000/month on mapbox (about 2m tiles). Just nginx + tileserver-gl + certbot.
Great writing, thanks for sharing! Special kudos to author for improving interface and contribute it to upstream.
Concerning hardware: I would not compare real hardware with cloud virtual servers. For a task like that I would rent a bare metal server. For example, Hetzner offers 6 cores AMD Ryzen 5 server with 128G RAM and 2T NVMe for only 90 EUR/month , but in Germany. I believe it is possible to find similar offer in US for comparable price.
hey........ i have a wildly awesome idea about improving OSM. can anyone build this and help the community? i would help by giving my time....
here is the idea.
a ride sharing app uses OSM for routing and such. fine. The driver follows the map but some times there are new turns or changes to road that are not in the map, or there are some improvements.
my idea. the ride sharing app has the historical "ACTUAL" rides that have already taken place.
we build a tool that takes point A&B from the route given and plots its own normal route. the actual trip and "Expected" trip are overlaid and if there are deviations, the software (after some adjustments for errors) this can give us a high level idea of the general map to actual route. this can also tell mappers which routes to fix and stuff...
there is one tool that does manually but i would be like for large number of routes that would be matched 1:1.