一 Hadoop运行模式
(1)本地模式(默认模式): 不需要启用单独进程,直接可以运行, 测试和开发时使用。
(2)伪分布式模式: 等同于完全分布式,只有一个节点。
(3)完全分布式模式:多个节点一起运行。
下面是官网给出的原文:
This will display the usage documentation for the hadoop script.
Now you are ready to start your Hadoop cluster in one of the three supported modes:
二 官网提供案例
1) grep
首先创建inputForGrep目录存放输入文件
cp etc/hadoop/*.xml inputForGrep/ 将hadoop下面的所有xml文件cp到输入文件下面用于处理
执行以下grep命令
查看运行结果