Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Updating a hadoop HDFS file

Tags:

hadoop

hdfs

I am a newbie to Hadoop. I have been reading that HDFS is mostly about "writing once, reading any times". I have a use case where I may have to make modifications to the files stored in HDFS. I have been researching if there are any ways of doing this.

My question is will it be possible to load the HDFS file into HBase, do the modifications, and save it back in HDFS, and deleting the original file. Please let me if this feasible.

like image 409
Srini Subramanian Avatar asked Oct 08 '22 20:10

Srini Subramanian


1 Answers

If you need to update values in a file you are much better of using HBase. You can still use your HBase table in your MR jobs via the TableInputFormat and TableOutputFormat. If you want to append data you can use any of the hadoop versions that support hdfs append such as 0.20.205.0.

like image 138
Steve Severance Avatar answered Oct 12 '22 11:10

Steve Severance