<p>I discovered that I was getting an Out of Memory with osm2pgsql. Had to look in the kernel log to see this. So I think it's just a case of an unexpected error message.</p>
<p>I am doing a planet import on an EC2 instance with 16G of RAM. The machine is not doing any other work. I'm using --cache 8000 and these PG settings (mostly taken from pgtune):</p>
<p>default_statistics_target = '50'<br>
maintenance_work_mem = '200MB'<br>
checkpoint_completion_target = '0.9'<br>
effective_cache_size = '1808MB'<br>
work_mem = '16MB'<br>
wal_buffers = '16MB'<br>
shared_buffers = '448MB'<br>
max_connections = '100'<br>
max_wal_size = '2GB'</p>
<p>Any advice on how to tune memory settings between Postgres and osm2pgsql to get the best use of limited RAM, without running into OOM?</p>
<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">—<br />You are receiving this because you are subscribed to this thread.<br />Reply to this email directly, <a href="https://github.com/openstreetmap/osm2pgsql/issues/855#issuecomment-403242124">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe-auth/AD2-7lL_xLIMASXgYEGOX68CJW5WcAK6ks5uER8GgaJpZM4VAAIJ">mute the thread</a>.<img src="https://github.com/notifications/beacon/AD2-7txDww7ICM27Xq6u9X6mVSfFDlJTks5uER8GgaJpZM4VAAIJ.gif" height="1" width="1" alt="" /></p>
<script type="application/json" data-scope="inboxmarkup">{"api_version":"1.0","publisher":{"api_key":"05dde50f1d1a384dd78767c55493e4bb","name":"GitHub"},"entity":{"external_key":"github/openstreetmap/osm2pgsql","title":"openstreetmap/osm2pgsql","subtitle":"GitHub repository","main_image_url":"https://assets-cdn.github.com/images/email/message_cards/header.png","avatar_image_url":"https://assets-cdn.github.com/images/email/message_cards/avatar.png","action":{"name":"Open in GitHub","url":"https://github.com/openstreetmap/osm2pgsql"}},"updates":{"snippets":[{"icon":"PERSON","message":"@jnewmoyer in #855: I discovered that I was getting an Out of Memory with osm2pgsql. Had to look in the kernel log to see this. So I think it's just a case of an unexpected error message. \r\n\r\nI am doing a planet import on an EC2 instance with 16G of RAM. The machine is not doing any other work. I'm using --cache 8000 and these PG settings (mostly taken from pgtune):\r\n\r\ndefault_statistics_target = '50'\r\nmaintenance_work_mem = '200MB'\r\ncheckpoint_completion_target = '0.9'\r\neffective_cache_size = '1808MB'\r\nwork_mem = '16MB'\r\nwal_buffers = '16MB'\r\nshared_buffers = '448MB'\r\nmax_connections = '100'\r\nmax_wal_size = '2GB'\r\n\r\nAny advice on how to tune memory settings between Postgres and osm2pgsql to get the best use of limited RAM, without running into OOM? \r\n\r\n"}],"action":{"name":"View Issue","url":"https://github.com/openstreetmap/osm2pgsql/issues/855#issuecomment-403242124"}}}</script>
<script type="application/ld+json">[
{
"@context": "http://schema.org",
"@type": "EmailMessage",
"potentialAction": {
"@type": "ViewAction",
"target": "https://github.com/openstreetmap/osm2pgsql/issues/855#issuecomment-403242124",
"url": "https://github.com/openstreetmap/osm2pgsql/issues/855#issuecomment-403242124",
"name": "View Issue"
},
"description": "View this Issue on GitHub",
"publisher": {
"@type": "Organization",
"name": "GitHub",
"url": "https://github.com"
}
},
{
"@type": "MessageCard",
"@context": "http://schema.org/extensions",
"hideOriginalBody": "false",
"originator": "AF6C5A86-E920-430C-9C59-A73278B5EFEB",
"title": "Re: [openstreetmap/osm2pgsql] Planet load fails with ERROR: relation \"osm_point\" does not exist (#855)",
"sections": [
{
"text": "",
"activityTitle": "**Jason Newmoyer**",
"activityImage": "https://assets-cdn.github.com/images/email/message_cards/avatar.png",
"activitySubtitle": "@jnewmoyer",
"facts": [
]
}
],
"potentialAction": [
{
"name": "Add a comment",
"@type": "ActionCard",
"inputs": [
{
"isMultiLine": true,
"@type": "TextInput",
"id": "IssueComment",
"isRequired": false
}
],
"actions": [
{
"name": "Comment",
"@type": "HttpPOST",
"target": "https://api.github.com",
"body": "{\n\"commandName\": \"IssueComment\",\n\"repositoryFullName\": \"openstreetmap/osm2pgsql\",\n\"issueId\": 855,\n\"IssueComment\": \"{{IssueComment.value}}\"\n}"
}
]
},
{
"name": "Close issue",
"@type": "HttpPOST",
"target": "https://api.github.com",
"body": "{\n\"commandName\": \"IssueClose\",\n\"repositoryFullName\": \"openstreetmap/osm2pgsql\",\n\"issueId\": 855\n}"
},
{
"targets": [
{
"os": "default",
"uri": "https://github.com/openstreetmap/osm2pgsql/issues/855#issuecomment-403242124"
}
],
"@type": "OpenUri",
"name": "View on GitHub"
},
{
"name": "Unsubscribe",
"@type": "HttpPOST",
"target": "https://api.github.com",
"body": "{\n\"commandName\": \"MuteNotification\",\n\"threadId\": 352322057\n}"
}
],
"themeColor": "26292E"
}
]</script>