I am having touble upload file to hdfs via webhdfs, the followed the example command line in the WebHDFS user guide
curl.exe -i -X PUT -L "http://webhdfsserver:14000/webhdfs/v1/user/TRODev/a.txt?op=CREATE&user.name=TRODev -T a.txt
the command failed with the following error:
HTTP Status 400 - Data upload requests must have content-type set to 'application/octet-stream'
type Status report
message Data upload requests must have content-type set to 'application/octet-stream'
description The request sent by the client was syntactically incorrect.
Any idea on what is wrong with the command? How to set the content-type in the curl command line?
Please help. Thanks.