help needed getting WMS server working with mapserver
Fawcett, David
David.Fawcett at STATE.MN.US
Mon Jul 17 05:57:30 PDT 2006
Brent,
I don't see SUPPORTS=WMS_CLIENT in your version output string.
David.
-----Original Message-----
From: UMN MapServer Users List [mailto:MAPSERVER-USERS at LISTS.UMN.EDU] On
Behalf Of Brent Wood
Sent: Saturday, July 15, 2006 10:58 PM
To: MAPSERVER-USERS at LISTS.UMN.EDU
Subject: [UMN_MAPSERVER-USERS] help needed getting WMS server working
with mapserver
Hi....
I've been wrestling with this for a while now, I've no idea why it
doesn't work...
I'm trying to get cgi mapserver working as a WMS server which is
accessible via cgi mapserver or mapscript & a mapfile.
So far I have a WMS enabled cgi mapserver which is able to generate a
map/image OK with wget, curl & other WMS clients such as QGIS. It also
works in http://wms.iter.dk/default.aspx
I am totally unable to get it to work as a layer in a mapserver mapfile,
which should, as I understand it, be reasonably straightforward.
If anyone can let me know why it doesn't work, or how to make it work
I'd be very grateful.....
I'm running a locally compiled mapserver 64bit SUSE 9.3 (it works fine
with everything else I've tried, just not with a mapserver client)
Hopefully there is enough info below to identify the problem, either in
the mapfile defining the WMS layer or in my mapfile which is trying to
access it.
I guess the problem is with the atlas_client.map mapfile, but have
included other info as well...
Thanks,
Brent Wood
The error message I get when accessing the WMS layer is:
msDrawMap(): WMS connection error. Failed to draw WMS layer named
'wms_w'. This most likely happened because the remote WMS server
returned an invalid image, and XML exception or another unexpected
result in response to the GetMap request. Also check and make sure that
the layer's connection URL is valid.
I'm confused because it seem to work with other clients OK.
mapserver version etc info:
baw at SUSE93:/data> /srv/www/cgi-bin/mapserv -v
MapServer version 4.6.1 OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG OUTPUT=WBMP
OUTPUT=SVG SUPPORTS=PROJ SUPPORTS=FREETYPE SUPPORTS=WMS_SERVER
SUPPORTS=WFS_SERVER SUPPORTS=WCS_SERVER INPUT=EPPL7 INPUT=POSTGIS
INPUT=OGR INPUT=GDAL INPUT=SHAPEFILE
the mapfile providing the WMS server is at:
http://203.97.249.147/map_nz/atlas.map
my mapfile (on the same box) accessing this as a WMS layer is (uses a
local IP address for the WMS server):
http://203.97.249.147/map_nz/atlas_client.map
A one line curl command to retrieve the jpg map via WMS is: curl
"http://203.97.249.147/cgi-bin/mapserv?map=/srv/www/htdocs/map_nz/atlas.
map&request=GetMap&service=WMS&layers=w_topo&version=1.1.1&srs=EPSG:4326
&bbox=0,-90,360,90&format=image/jpeg&width=400&height=400&style="
> test.jpg
or via a browser, just enter this URL:
http://203.97.249.147/cgi-bin/mapserv?map=/srv/www/htdocs/map_nz/atlas.m
ap&request=GetMap&service=WMS&layers=w_topo&version=1.1.1&srs=EPSG:4326&
bbox=0,-90,360,90&format=image/jpeg&width=400&height=400&style=
This URL returns the WMS capabilities document fine, as far as I can
tell:
http://203.97.249.147/cgi-bin/mapserv?map=/srv/www/htdocs/map_nz/atlas.m
ap&SERVICE=WMS&REQUEST=GetCapabilities
More information about the MapServer-users
mailing list