[postgis-users] Postgres segfaults on some geometry functions

Havard Tveite havard.tveite at nlh.no
Wed May 12 02:55:21 PDT 2004


Things seem to work OK when using a static geos-1.0.0 library.

I configured geos-1.0.0 with the following options:
./configure --enable-shared=no --enable-static=yes --with-pic

I removed the geos-1.0.0 shared libraries and recompiled
postgis-0.8.1 (using -fPIC in the CXXFLAGS).

Paul Ramsey wrote:

> All three of those worked for me just fine on Linux, similar version 
> profile. It is possible we are having some platform problems, GEOS is 
> undertested on Solaris.
> 
> 
> select geomunion( 'POLYGON((0.5 0.5,0.5 1.5,1.5 1.5,1.5 0.5,0.5 0.5))', 
> 'POLYGON
> ((0 0,0 1,1 1,1 0,0 0))');
> dra_conflation=# select geomunion( 'POLYGON((0.5 0.5,0.5 1.5,1.5 1.5,1.5 
> 0.5,0.5
>  0.5))', 'POLYGON((0 0,0 1,1 1,1 0,0 0))');
>                                 geomunion
> --------------------------------------------------------------------------
>  SRID=-1;POLYGON((0.5 1,0.5 1.5,1.5 1.5,1.5 0.5,1 0.5,1 0,0 0,0 1,0.5 1))
> (1 row)
> 
> dra_conflation=# select intersection('POLYGON((0.5 0.5,0.5 1.5,1.5 
> 1.5,1.5 0.5,0
> .5 0.5))', 'POLYGON((0 0,0 1,1 1,1 0,0 0))');
>                     intersection
> ----------------------------------------------------
>  SRID=-1;POLYGON((0.5 0.5,0.5 1,1 1,1 0.5,0.5 0.5))
> (1 row)
> 
> 
> Havard Tveite wrote:
> 
>> I am on Solaris 2.7, GCC 3.3.2, Postgres 7.4.1, GEOS 1.0.0, Postgis
>> 0.8.1 (I had to compile postgis with -fPIC in the CXXFLAGS to be able to
>> build shared libraries).
>>
>> I seem to be having problems with geometry functions that return
>> geometry. All geometric predicates seem to run fine, and so does
>> other "geometry"-functions such as isempty and geometrytype.
>>
>> I have tested:
>> select buffer('POLYGON((0.5 0.5,0.5 1.5,1.5 1.5,1.5 0.5,0.5 0.5))',5);
>> select geomunion( 'POLYGON((0.5 0.5,0.5 1.5,1.5 1.5,1.5 0.5,0.5 
>> 0.5))', 'POLYGON((0 0,0 1,1 1,1 0,0 0))');
>> select intersection('POLYGON((0.5 0.5,0.5 1.5,1.5 1.5,1.5 0.5,0.5 
>> 0.5))', 'POLYGON((0 0,0 1,1 1,1 0,0 0))');
>> and all fail with the following response:
>> "
>> server closed the connection unexpectedly
>>         This probably means the server terminated abnormally
>>         before or while processing the request.
>> The connection to the server was lost. Attempting reset: Failed.
>> "
>> Postgresql recovers from the failure.
>>
>> The postgresql log does not show much, even with debug5 set. This is
>> the result with "notice":
>> 2004-05-11 17:35:25 LOG:  statement: select buffer('POLYGON((0.5 
>> 0.5,0.5 1.5,1.5
>>  1.5,1.5 0.5,0.5 0.5))',5);
>> 2004-05-11 17:35:31 LOG:  server process (PID 9006) was terminated by 
>> signal 11
>> 2004-05-11 17:35:31 LOG:  terminating any other active server processes
>> 2004-05-11 17:35:31 LOG:  all server processes terminated; reinitializing
>> 2004-05-11 17:35:31 LOG:  connection received: host=[local] port=
>> 2004-05-11 17:35:31 FATAL:  the database system is starting up
>>
>> What could be the problem?
>>
> 
> 

-- 
Håvard Tveite
Department of Mathematical Sciences and Technology
Agricultural University of Norway
Drøbakveien 14, POBox 5003, N-1432 Ås, NORWAY
Phone: +47 64948857 Fax: +47 64948810 http://www.nlh.no/imt



More information about the postgis-users mailing list