Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to establish SSL connection. #6

Closed
Milutinke92 opened this issue Jun 13, 2016 · 8 comments
Closed

Unable to establish SSL connection. #6

Milutinke92 opened this issue Jun 13, 2016 · 8 comments

Comments

@Milutinke92
Copy link

Milutinke92 commented Jun 13, 2016

When the download starts, file starts to download:
query_results.xml, file_dir.xml.
Then on the following link for example:
https://scihub.copernicus.eu/apihub/odata/v1/Products('326b6316-f7ae-4ae6-91e5-2121f3aedfe1')/Nodes('S2A_OPER_PRD_MSIL1C_PDMC_20160526T094552_R051_V20160521T105553_20160521T105553.SAFE')/Nodes('GRANULE')/Nodes
It says: Unable an to establish SSL connection. And "granule_dir.xml" is empty.

When I set https_proxy="" then there is no error.
But he's getting more time to send request for file.

I couldn't find your email to ask you, so I attach this question here. Sorry.

@olivierhagolle
Copy link
Owner

Sorry for replying late. This is indeed the place where issues should be posted.
I am not sure i understand this issue very well.
Could you please provide your command lines so that i can test ?
Best regards,
Olivier

@Milutinke92
Copy link
Author

I download a fresh copy of your api, and setup like this:
export https_proxy=http://proxy.rcub.bg.ac.rs:8080
export http_proxy=http://proxy.rcub.bg.ac.rs:8080

Now the downloading started but now there is a second issue.
It saty "404 not found".
https://scihub.copernicus.eu/odata/v1/Products('b95cb837-6606-484b-89d6-b10bfaead9bd')/Nodes('S2A_OPER_PRD_MSIL1C_PDMC_20160626T152756_R136_V20160626T093035_20160626T093744.SAFE')/Nodes('DATASTRIP')/Nodes('S2A_OPER_MSI_L1C_DS_MPS__20160626T131738_S20160626T093744_N02.04')/Nodes
If you go to this link (copied from console when running api) you will see "page not found"

BUT, if you change link into https://scihub.copernicus.eu/dhus/odata/v1/Products('b95cb837-6606-484b-89d6-b10bfaead9bd')/Nodes('S2A_OPER_PRD_MSIL1C_PDMC_20160626T152756_R136_V20160626T093035_20160626T093744.SAFE')/Nodes('DATASTRIP')/Nodes('S2A_OPER_MSI_L1C_DS_MPS__20160626T131738_S20160626T093744_N02.04')/Nodes
The file is there.

So /dhus/odata/ works, /odata/ doesn't work.

I tried to add --dhus into console, and that's okay for first file granule_dir or something like that, but then he tries to download from /odata/ all other files.

Help?

@Milutinke92
Copy link
Author

I tried to modify your API, to insert /dhus/ in every link.
The download start. But on some link same error: SSL Connection could not be establish.

I upload you log.txt file to see console output: http://www102.zippyshare.com/v/H9TsdBND/file.html

@Milutinke92
Copy link
Author

This is fresh copy of API downloaded from here. When I add --dhus same error.
1
2

And one more thing. it happens that SSL conection sometimes apear on first file, sometimes on 10th and etc. no rule for that.

@olivierhagolle
Copy link
Owner

olivierhagolle commented Jun 27, 2016

Thanks Milutinke92.
I have solved this issue (error 404) on Saturday, (it is due to an inconsistency within the files provided by scihub) please pull again the reprository.
I am interested to know if it solves the problem for you too

Regarding the SSL issue, I have never seen it on my side, so I do not know how I can resolve it. Maybe is it a problem with your proxy ?
Olivier

@Milutinke92
Copy link
Author

Milutinke92 commented Jun 27, 2016

I did and same issue.

wget --no-check-certificate --user="xxxx" --password="xxx" --continue --output-document=temp.xml "https://scihub.copernicus.eu/apihub/odata/v1/Products('c4f7c88d-c6b0-473a-879f-a9819f2f1113')/Nodes('S2A_OPER_PRD_MSIL1C_PDMC_20160620T201325_R051_V20160620T105336_20160620T105336.SAFE')/Nodes('HTML')/Nodes"
--2016-06-27 12:42:48-- https://scihub.copernicus.eu/apihub/odata/v1/Products('c4f7c88d-c6b0-473a-879f-a9819f2f1113')/Nodes('S2A_OPER_PRD_MSIL1C_PDMC_20160620T201325_R051_V20160620T105336_20160620T105336.SAFE')/Nodes('HTML')/Nodes
Resolving proxy.rcub.bg.ac.rs (proxy.rcub.bg.ac.rs)... 147.91.1.42, 147.91.1.43, 147.91.1.44, ...
Connecting to proxy.rcub.bg.ac.rs (proxy.rcub.bg.ac.rs)|147.91.1.42|:8080... connected.
Unable to establish SSL connection.
Traceback (most recent call last):
File "Sentinel_download.py", line 351, in
get_dir('HTML',url_html_dir,product_dir_name,wg,auth,wg_opt,value)
File "Sentinel_download.py", line 67, in get_dir
download_tree(product_dir_name+'/'+dir_name,"temp.xml",wg,auth,wg_opt,value)
File "Sentinel_download.py", line 40, in download_tree
urls,types,names=get_elements(xml_file)
File "Sentinel_download.py", line 29, in get_elements
line=fic.readlines()[0].split('')
IndexError: list index out of range
stefan@W04704:~/Downloads/Sentinel-download-master$

@olivierhagolle
Copy link
Owner

As I said, the new patch corrects for the error 404, but not for the issue with your proxy.
Maybe should you ask support from you proxy support.
Olivier

@Milutinke92
Copy link
Author

It's something with our proxy on faculty. Thanks for all reply!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants