PostGIS vs. Shapefile
Daniele Margotti
margottid at COMUNE.LUGO.RA.IT
Fri Feb 11 02:13:08 PST 2005
>-----Original Message-----
>From: Didrik Pinte [mailto:pinted at tiscali.be]
>Sent: Friday, February 11, 2005 10:39 AM
>To: Daniele Margotti
>Cc: MAPSERVER-USERS at LISTS.UMN.EDU
>Subject: Re: [UMN_MAPSERVER-USERS] PostGIS vs. Shapefile
>
>
>Le vendredi 11 février 2005 à 10:30 +0100, Daniele Margotti a écrit :
>> In /var/log I only have a 0-byte pgsql file (but in my
postgresql.conf
>> I didn't set any debug option...).
>>
>> Inspecting top on the server (which normally is 100% idle), I can see
>> that during elaboration of the map (/cgi-bin/mapserv?mode=browse)
>> involved processes are "mapserv" and "postmaster", that use 100% CPU
>> (sharing it in various %) for about 2 seconds.
>>
>> During query, the process "postmaster" monopolizes CPU with 99.9%
>> load, for many seconds, during which sometimes appear "mapserv" and
>> "httpd"
>> processes: such situation starts when I click with the mouse and ends
>> when the page is completely transmitted to the browser (I can see the
>> page slowly composing, as if I had a 14.4 Kbps connection, instead of
>> being LAN-connected!).
>>
>> With shapefile query, the page is instantaneously shown.
>>
>> Daniele
>
>From rom my point of view, the problem can be one of the following
>
>[1] The query in Pg returns a lot of objects (maybe not drawn) so that
the image creation is slow.
Do you mean "the PAGE creation"?
Image creation (i.e., browsing the map) is fast.
Even if I query only few elements (e.g.: 2 o 3) the query page creation
is fast.
But when elements are some hundreds, querying shapefiles is faster then
PostGIS.
>
>[2] You need to increase the memory (shared_buffers, sort_mem) --> see
how to tune postgres.
>
I'll try.
Thank you,
Daniele
More information about the MapServer-users
mailing list