07-12-2017 08:28 PM - edited 07-12-2017 08:42 PM
We transfer WMS/WFS services from the current server to a new server. The WFS instances are ok, but all the WMS ones are not working. The error messages are either "System.NullReferenceException: Object reference not set to an instance of an object" or "System.Runtime.InteropServices.COMException: The remote procedure call failed. (Exception from HRESULT: 0x800706BE)".
Our WFS instances are get features from a Smart Store. We also investigate the service source in the GeoMedia and they are all ok. However, when consuming these WMS instances in GeoMedia on the new server, the performance is much slower than the old one and I wonder whether it could cause some timeout somewhere in the process. We also check the log GWMLog file and the failed one show following errors:
We are not sure what causes this, still investigating.
Appreciate all helps, suggestions and insights on how to resolve this error. I provide the WMS log file here in case it's helpful.
07-26-2017 08:56 AM
This looks as though it failed to set up correctly the connection to the library part of the WebMap Metadata of the Service Source. Am I assuming correctly that neither GetCapabilities nor GetMap work for the WMS instance? And restarting the GeoMedia WebMap service doesn't help as well?
Can you get us a full detailed GWMLog of issuing a GetCapabilities/GetMap request against the WMS instance just after WebMap has been restarted? This way we might be able to track down what caused it to set up improperly.
07-26-2017 04:33 PM
Thanks hbm for looking at this.
I did create a support ticket for this problem. The GetCapabilities and GetMap work for the WMS instance. It shows no issue when we browse it in a Geospatial portal instance. However, we can quite easily reproduce it when we consume it in GeoMedia Desktop client. In the workspace, if we choose to add all layers then the issue is likely to occur. Additionally, one of the WMS instance is used to create WMTS instance and when we start the CacheFillerService and CacheFillerManagerService, we also observe this error in GWMLog.
07-27-2017 02:28 AM
2017-07-14 11:57:03 (11.587463) - Create SS 2017-07-14 11:57:03 (11.834376) - New SS 0 2017-07-14 11:57:03 (11.835924) - GMWS: Enter MapURL
These lines from the GWMLog file are the most interesting. The "New SS 0" means that there was a failure in creating a LibraryStorageService object. Unfortunately, no error code is logged, and the processing ends here for connecting to the WebMap Publisher Metadata. The last should actually be preceeded by some more logging of setting up the WebMap Publisher Metadata, but the exception has been swallowed somewhere and GMWS proceeded happily to only fail further down the road.
Am I correct in assuming you have WebMap put error messages in the Windows Event Log?
I'm not exactly sure what might be the direct cause of the failure here, as I've already said that there is no specific error code logged, but I'm inclined to believe that the object creation wasn't successful because of memory pressure on the MapSvr.exe process. Can you verify that you are not hitting any limits there?
07-27-2017 07:27 PM - edited 07-27-2017 08:53 PM
The webmap did put error messages in Window Event log, but just general error message; it provides GWMLog id if we want to look at it in detail. Here are what showing in the Window event log when the issue occurs:
Here is the server configuration:
We also monitor the amount of memory MapServer instances use when the wms service is consumed and they are not going above 200mb so I don't think there is any memory pressure on MapServer.exe processes.
Would you mind advising us on what possible circumstances that creating a LibraryStorageService object fails? We could do further investigation and narrow it down?
These WMS instances are configured to run with https, and they have SSL Settings 'RequireSSL' set to true and Client certificates ignored. I wonder whether it could block some communications that only run with http.
07-28-2017 01:01 AM
The logic of the GeoMedia WebMap Map Server assumes that the creation of the object would not fail at any time. That's why there is no logging of the error, only a Event Viewer log message. This is unfortunate, as without an error code to follow, this begins to transform into a psychic debugging session To make matters worse, you suggest that WFS instances are working fine on the machine.
Skimming through the code I can only see two modes of failure for the creation of the required object:
You could try to use a diagnostic tool like Process Monitor (available from Microsoft) to see whether the file gets read actually, or fails to open. But first check if the file is actually there
Other than that, I have never before seen such a failure and am slowly getting out of ideas.
08-03-2017 05:56 PM
Latest updates on the issues. I couldn't reproduce it on my local environment event with client's data. I also went back and tried to reproduce again on their environments but the services are showing no issues. We belive after rebooting the servers, all settings such as DCom config are functioning correctly so we will leave it at that but still keep an eye on this.
Thank you for looking at the issue, ideas and suggestions.