OpenDAP https behind Proxy

조회 수: 6 (최근 30일)
Luke Robison
Luke Robison 2021년 3월 10일
댓글: daruzi 2021년 4월 5일
Hello,
I'm using Windows Matlab 2020b. I am attempting to read HTTPS OpenDAP data from matlab behind a proxy.
I can confirm with wget and my web browser that the proxy works for both http and https to the tds.hycom.org domain.
For Matlab, I've set HTTP_PROXY=proxy.mycompany.com:3129 and HTTPS_PROXY=proxy.mycompany.com:3129. I've done this from Windows 10's Settings => Edit Environment Variables for your account. After setting those variables I start a new matlab.
test HTTP, it works:
>> ncinfo('http://tds.hycom.org/thredds/dodsC/GLBy0.08/expt_93.0')
ans =
struct with fields:
Filename: 'http://tds.hycom.org/thredds/dodsC/GLBy0.08/expt_93.0'
Name: '/'
Dimensions: [1×4 struct]
Variables: [1×14 struct]
Attributes: [1×10 struct]
Groups: []
Format: 'classic'
test HTTPS, it fails:
>> ncinfo('https://tds.hycom.org/thredds/dodsC/GLBy0.08/expt_93.0');
Error using netcdflib
The NetCDF library encountered an error during execution of 'open' function - 'I/O failure
(NC_EIO)'. If the data source was an OPeNDAP URL, see the OPeNDAP Troubleshooting section in the
Users Guide.
Error in netcdf.open (line 67)
[varargout{:}] = netcdflib ( 'open', filename, varargin{1} );
Error in internal.matlab.imagesci.nc/openToRead (line 1278)
this.ncRootid = netcdf.open(this.Filename,'NOWRITE');
Error in internal.matlab.imagesci.nc (line 121)
this.openToRead();
Error in ncinfo (line 88)
ncObj = internal.matlab.imagesci.nc(ncFile);
My company's IT has confirmed that Matlab is making the request and getting a response from the server.
Is this a known limitation of the netcdf library matlab is using? Are there additional ways to get debugging information or understand the cause of the failure?
Related posts:
https://www.mathworks.com/matlabcentral/answers/658718-problem-to-access-opendap-data-behind-https-urls notes that https didn't work for a particular URL in 2019b but a Mathworks Saff memeber notes that it works in 2020b (my version).
Thank you,
Luke

답변 (1개)

daruzi
daruzi 2021년 3월 31일
>> ncinfo('https://tds.hycom.org/thredds/dodsC/GLBv0.08/expt_53.X/data/2006')
ans =
Filename: 'https://tds.hycom.org/thredds/dodsC/GLBv0.08/expt_53.X/data/2006'
Name: '/'
Dimensions: [1×4 struct]
Variables: [1×14 struct]
Attributes: [1×9 struct]
Groups: []
Format: 'classic'
  댓글 수: 2
Luke Robison
Luke Robison 2021년 4월 2일
This does not work behind a proxy. Are you behind a proxy?
daruzi
daruzi 2021년 4월 5일
  • I was able to download the data using HTTPS

댓글을 달려면 로그인하십시오.

제품


릴리스

R2020b

Community Treasure Hunt

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

Start Hunting!

Translated by