hadoop - webhdfs create file exception -


i using hadoop 2.7.1 on centos 7

if want use webhdfs hadoop cluster

i should configure property

<property>       <name>dfs.webhdfs.enabled</name>       <value>true</value> </property> 

but else?

my name node ip 192.168.4.128

when use firefox on windows 8 , send request

http://192.168.4.128:50070/webhdfs/v1/hadoopdir/a.txt/?user.name=system&op=open 

i can open file , see it's content

but when send put request

http://192.168.4.128:50070/webhdfs/v1/hadoopdir/b.txt/?user.name=system&op=create&data=true 

i following response

{"remoteexception":{"exception":"illegalargumentexception","javaclassname":"java.lang.illegalargumentexception","message":"invalid value webhdfs parameter \"op\": no enum constant org.apache.hadoop.hdfs.web.resources.getopparam.op.create"}} 

why in get operation opening file ok, not in put.

any other configurations should handled process request?

webhdfs performs 4 kinds of http operations (get, post, put, delete) whereas web browsers support , post.

include plugins restclient (for firefox), advanced rest client (for chrome) sending http put , http delete requests.

alternatively, can use curl command line.

note: webhdfs enabled default. so, property added in hdfs-site.xml redundant (just saying).


Comments

Popular posts from this blog

inversion of control - Autofac named registration constructor injection -

verilog - Systemverilog dynamic casting issues -

ios - Change Storyboard View using Seague -