win7下Cygwin搭建Hadoop开发环境(由于win7环境不同导致本文章并不一定适合所有的win7用户)
来源:互联网 发布:centos修改时间 编辑:程序博客网 时间:2024/06/06 06:32
第一步:安装JDK
略。
第二步:安装Cygwin
官方网址:http://www.cygwin.com/ 下载setup.exe
安装时选择相应的安装包:
Base-->sed
Editors-->vim
Libs-->
Net-->OpenSSH
第三步:配置Windows系统变量
jdk安装:
JAVA_HOME=E:\Program Files\Java\jdk1.6.0_22
path中添加 jdk,jre:
%JAVA_HOME%\bin;%JAVA_HOME%\jre\bin;
path中添加cygwin bin路径:
E:\Program Files\cygwin\bin;E:\Program Files\cygwin\usr\sbin;
环境变量中-->新建变量-->CYGWIN-->对应的值为:ntsec tty
第四步:安装并配置sshd服务
键入命令:
ssh-host-config
本人第一次配置的时候没有成功,然后又卸载Cgywin(卸载cygwin,也不是一件容易的事情),卸载sshd服务,网上有的方法几乎都试过,总算迷迷糊糊就给设置好了。
可参考一下文章:http://pwcrab.blog.163.com/blog/static/16990382220107267443810/ (Cygwin上安装、启动ssh服务失败、ssh localhost失败的解决方案)
http://blog.csdn.net/souichiro/article/details/6284172 (如何在Cygwin中安装并配置SSH)
http://blog.csdn.net/cybercode/article/details/7080729 (cygwin使用总结)
http://blog.csdn.net/woshizy/article/details/4139868 (在windows下安装SSH)
注意:在安装ssh服务的时候仔细阅读,cygwin上的Info信息。
*** Info: On Windows Server 2003, Windows Vista, and above, the*** Info: SYSTEM account cannot setuid to other users -- a capability*** Info: sshd requires. You need to have or to create a privileged*** Info: account. This script will help you do so.*** Info: You appear to be running Windows XP 64bit, Windows 2003 Server,*** Info: or later. On these systems, it's not possible to use the LocalSystem*** Info: account for services that can change the user id without an*** Info: explicit password (such as passwordless logins [e.g. public key*** Info: authentication] via sshd).*** Info: If you want to enable that functionality, it's required to create*** Info: a new account with special privileges (unless a similar account*** Info: already exists). This account is then used to run these special*** Info: servers.*** Info: Note that creating a new user requires that the current account*** Info: have Administrator privileges itself.*** Info: No privileged account could be found.*** Info: This script plans to use 'cyg_server'.*** Info: 'cyg_server' will only be used by registered services.
win7下安装ssh服务,不是一路顺风的。
我的win7安装ssh服务后的变化如下:
具体什么原因,我也不是很清楚。
最后记得,测试你的ssh服务是否安装成功。
第五步:配置Hadoop安装包
下载Hadoop安装包
修改配置文件:
hadoop-env.sh
export JAVA_HOME=/cygdrive/E/Progra~1/Java/jdk1.6.0_22
注意:Program Files改为Progra~1 否则 启动Hadoop的时候会报错。
core-site.xml
<configuration><property><name>fs.default.name</name><value>hdfs://localhost:9000</value></property></configuration>
hdfs-site.xml
<configuration><property><name>dfs.replication</name><value>1</value></property></configuration>
mapred-site.xml
<configuration><property><name>mapred.job.tracker</name><value>localhost:9001</value></property></configuration>
启动Hadoop
格式化HDFS文件系统:(执行此命令,必须进入hadoop的bin目录,而且hadoop的路径不能有空格,所以建议将hadoop安装在根目录)
启动Hadoop守护进程:
验证Hadoop是否启动:
历经千辛万苦,多少个不眠的日夜,多少人都劝我还是去Linux下,也曾经想放弃了,终于还是凭着坚强毅力,成功了。当然,这仅仅是第一步。
- win7下Cygwin搭建Hadoop开发环境(由于win7环境不同导致本文章并不一定适合所有的win7用户)
- win7下Cygwin搭建Hadoop开发环境(由于win7环境不同导致本文章并不一定适合所有的win7用户)
- win7下Cygwin搭建Hadoop开发环境
- win7+Cygwin+Eclipse搭建Hadoop开发环境
- win7+Cygwin+Eclipse搭建Hadoop开发环境
- win7(64位)平台下Cygwin+Eclipse搭建Hadoop单机开发环境 (二) Hadoop的安装
- [Windows]在Win7系统下搭建Eclipse+Cygwin开发环境
- win7(64位)平台下Cygwin+Eclipse搭建Hadoop单机开发环境 (三) 在Eclipse中配置Hadoop
- win7(64位)平台下Cygwin+Eclipse搭建Hadoop单机开发环境 (一) Cygwin(64位)的安装 + ssh的配置
- win7下的eclipse cygwin cdt 搭建C/C++环境
- Win7下Android开发环境的搭建
- win7下android开发环境的搭建
- Win7下Android开发环境的搭建
- Win7环境下搭建Android开发环境
- win7下搭建cocos2d-x androi开发环境不用cygwin的方法
- win7下搭建cocos2d-x androi开发环境不用cygwin的方法
- win7下搭建cocos2d-x androi开发环境不用cygwin的方法
- win7下Eclipse开发Hadoop应用程序环境搭建
- EditView 文本提示信息
- Android4.0源码Launcher启动流程分析
- [bzoj]郁闷的出纳员[Splay求第k大]
- win7远程桌面访问ubuntu12.04
- 完全背包问题总结
- win7下Cygwin搭建Hadoop开发环境(由于win7环境不同导致本文章并不一定适合所有的win7用户)
- ubuntu 12.04 安装JDK
- Cygwin的中文支持(解决乱码)Windows目录下乱码解决
- Ant编译Hadoop 1.0.3的eclipse-plugin插件包
- ubuntu 12.04 在没有断开PPPOE网络连接的情况下无法关机或重启
- 设置chrome浏览器访问过链接的颜色
- linux内核笔记——内核地址空间
- 普通java类(排序)实现Comparable接口重写CompareTo方法
- 字符串四则运算表达式的计算(华为机试)