FAQs
Zeige die ganze FAQ Zum InhaltsverzeichnisGeneral
What is available for books on MapServer?
What is available for books on MapServer?
"Mapping Hacks" by Schuyler Erle, Rich Gibson, and Jo Walsh is available from O'Reilly.
"Web Mapping Illustrated" by Tyler Mitchell is available from O'Reilly. Introduces MapServer and many other related technologies including, GDAL/OGR, MapScript, PostGIS, map projections, etc.
"MapServer: Open Source GIS Development" by Bill Kropla.
Diese FAQ betrifft: MapServer 4.4, MapServer 4.6
How do I compile MapServer for Windows?
How do I compile MapServer for Windows?
See the Win32 Compilation Howto.
What do MapServer version numbers mean?
What do MapServer version numbers mean?
MapServer's version numbering scheme is very similar to Linux's. For example, a MapServer version number of 4.2.5 can be decoded as such:
- 4: Major version number. MapServer releases a major version every two to three years.
- 2: Minor version number. Increments in minor version number almost always relate to additions in functionality.
- 5: Revision number. Revisions are bug fixes only. No new functionality is provided in revisions.
From a developer's standpoint, MapServer version numbering scheme is also like Linux. Even minor version numbers (0..2..4..6) relate to release versions, and odd minor versions (1..3..5..7) correspond to developmental versions.
Is MapServer Thread-safe?
Is MapServer Thread-safe?
Q: Is MapServer thread-safe?
A: Generally, no (but see the next question). Many components of MapServer use static or global data that could potentially be modified by another thread. Under heavy load these unlikely events become inevitable, and could result in sporadic errors.
Q: Is it possible to safely use any of MapServer in a multi-threaded application?
A: Some of it, yes, with care. Or with Python :) Programmers must either avoid using the unsafe components of MapServer or carefully place locks around them. Python's global interpreter lock immunizes against MapServer threading problems; since no mapscript code ever releases the GIL all mapscript functions or methods are effectively atomic. Users of mapscript and Java, .NET, mod_perl, or mod_php do not have this extra layer of protection.
A: Which components are to be avoided?
Q: Below are lists of unsafe and unprotected components and unsafe but locked components.
Unsafe:
- OGR layers: use unsafe CPL services
- Cartoline rendering: static data
- Imagemap output: static data
- SWF output: static data and use of unsafe msGetBasename()
- SVG output: static data
- WMS/WFS server: static data used for state of dispatcher
- Forcing a temporary file base (an obscure feature): static data
- MyGIS: some static data
Unsafe, but locked:
- Map config file loading: global parser
- Setting class and and layer filter expressions (global parser)
- Class expression evaluation (global parser)
- Setting map and layer projections (PROJ)
- Raster layer rendering and querying (GDAL)
- Database Connections (mappool.c)
- PostGIS support
- Oracle Spatial (use a single environment handle for connection)
- SDE support (global layer cache)
- Error handling (static repository of the error objects)
- WMS/WFS client connections: potential race condition in Curl initialization
- Plugin layers (static repository of the loaded dll-s)
Rather coarse locks are in place for the above. Only a single thread can use the global parser at a time, and only one thread can access GDAL raster data at a time. Performance is exchanged for safety.
Diese FAQ betrifft: MapServer 4.6, MapServer 4.8
What does STATUS mean in a LAYER?
Why are there three possible values for STATUS in a LAYER, and what do they mean?
Where is the mapserver log file?
How can I tell mapserv where to put a log file so that I can diagnose problems?
WEB Object ...(snip) .. EMPTY optional URL to forward users to if a query fails. If not defined the value for ERROR is used. Value: [url] ERROR optional, however highly suggested! URL to forward users to if an error occurs. Ugly old MapServer error messages will appear if this is not defined. Values: [url] LOG optional File to log MapServer activity in. Must be writable by the user the web server is running as. Value: [filename]
How can I make my maps run faster?
Some tips on improving performance.
- Tuning your mapfile for performance
- Optimizing the performance of vector data sources
- Optimizing the performance of raster data sources
- Tileindexes for mosaicing and performance
- First ands foremost is hardware. An extra GB of RAM will give your map performance increases beyond anything you're likely to achieve by tweaking your data. With the price of RAM these days, it's cheap and easy to speed up every map with one inexpensive upgrade.
- Use the scientific method. Change one thing at a time, and see what effect it had. Try disabling all layers and enabling them one at a time until you discover which layer is being problematic.
- You can use the shp2img program to time your results. This runs from the command line and draws an image of your entire map. Since it's run from the command line, it is immune to net lag and will give more consistent measurements that your web browser.