carlos-alberto-silva / rGEDI

rGEDI: An R Package for NASA's Global Ecosystem Dynamics Investigation (GEDI) Data Visualization and Processing.
157 stars 67 forks source link

Authentication issues when walking through "Getting Started" example #11

Closed serbinsh closed 4 years ago

serbinsh commented 4 years ago
> source('~/Data/RS_GIS_Data/NASA_GEDI/SEUS_GEDI_v1.R')
A .netrc file with your Earthdata Login credentials was stored in the output directory 
------------------------------
Downloading file 1/12: GEDI01_B_2019216020716_O03637_T00051_02_003_01.h5
------------------------------
Error in open.connection(con, open = mode) : HTTP error 401.
> #--------------------------------------------------------------------------------------------------#

I input my user and Pass and confirmed that info is correct in the .netrc file. Still getting a 401 error?

serbinsh commented 4 years ago

And to be clear I can login to urs.earthdata.nasa.gov via the web just fine using my user/pass

serbinsh commented 4 years ago

Also I tested a similar approach with wget which worked fine


wget --user [username] --password [password] https://e4ftl01.cr.usgs.gov/GEDI/GEDI01_B.001/2019.08.04/GEDI01_B_2019216020716_O03637_T00051_02_003_01.h5
anapatriciarb commented 4 years ago

Hi, I am also having the same issue. @serbinsh , were you able to solve it? The approach you used did not work for me.

caiohamamura commented 4 years ago

HTTP error 401 is an authentication issue, you probably mistyped your credentials, now you will need to delete manually the .netrc file which should be in the outdir or the working directory you ran the code.

To address this issue we are implementing the suggestions from an issue, please folllow to keep updated: https://github.com/carlos-alberto-silva/rGEDI/issues/9

Also, you can test using wget without providing the credentials in the directory your .netrc file is located. The .netrc is a standard file which many different programs will use, if wget works with the .netrc and gediDownload doesn't than please let us know.