You are viewing a plain text version of this content. The canonical link for it is here.
Posted to common-commits@hadoop.apache.org by Apache Wiki <wi...@apache.org> on 2007/07/20 05:03:03 UTC

[Lucene-hadoop Wiki] Trivial Update of "WordCount" by TedDunning

Dear Wiki user,

You have subscribed to a wiki page or wiki category on "Lucene-hadoop Wiki" for change notification.

The following page has been changed by TedDunning:
http://wiki.apache.org/lucene-hadoop/WordCount

------------------------------------------------------------------------------
  To run the example, the command syntax is[[BR]]
  bin/hadoop jar hadoop-*-examples.jar wordcount [-m <#maps>] [-r <#reducers>] <in-dir> <out-dir>
  
- All of the files in the input directory (called in-dir in the command line above) are read and the counts of words in the input are written to the output directory (called out-dir above).  It is assumed that both inputs and outputs are stored in HDFS.  If your input is not already in HDFS, but is rather in a local file system somewhere, you need to copy the data into HDFS using a command like this:[[BR]]
+ All of the files in the input directory (called in-dir in the command line above) are read and the counts of words in the input are written to the output directory (called out-dir above).  It is assumed that both inputs and outputs are stored in HDFS (see ImportantConcepts).  If your input is not already in HDFS, but is rather in a local file system somewhere, you need to copy the data into HDFS using a command like this:[[BR]]
  bin/hadoop dfs -mkdir <hdfs-dir>
  bin/hadoop dfs -copyFromLocal <local-dir> <hdfs-dir>