[OSM-dev] osm2pgsql failing with low cache size

Michael Corey mcorey at cironline.org
Wed Jun 20 17:59:21 BST 2012


The same file works fine when I run osm2pgsql on it with my local 
machine, so I don't think it's an inherent problem with the XML.

Michael Corey
News Applications Developer
Center for Investigative Reporting
510.809.3178

/2012 Recipient of the MacArthur Award for Creative and Effective 
Institutions/
On 6/20/12 7:30 AM, Paul Norman wrote:
>> From: Roland Olbricht [mailto:roland.olbricht at gmx.de]
>> Subject: Re: [OSM-dev] osm2pgsql failing with low cache size
>>
>> Hi,
>>
>>>> Reading in file: ./data/latest.xml
>>>> StartElement: Unknown element name: note Unknown node type 3
>>>> EndElement: Unknown element name: note
>>>> StartElement: Unknown element name: meta
>>>> EndElement: Unknown element name: meta Segmentation fault (core
>>>> dumped)
>>> Can you sanitize your XML by running it through Osmosis (--read-xml
>>> latest.xml --write-xml foo.xml) and then try osm2psql again on the
>>> resulting file? Just to be safe that there's nothing strange in there
>>> that breaks it.
>> The <note> element contains a license remark, the <meta> element a
>> timestamp. Both are in the beginning of the file. You could simply
>> remove them with a text editor.
>>
>> It is a little bit surprising to me because the osm2pgsql version I
>> tried had happily ignored the extra elements.
>>
>> The rationale behind these two elements (and a third element <error>
>> appearing only in case of an error) is to provide useful information in
>> additional tags. This allows any tool to safely just ignore tags which
>> it doesn't know. The license remark is a matter of good style - nobody
>> should say he didn't know about the license of the excerpt. And the
>> timestamp can enable editors like JOSM with the mirrored_download plugin
>> to decide whether a given set of data is outdated or not.
> The issue I have with the timestamp given by overpass is it ignores the XAPI
> output format, even in XAPI compatibility mode. Since at least 2010 the XAPI
> output has included xapi:planetDate and xapi:copyright attributes to the
> <osm> element, not as stand-alone tags.
>
>
> _______________________________________________
> dev mailing list
> dev at openstreetmap.org
> http://lists.openstreetmap.org/listinfo/dev


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/dev/attachments/20120620/96a00633/attachment.html>


More information about the dev mailing list