1.复制hadoop-eclipse-plugin-2.6.0.jar插件到eclipse的plugins目录下(hadoop2.6的插件,在hadoop自带上没有,要上网下载,多试几个
如果是从ubuntu自带的软件中心安装elcipse的话,则安装目录为:/usr/share/eclipse/dropins/sdk/plugins/
不是在/usr/share/eclipse/plugins
sudo cp hadoop-eclipse-plugin-2.6.0.jar /usr/share/eclipse/dropins/sdk/plugins/
2.重启eclipse,配置Hadoop installation directory
如果插件安装成功,打开Windows—Preferences后,在窗口左侧会有Hadoop Map/Reduce选项,点击此选项,在窗口右侧设置Hadoop安装路径。
3.配置Map/Reduce Locations
打开Windows—Open Perspective—Other 选择Map/Reduce,点击OK
4.在右下方看到Map/Reduce Locations,点击Map/Reduce Location选项卡,点击右边小象图标,打开Hadoop Location配置窗口:
注意:MR Master和DFS Master配置必须和mapred-site.xml和core-site.xml等配置文件一致
5.测试
用wordcount例子来测试,可参考http://www.cnblogs.com/aijianiula/p/3854372.html