MapServer 4.10 Available
MapServer 4.10 has been released! This is a fairly significant release with a lot of new features and fixes. You can see a list of all the changes on the 4.10 change log. One of the most useful ones for me is adding OGC WxS wrappers for MapScript. That makes it easier to create WMS and WFS servers with MapServer, as you won’t have to go through the MapServer CGI.
I updated the download files in the Windows installation instructions in previous posts (the one for CGI and one for FastCGI), so now those instructions will install the latest versions of both PHP MapScript (4.10) and PHP (5.2). It also includes eAccelerator, a PHP extension that caches precompiled optimized binaries of your pages to speed things up a bit.
I’ve swiped the new release of MapServer from the MS4W package. If you can run Apache in production in your environment, I recommend it over my instructions. Installing it is a matter of unzipping a folder and clicking on a batch file. If you’re stuck with IIS, however, you’ll have to go through the minor unpleasantnesses described in this blog or something like it.
One great thing about the MapServer release in the MS4W package is it compiled with a lot more features. That includes support for SDE 9.1 and Oracle 10g (if you have the DLL’s), GDAL/OGR, Mr. Sid, and some other niceties.
A couple of things to note. The new version of MapServer seems averse to inaccurate cases in your map configuration file and code (i.e. a field name of “ZONE” will not work if the actual field name is “zone”). Programming purists will like this. The rest of us will stick out our bottom lips and sulk for the five minutes it will take to fix our code.
The other thing - getting this latest release up and running took me a while. It was no problem on my XP laptop, but on our production web server PHP refused the load the mapscript dll no matter what I tried. I ran dependency walker, tried different versions of GDAL, recompiled dll’s, tried different versions of PHP - no luck. Thinking maybe it was a Windows 2000 problem, I make a virtual Windows 2000 Server instance in VMware on my Ubuntu Linux box at home and it installed without a hitch. Turns out the problem was our production server had an older version of the Mr. Sid DLL in a directory in the PATH environmental variable and MapServer was trying to use it instead of the one in our mapserver_binaries folder. Ah, dependency hell, my dear friend, how I’ve missed you at home since I moved to Linux. Sigh.
I did discover one useful diagnostic tool in my struggles. If you run phpinfo() from a web page, it will tell you if a module doesn’t load, but it isn’t very descriptive. If you run that .php file from the command line:
c:\PHP\php.exe phpinfo.php
A windows box will pop up with much more detailed information if an extension isn’t loading. In this case it named the aforementioned Mr. Sid dll as the culprit, and I was able to hunt down problem.
Good luck!