TEMPO access using wget
TEMPO access using wget
Dear Earthdata forum.
I am trying to retrieve the TEMPO O3, NO2 and HCHO products from Earthdata https://data.asdc.earthdata.nasa.gov/asdc-prod-protected/TEMPO/. I used the script provided by Earthdata and I can download individual files for initial tests.
To implement the retrieval of TEMPO products operationally, we would need to set up our in house acquisition system, which behaves similarly to wget.
I tried this wget
wget -d --user=my_user --password=my_passwd -r --load-cookies cookies.txt -A "*.nc" https://data.asdc.earthdata.nasa.gov/asdc-prod-protected/TEMPO/TEMPO_NO2_L2_V03/YYYY.MM.DD/
To retrieve the listing of files for a particular day but I get a 404 error.
I am aware there is a python package
https://eur03.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fpodaac%2Fdata-subscriber&data=05%7C02%7Croberto.ribas%40ecmwf.int%7Cbac38a6bf80845f659be08dd4aa98770%7C21b711c6aab74d369ffbac0357bc20ba%7C1%7C0%7C638748814205818826%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C0%7C%7C%7C&sdata=Y3n5H%2BY0QROCEucvUIIzIovnVY8n7ucbSzB5y7ib45E%3D&reserved=0
but unfortunately our in house system does not support python.
I am using Linux with wget version
wget -V
GNU Wget 1.19.5 built on linux-gnu.
I am also aware there is a opendap access to the files however, to use opendap, we would need to adapt our in-house system and this will take time. That is why our preferred solution would be to know how to use wget to get the listing of the files inside each YYYY.MM.DD directory. Once we know that we can use our existing system to retrieve the files.
our Linux system is
Description: Red Hat Enterprise Linux release 8.8 (Ootpa)
Could you please provide some insight and guidance on how to configure wget to access the YYYY.MM.DD directories and do the listings of these directories.
Thank you very much in advance
best regards
Roberto Ribas
I am trying to retrieve the TEMPO O3, NO2 and HCHO products from Earthdata https://data.asdc.earthdata.nasa.gov/asdc-prod-protected/TEMPO/. I used the script provided by Earthdata and I can download individual files for initial tests.
To implement the retrieval of TEMPO products operationally, we would need to set up our in house acquisition system, which behaves similarly to wget.
I tried this wget
wget -d --user=my_user --password=my_passwd -r --load-cookies cookies.txt -A "*.nc" https://data.asdc.earthdata.nasa.gov/asdc-prod-protected/TEMPO/TEMPO_NO2_L2_V03/YYYY.MM.DD/
To retrieve the listing of files for a particular day but I get a 404 error.
I am aware there is a python package
https://eur03.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fpodaac%2Fdata-subscriber&data=05%7C02%7Croberto.ribas%40ecmwf.int%7Cbac38a6bf80845f659be08dd4aa98770%7C21b711c6aab74d369ffbac0357bc20ba%7C1%7C0%7C638748814205818826%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C0%7C%7C%7C&sdata=Y3n5H%2BY0QROCEucvUIIzIovnVY8n7ucbSzB5y7ib45E%3D&reserved=0
but unfortunately our in house system does not support python.
I am using Linux with wget version
wget -V
GNU Wget 1.19.5 built on linux-gnu.
I am also aware there is a opendap access to the files however, to use opendap, we would need to adapt our in-house system and this will take time. That is why our preferred solution would be to know how to use wget to get the listing of the files inside each YYYY.MM.DD directory. Once we know that we can use our existing system to retrieve the files.
our Linux system is
Description: Red Hat Enterprise Linux release 8.8 (Ootpa)
Could you please provide some insight and guidance on how to configure wget to access the YYYY.MM.DD directories and do the listings of these directories.
Thank you very much in advance
best regards
Roberto Ribas
Filters:
-
- User Services
- Posts: 1
- Joined: Mon Dec 09, 2024 11:23 pm America/New_York
Re: TEMPO access using wget
Hi Roberto,
The guidance you need could be on this previous Forum post on how to use wget.
viewtopic.php?t=2329
I hope this helps,
David W.
NASA LaRC ASDC
The guidance you need could be on this previous Forum post on how to use wget.
viewtopic.php?t=2329
I hope this helps,
David W.
NASA LaRC ASDC
Re: TEMPO access using wget
Dear user support
I followed your suggestion about accessing with wget and I created the following code
#!/bin/bash
URL="https://data.asdc.earthdata.nasa.gov/asdc-prod-protected/TEMPO/TEMPO_NO2_L2_V03/2025.03.10/"
TOKEN=MY_TOKEN
wget -d --header "Authorization: Bearer $TOKEN" --recursive --no-parent --reject "index.html" --execute robots=off $URL
The goal of this script it to produce a list of the TEMPO files for March 10 2025 (2025.03.10).
However I am getting a 404 error Data not available.
I tried to retrieve one file with the -d debug option
wget -d https://data.asdc.earthdata.nasa.gov/asdc-prod-protected/TEMPO/TEMPO_NO2_L2_V03/2025.03.10/TEMPO_NO2_L2_V03_20250310T235549Z_S014G05.nc
and I see I can get the file after few redirections I retrieve the file. I think my problem seems to be getting the list of the files under the directories YYYY.MM.DD
Any ideas on how to get the listing?
Thank you very much in advance
Best regards
Roberto
I followed your suggestion about accessing with wget and I created the following code
#!/bin/bash
URL="https://data.asdc.earthdata.nasa.gov/asdc-prod-protected/TEMPO/TEMPO_NO2_L2_V03/2025.03.10/"
TOKEN=MY_TOKEN
wget -d --header "Authorization: Bearer $TOKEN" --recursive --no-parent --reject "index.html" --execute robots=off $URL
The goal of this script it to produce a list of the TEMPO files for March 10 2025 (2025.03.10).
However I am getting a 404 error Data not available.
I tried to retrieve one file with the -d debug option
wget -d https://data.asdc.earthdata.nasa.gov/asdc-prod-protected/TEMPO/TEMPO_NO2_L2_V03/2025.03.10/TEMPO_NO2_L2_V03_20250310T235549Z_S014G05.nc
and I see I can get the file after few redirections I retrieve the file. I think my problem seems to be getting the list of the files under the directories YYYY.MM.DD
Any ideas on how to get the listing?
Thank you very much in advance
Best regards
Roberto
-
- Posts: 67
- Joined: Tue Jun 08, 2021 11:29 pm America/New_York
Re: TEMPO access using wget
Hi Roberto,
Please consult the website below for more information on how to use wget to download data from NASA.
https://nasa-openscapes.github.io/earthdata-cloud-cookbook/how-tos/access-data/access-command-line.html
Thanks,
David W.
NASA LaRC ASDC
Please consult the website below for more information on how to use wget to download data from NASA.
https://nasa-openscapes.github.io/earthdata-cloud-cookbook/how-tos/access-data/access-command-line.html
Thanks,
David W.
NASA LaRC ASDC