Can't connect using wget or curl to https://oceandata.sci.gsfc.nasa.gov/ob/
-
- Posts: 2
- Joined: Tue Apr 11, 2023 6:11 pm America/New_York
- Been thanked: 1 time
Can't connect using wget or curl to https://oceandata.sci.gsfc.nasa.gov/ob/
About a week ago the daily script I run to access CyAN data stopped working. After further investigation, I can't download using wget or curl. The file that is downloaded is not able to be loaded as it was before. I am able to manually download at: https://oceandata.sci.gsfc.nasa.gov/directdataaccess/Level-3%20Mapped/Merged-S3-CYAN/2023/100/
I have a ~/.netrc with login and password. I've also tried using "@appkey={APP_KEY}" but that doesn't work either. Any help would be much appreciated.
Here are the command line calls I have used to access these files:
wget --load-cookies ~/.urs_cookies --save-cookies ~/.urs_cookies --keep-session-cookies https://oceandata.sci.gsfc.nasa.gov/ob/getfile/L2023100.L3m_DAY_CYAN_CI_cyano_CYAN_CONUS_300m_7_5.tif -O data/cyan/L2023100.L3m_DAY_CYAN_CI_cyano_CYAN_CONUS_300m_7_5.tif
curl -O -b ~/.urs_cookies -c ~/.urs_cookies -L -n https://oceandata.sci.gsfc.nasa.gov/ob/getfile/L2023100.L3m_DAY_CYAN_CI_cyano_CYAN_CONUS_300m_7_5.tif -o data/cyan/L2023100.L3m_DAY_CYAN_CI_cyano_CYAN_CONUS_300m_7_5.tif
I have a ~/.netrc with login and password. I've also tried using "@appkey={APP_KEY}" but that doesn't work either. Any help would be much appreciated.
Here are the command line calls I have used to access these files:
wget --load-cookies ~/.urs_cookies --save-cookies ~/.urs_cookies --keep-session-cookies https://oceandata.sci.gsfc.nasa.gov/ob/getfile/L2023100.L3m_DAY_CYAN_CI_cyano_CYAN_CONUS_300m_7_5.tif -O data/cyan/L2023100.L3m_DAY_CYAN_CI_cyano_CYAN_CONUS_300m_7_5.tif
curl -O -b ~/.urs_cookies -c ~/.urs_cookies -L -n https://oceandata.sci.gsfc.nasa.gov/ob/getfile/L2023100.L3m_DAY_CYAN_CI_cyano_CYAN_CONUS_300m_7_5.tif -o data/cyan/L2023100.L3m_DAY_CYAN_CI_cyano_CYAN_CONUS_300m_7_5.tif
Last edited by johnwoodill on Wed Apr 12, 2023 2:46 pm America/New_York, edited 1 time in total.
Filters:
-
- Posts: 395
- Joined: Mon Jun 22, 2020 5:24 pm America/New_York
- Has thanked: 8 times
- Been thanked: 8 times
Re: Can't connect using wget or curl to https://oceandata.sci.gsfc.nasa.gov/ob/
Thanks for reporting. Taking a look..
-
- Posts: 2
- Joined: Tue Apr 11, 2023 6:11 pm America/New_York
- Been thanked: 1 time
Re: Can't connect using wget or curl to https://oceandata.sci.gsfc.nasa.gov/ob/
Thanks. Sorry, there was a typo above for the wget call where the output -O was not defined correctly.
It appears to be working now. The original script was using the appkey as follows:
"https://oceandata.sci.gsfc.nasa.gov/ob/getfile/L2023100.L3m_DAY_CYAN_CI_cyano_CYAN_CONUS_300m_7_3.tif?appkey={CYAN_APPKEY}"
This is what stopped working. When I add "wget --load-cookies ~/.urs_cookies --save-cookies ~/.urs_cookies --keep-session-cookies " today it appears to be working.
I'll report back if I run into additional issues. Much appreciated.
It appears to be working now. The original script was using the appkey as follows:
"https://oceandata.sci.gsfc.nasa.gov/ob/getfile/L2023100.L3m_DAY_CYAN_CI_cyano_CYAN_CONUS_300m_7_3.tif?appkey={CYAN_APPKEY}"
This is what stopped working. When I add "wget --load-cookies ~/.urs_cookies --save-cookies ~/.urs_cookies --keep-session-cookies " today it appears to be working.
I'll report back if I run into additional issues. Much appreciated.
Re: Can't connect using wget or curl to https://oceandata.sci.gsfc.nasa.gov/ob/
Hello,
Please clear your browser cache and visit appkey web page to make sure that you're using the correct appkey.
Let us know if this helps.
Thank you
Please clear your browser cache and visit appkey web page to make sure that you're using the correct appkey.
Let us know if this helps.
Thank you