[Tile-serving] [osm2pgsql] Unnecessary flat-nodes with enough RAM (#22)

Paul Norman penorman at mac.com
Tue Apr 30 21:49:14 UTC 2013

> From: Frederik Ramm [mailto:frederik at remote.org]
> Subject: Re: [Tile-serving] [osm2pgsql] Unnecessary flat-nodes with
> enough RAM (#22)
> Hi,
> On 30.04.2013 19:51, pnorman wrote:
> > It's been said that you could almost use /dev/null for a flat-nodes
> > file if you have a large enough -C value and don't plan to update the
> > database. An option that allows you to use no file at all for flat
> > nodes would be useful for when someone doesn't plan to update diffs
> > and has enough memory. It would save on sequential writes and save on
> > disk space. The latter is useful when using SSDs.
> Why would you use --slim under these circumstances at all?

32GB is enough memory for --slim with enough cache to only write to flat
nodes, but not nearly enough for non-slim mode.

Last time I imported it was on my server which had 32GB ram but I had to put
flat nodes on the same drive as another file which isn't quite optimal. 

My current import is on an EC2 instance (m3.2xlarge) so to have enough space
for the flat nodes file I needed to make my temporary scratch EBS volume
about 16GB larger.

Lastly, it's my understanding that slim with appropriate options approaches
the speed of non-slim. This may vary from system to system.

As an aside, I tried importing on an EC2 cluster instance with 244GB ram, 32
Xeon threads, and provisioned IO. The first parts were no quicker because it
was single-thread CPU bound reading from the PBF.

More information about the Tile-serving mailing list