Clear Filters
Clear Filters

Retrieve Elevation Data from Web Map Server is not working

6 views (last 30 days)
Hello,
when I run the code to get elevation maps (find it on the page https://it.mathworks.com/help/map/retrieving-elevation-data.html):
layers = wmsfind('nasa.network*elev', 'SearchField', 'serverurl');
layers = wmsupdate(layers);
I get the warning:
Warning: An error occurred while attempting to update layers from the server,
'http://www.nasa.network.com/elev?'. These layers are being removed from the layer
array. The number of layers from this server that are being removed from the layer
array is 11. The error message returned by the server is: 'Expected the
capabilities document from the server, 'http://www.nasa.network.com/elev?', to
contain valid XML.'.
And if I try to display the layers:
disp(layers,'Properties',{'LayerTitle','LayerName'})
I get zero layers:
0x1 empty WMSLayer
Can anyone help? This code was working on March 2017 on my computer. I have tried to make it run over several different internet connections, different computers and Matlab versions but it is never working. I have seen somebody already asked about this but nobody responded.
Thank you.

Accepted Answer

Prashant Arora
Prashant Arora on 19 Jul 2017
Edited: Prashant Arora on 19 Jul 2017
Hi Olga,
I believe the NASA server has changed recently which is causing this issue. To workaround this, you can try and use the following commands:
info = wmsinfo('https://data.worldwind.arc.nasa.gov/elev?');
layers = info.Layer;
layers = wmsupdate(layers);
  3 Comments
Arthur Wu
Arthur Wu on 15 Mar 2019
Hello,
I am experiencing similar error to the original post. When I attempt example from
I get an error while updating the layers from the server (step 3). My exact code is
>> elevation = wmsfind('elevation');
>> gtopolayer = refine(elevation, 'Foundation.GTOPO30', 'SearchField', 'layername');
>> gtopolayer = refine(gtopolayer, 'nfis.org', 'SearchField', 'serverurl');
>> gtopolayer = wmsupdate(gtopolayer, 'AllowMultipleServers', true);
Warning: An error occurred while attempting to update layers from the server,
'https://ca.nfis.org/cubewerx/cubeserv/cubeserv.cgi?'. These layers are being
removed from the layer array. The number of layers from this server that are
being removed from the layer array is 1. The error message returned by the
server is: 'sun.security.validator.ValidatorException: PKIX path building
failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to
find valid certification path to requested target'.
> In wmsupdate>synchronizeLayerArray (line 154)
In wmsupdate (line 95)
>> disp(gtopolayer)
0x0 empty WMSLayer
Properties:
ServerTitle
ServerURL
LayerTitle
LayerName
Latlim
Lonlim
Abstract
CoordRefSysCodes
Details
Methods
I've tried Prashant's answer above, and I get
>> info = wmsinfo('https://data.worldwind.arc.nasa.gov/elev?');
layers = info.Layer;
layers = wmsupdate(layers);
Error using wmsinfo>getDocument (line 348)
WebMapServer encountered the following error while attempting to obtain the
capabilities document from the server:
sun.security.validator.ValidatorException: PKIX path building failed:
sun.security.provider.certpath.SunCertPathBuilderException: unable to find
valid certification path to requested target
Error in wmsinfo (line 316)
capabilities = getDocument(server, timeoutInSeconds);
Has the NASA server changed again to cause this issue?
P.S. I'm using R2018b
Jeremy P
Jeremy P on 27 Sep 2022
Edited: Jeremy P on 27 Sep 2022
any updates from mathworks staff? I'm having the same problem. It seems the old and new nasa address no longer works:
info = wmsinfo('https://data.worldwind.arc.nasa.gov/elev?');
Error using wmsinfo>getDocument (line 348)
WebMapServer encountered the following error while attempting to obtain the capabilities document from the server:
Secure connection to "https://data.worldwind.arc.nasa.gov/elev?REQUEST=GetCapabilities&VERSION=1.3.0&SERVICE=WMS" not established because "Server aborted the SSL handshake". Check your system certificates for expired, missing, or invalid certificates.
Error in wmsinfo (line 316)
capabilities = getDocument(server, timeoutInSeconds);
OR
layers = wmsfind('nasa.network*elev', 'SearchField', 'serverurl');
layers = wmsupdate(layers);
Warning: An error occurred while attempting to update layers from the server,
'http://www.nasa.network.com/elev?'. These layers are being removed from the layer array. The number
of layers from this server that are being removed from the layer array is 9. The error message
returned by the server is: 'The server returned the status 504 with message "Gateway Timeout" in
response to the request to URL
http://www.nasa.network.com/elev?REQUEST=GetCapabilities&VERSION=1.3.0&SERVICE=WMS.'.

Sign in to comment.

More Answers (0)

Products

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!