Getting wrong MIME Type from Geoserver

المشرف العام

Administrator
طاقم الإدارة
Geoserver MimeType Problem

Environment: OL2, Tomcat 7, Geoserver 2.7.0, PostGIS-DataStore in Geoserver

I have created a Website, first at Local Machine, then transferred the project to AcuGIS. Before I was working with XAMPP and Apache, Geoserver was on different Location (localhost:5000) and everything was working fine, but after transfer I only get "Pink Tiles" and mime type error.

On AcuGIS they offer a package with geoserver, tomcat etc. Transferring, setting up connections to PostGIS (I have created PostGIS stores in Geoserver) everything seems working fine, even the Proxy works. Okay.

Layer previews in Geoserver with OL3 (even though I am working with OL2) are showing up as expected.

In fact I the core use of my WebApplication is loading GeoJSON Layers. But to show additional Informations (parameterized SQL Views, WFS for creating features) I rely on getting Geoserver and WMS / WFS to work.

So in my OL Javascript I request the exact URL where my Geoserver Data Store and everything is:

function init() { OpenLayers.ProxyHost = "/cgi-bin/proxy.cgi?url="; var format = "image/png"; var trailsGeoserver = new OpenLayers. //"http://localhost:5000/geoserver/Master/wms"; "http://mtb- trailfinder.com:80/geoserver/MASTER/wms" var trailsGeoserver = new OpenLayers.Layer.WMS( "Trails Steiermark", "http://mtb-trailfinder.com:80/geoserver/MASTER/wms" , { "LAYERS": 'Master:scale', transparent: true, format:format }, { buffer: 0, displayOutsideMaxExtent: true, isBaseLayer: false, projection: 'EPSG:4326', // dient nur der Information visibility: false, transitionEffect: 'null' } ); map.addLayer(trailsGeoserver); } // end of Init This is my reduced code for troubleshooting, with just one WMS, instead of 10. So the funny thing is, that replacing the URL of the WMS with my localhost:5000 Adress, everything works fine!

However putting the URL to the Geoserver on my WebHost (which in fact is showing me the right png in layer preview) it comes back as mal formatted, with

"Content-Type: application/vnd.ogc.se_xml;charset=UTF-8"

Status Code is allright (200). And this is my error log in Chrome Debugger:

Resource interpreted as Image but transferred with MIME type application/vnd.ogc.se_xml: "link..." (cannot displayed due to lack of reputation). When I click on that link I get back an XML File with following Message:

Could not find layer Master:scale

So I am really confused, because on my localsystem everything works just fine, took me a week to investigate the problems I am facing right now, without any real success.

I also have been looking in all Forums, but they all differ from my problem.

//

So until now my guess is, that the tomcat server is not working properly. Geoserver instead works fine, asuming this because of the working Layer-Previews.

Something messes up the Server response on AcuGIS. But I don´t have any clue what this is.

I have waited for a long time to step out of troubleshooting by my own, so help would be extremely appreciated.

For inspection the Website is available on www.mtb-trailfinder.com.

Thanks!



أكثر...
 
أعلى