unable to establish SSL connection

Use this Forum to find information on, or ask a question about, NASA Earth Science data.
Post Reply
zbegg
Posts: 4
Joined: Sun Jan 13, 2019 9:58 pm America/New_York
Answers: 0

unable to establish SSL connection

by zbegg » Wed Apr 28, 2021 11:44 pm America/New_York

i had setup a crontab which was downloading daily chlorophyll data over the years. Since last month i have been experiencing data not downloading. when i run the script manually it states : unable to establish SSL connection. appreciate any assistance on this.
my server runs from AWS and is built on Ubuntu 16.04.6. I have followed the steps outlined in https://oceancolor.gsfc.nasa.gov/data/download_methods.
i have created a .netrc file with username/password. i am using wget yo download, wget version 1.17.1

this is my code:
if '$PERIOD' == 'daily':
for delta in range(4):
date_stamp = today + timedelta(-delta)
date_stamp = date_stamp.timetuple()
file_name = 'A%4d%03d.L3m_DAY_CHL_chlor_a_4km' % (date_stamp.tm_year, date_stamp.tm_yday)
nc_file_name = file_name + '.nc'
nc_file_path = 'daily/' + nc_file_name
full_url = url + nc_file_name
print full_url
if os.path.exists(nc_file_path):
continue
else:
try:
check_call(['wget','-nc', '--auth-no-challenge=on', '--content-disposition', 'https://oceandata.sci.gsfc.nasa.gov/cgi/getfile/', '--random-wait', '-P', 'daily'])
except CalledProcessError as cpe:
print cpe.message;
print '\n'
continue
except OSError as oe:
print oe.strerror;
print '\n'
print full_url;
print '\n'
continue
by gnwiii » Fri Apr 30, 2021 8:31 am America/New_York

Code: Select all

https://oceancolor.gsfc.nasa.gov/data/download_methods/
mentions using an AppKey and also Python downloaders. For me, the python scripts have been more reliable than wget.
Go to full post

Tags:

OB.DAAC - amscott
User Services
User Services
Posts: 350
Joined: Mon Jun 22, 2020 5:24 pm America/New_York
Answers: 1
Has thanked: 8 times
Been thanked: 3 times

Re: unable to establish SSL connection

by OB.DAAC - amscott » Thu Apr 29, 2021 11:11 am America/New_York

I would suggest upgrading to a more current version of wget to see if that would resolve the issue.

gnwiii
Posts: 713
Joined: Fri Jan 29, 2021 5:51 pm America/New_York
Answers: 2
Has thanked: 1 time

Re: unable to establish SSL connection

by gnwiii » Fri Apr 30, 2021 8:31 am America/New_York

Code: Select all

https://oceancolor.gsfc.nasa.gov/data/download_methods/
mentions using an AppKey and also Python downloaders. For me, the python scripts have been more reliable than wget.

zbegg
Posts: 4
Joined: Sun Jan 13, 2019 9:58 pm America/New_York
Answers: 0

Re: unable to establish SSL connection

by zbegg » Fri May 21, 2021 2:01 pm America/New_York

thank you for your suggestion. I have upgraded to wget version 1.21, the latest one. now i see the error as: HTTP request sent, awaiting response... Read error (Connection timed out) in headers.
Retrying.
I have .netrc as well as .urs_cookies

appreciate any advice please

OB.DAAC - SeanBailey
User Services
User Services
Posts: 1464
Joined: Wed Sep 18, 2019 6:15 pm America/New_York
Answers: 1
Been thanked: 5 times

Re: unable to establish SSL connection

by OB.DAAC - SeanBailey » Tue May 25, 2021 8:02 am America/New_York

Well, "Connection timed out" suggests some server in the mix failed to respond within the timeout defined for wget. Run the wget command with the --debug option, which will print out a lot of information. Some of it might help you identify the issue.

Sean

Post Reply