[postgis-users] Error in shp2pgsql

João Paulo Hespanha jphespanha at gmx.com
Tue Jun 22 12:59:43 PDT 2010


Dear Sirs:

While importing a shapefile produced from an ESRI personal geodatabase,
consisting of a total of 609 polygons, I got the error which I report in
the below transcript (a bit long... as usual).

Later, I found out that the program was crashing due to a incorrect
polygon, having shape length and area equal to zero. Now I know that
ArcGIS accepts such misformed polygons in the geodatabase...

I have also used SPIT (a QGIS plugin), which did not give me problems
respecting the import and simply ignored the erroneous polygon, although
it did not informed me of the fact.

FYI, I am using release 1.5 of shp2pgsql and:
"POSTGIS="1.3.5" GEOS="3.2.2-CAPI-1.6.2" PROJ="Rel. 4.7.1, 23 September
2009" USE_STATS"; "PostgreSQL 8.3.8 on i486-pc-linux-gnu, compiled by
GCC gcc-4.4.real (Ubuntu 4.4.1-3ubuntu3) 4.4.1"


Transcript from my session:
jphespanha at JPHUbuntu:~/Documentos/Tese/ImplementationTest_2010/ArcGISshapes$ shp2pgsql -c -s 9102160 Predio_Polygons public.predio_polygons > predio_polys.sql 
Shapefile type: Polygon
Postgis type: MULTIPOLYGON[2]
*** glibc detected *** shp2pgsql: corrupted double-linked list:
0x084a9c78 ***
======= Backtrace: =========
/lib/tls/i686/cmov/libc.so.6[0xe3f0d1]
/lib/tls/i686/cmov/libc.so.6[0xe40b69]
/lib/tls/i686/cmov/libc.so.6(cfree+0x6d)[0xe438ad]
shp2pgsql[0x8053345]
shp2pgsql[0x8053d76]
/lib/tls/i686/cmov/libc.so.6(__libc_start_main+0xe6)[0xdeab56]
shp2pgsql[0x8049ed1]
======= Memory map: ========
0068d000-0068e000 r-xp 00000000 00:00 0          [vdso]
00931000-00955000 r-xp 00000000 08:01
1967425    /lib/tls/i686/cmov/libm-2.10.1.so
00955000-00956000 r--p 00023000 08:01
1967425    /lib/tls/i686/cmov/libm-2.10.1.so
00956000-00957000 rw-p 00024000 08:01
1967425    /lib/tls/i686/cmov/libm-2.10.1.so
009e3000-009e5000 r-xp 00000000 08:01
534769     /usr/lib/gconv/CP1252.so
009e5000-009e6000 r--p 00001000 08:01
534769     /usr/lib/gconv/CP1252.so
009e6000-009e7000 rw-p 00002000 08:01
534769     /usr/lib/gconv/CP1252.so
00d6b000-00d87000 r-xp 00000000 08:01 2352       /lib/libgcc_s.so.1
00d87000-00d88000 r--p 0001b000 08:01 2352       /lib/libgcc_s.so.1
00d88000-00d89000 rw-p 0001c000 08:01 2352       /lib/libgcc_s.so.1
00dd4000-00f12000 r-xp 00000000 08:01
1967417    /lib/tls/i686/cmov/libc-2.10.1.so
00f12000-00f13000 ---p 0013e000 08:01
1967417    /lib/tls/i686/cmov/libc-2.10.1.so
00f13000-00f15000 r--p 0013e000 08:01
1967417    /lib/tls/i686/cmov/libc-2.10.1.so
00f15000-00f16000 rw-p 00140000 08:01
1967417    /lib/tls/i686/cmov/libc-2.10.1.so
00f16000-00f19000 rw-p 00000000 00:00 0 
00f53000-00f6e000 r-xp 00000000 08:01 146        /lib/ld-2.10.1.so
00f6e000-00f6f000 r--p 0001a000 08:01 146        /lib/ld-2.10.1.so
00f6f000-00f70000 rw-p 0001b000 08:01 146        /lib/ld-2.10.1.so
08048000-0807b000 r-xp 00000000 08:01 4134       /usr/bin/shp2pgsql
0807b000-0807c000 r--p 00032000 08:01 4134       /usr/bin/shp2pgsql
0807c000-0807d000 rw-p 00033000 08:01 4134       /usr/bin/shp2pgsql
084a6000-084c7000 rw-p 00000000 00:00 0          [heap]
b7600000-b7621000 rw-p 00000000 00:00 0 
b7621000-b7700000 ---p 00000000 00:00 0 
b77f4000-b77f6000 rw-p 00000000 00:00 0 
b7800000-b7801000 rw-p 00000000 00:00 0 
b7801000-b7808000 r--s 00000000 08:01
534863     /usr/lib/gconv/gconv-modules.cache
b7808000-b780d000 rw-p 00000000 00:00 0 
bf7f9000-bf80e000 rw-p 00000000 00:00 0          [stack]
Abortado

I really have to do an update on this old versions of postgresql
+postgis!!! :-)
Perhaps the question is already solved, but if not, this could be
helpful.





More information about the postgis-users mailing list