performance issues

Frank Warmerdam warmerdam at POBOX.COM
Tue Oct 18 13:54:56 EDT 2005


On 10/18/05, Bart van den Eijnden <bartvde at xs4all.nl> wrote:
> Hi list,
>
> on a very fast Red Hat machine we are running into Mapserver performance
> problems (Mapserver 4.4.2). It's a basic MAP file with 4 shapefiles,
> nothing special. Mapserver debugging reports 0.6 seconds processing, but
> mapserv over the commandline takes a lot more time to finish as you can
> see below. The same applies to shp2img.
>
> Does anybody have an idea what could be going on?
>
> time ./mapserv
> "QUERY_STRING=map=/data/OGC_UMN_services/
> overzichtskaartnl.map&LAYERS=NL%2Dprov,bebouwing,rijkswegen,vaarwegen&REQUEST=GetMap&SERVICE=WMS&FORMAT=image%2Fpng&STYLES=,,,&HEIGHT=450&QUERY_LAYERS=NL%2Dprov,bebouwing,rijkswegen,vaarwegen&VERSION=1.1.0&SRS=EPSG:28992&WIDTH=750&BBOX=%2D116666%2E66666666667%2C285000%2C441666%2E66666666669%2C620000&TRANSPARENT=TRUE&EXCEPTIONS=application/
> vnd.ogc.se_inimage"
> > /tmp/out2.png
>
> CGI Request 1 on process 26586
> msDrawMap(): Layer 3 (NL-prov), 0.034s
> msDrawMap(): Layer 2 (bebouwing), 0.515s
> msDrawMap(): Layer 0 (rijkswegen), 0.016s
> msDrawMap(): Layer 1 (vaarwegen), 0.009s
> msDrawMap(): Drawing Label Cache, 0.000s
> msDrawMap() total time: 0.585s
>
> real    0m5.485s
> user    0m5.300s
> sys     0m0.190s

Bart,

Normally when I run into this sort of problem, I would
build MapServer in debug mode, and run it in gdb.
Then hit "cntl-c" a few times during the run and get
a traceback to see what is going on.  This crude sampling
technique can often identify especially major performance
bottlenecks.

If the statistics on msDrawMap() are accurate then the
bulk of the delay must be somewhere else.  Perhaps the
compression of the PNG (though it does not seem
especially large) or some sort of preprocessing (getting
projections during .map processing?)

Best regards,
--
---------------------------------------+--------------------------------------
I set the clouds in motion - turn up   | Frank Warmerdam, warmerdam at pobox.com
light and sound - activate the windows | http://pobox.com/~warmerdam
and watch the world go round - Rush    | Geospatial Programmer for Rent



More information about the mapserver-dev mailing list