1

I try this command

curl -L     http://cosmos.lab.fiware.org:14000/webhdfs/v1/user/souleime/file1         &user.name=souleime" -H "X-Auth-Token: *****************" -O

and I get curl(52) Empty reply from server. My file exists on the HDFS.

Zombo
  • 1
  • 62
  • 391
  • 407
Scrpns
  • 31
  • 5

1 Answers1

1

I managed to read my file curl -i -L "http://cosmos.lab.fiware.org:14000/webhdfs/v1/user/souleime/file1?op=open&user.name=souleime" -H "X-Auth-Token: ****************"

?op=open was my problem

Scrpns
  • 31
  • 5
  • Yes, the kind of operation must be added to the URL. The API is the same than the WebHDFS original one (https://hadoop.apache.org/docs/current/hadoop-project-dist/hadoop-hdfs/WebHDFS.html), but with the addition of the OAuth2 token header. – frb Sep 14 '15 at 10:18