• hadoop创建两大错误:Bad connection to FS. command aborted. exception和Shutting down NameNod...


    我的hadoop启动后,各个节点都正常,但是无法查看hdfs目录,错误提示

     Bad connection to FS. command aborted.  查了下网上的解决办法,主要是删除tmp下的所有文件,然后格式化就可以了。

    原文:http://www.tuicool.com/articles/J7R3mei

    问题目录表:

    Bad connection to FS. command aborted. exception: Call to localhost/127.0.0.1:8888

    failed on connection exception: java.net.ConnectException: Connection refused

     遇到错误:

    Error代码   收藏代码

    1. 11 / 08 / 18   14 : 56 : 37  INFO ipc.Client: Retrying connect to server: localhost/127.0 . 0   
    2. . 1 : 8888 . Already tried  0  time(s).  
    3. 11 / 08 / 18   14 : 56 : 39  INFO ipc.Client: Retrying connect to server: localhost/127.0 . 0   
    4. . 1 : 8888 . Already tried  1  time(s).  
    5. 11 / 08 / 18   14 : 56 : 41  INFO ipc.Client: Retrying connect to server: localhost/127.0 . 0   
    6. . 1 : 8888 . Already tried  2  time(s).  
    7. 11 / 08 / 18   14 : 56 : 43  INFO ipc.Client: Retrying connect to server: localhost/127.0 . 0   
    8. . 1 : 8888 . Already tried  3  time(s).  
    9. 11 / 08 / 18   14 : 56 : 45  INFO ipc.Client: Retrying connect to server: localhost/127.0 . 0   
    10. . 1 : 8888 . Already tried  4  time(s).  
    11. 11 / 08 / 18   14 : 56 : 47  INFO ipc.Client: Retrying connect to server: localhost/127.0 . 0   
    12. . 1 : 8888 . Already tried  5  time(s).  
    13. 11 / 08 / 18   14 : 56 : 49  INFO ipc.Client: Retrying connect to server: localhost/127.0 . 0   
    14. . 1 : 8888 . Already tried  6  time(s).  
    15. 11 / 08 / 18   14 : 56 : 51  INFO ipc.Client: Retrying connect to server: localhost/127.0 . 0   
    16. . 1 : 8888 . Already tried  7  time(s).  
    17. 11 / 08 / 18   14 : 56 : 53  INFO ipc.Client: Retrying connect to server: localhost/127.0 . 0   
    18. . 1 : 8888 . Already tried  8  time(s).  
    19. 11 / 08 / 18   14 : 56 : 55  INFO ipc.Client: Retrying connect to server: localhost/127.0 . 0   
    20. . 1 : 8888 . Already tried  9  time(s).  

    Error代码   收藏代码

    1. Bad connection to FS. command aborted. exception : Call to localhost/ 127.0 . 0.1: 88   
    2. 88 failed on connection exception: java.net.ConnectException: Connection refused  
    3. : no further information  
    4. <span style= "color: #ff0000;" >  
    5. </span>  

    错误提示“Bad connection to FS. command aborted. exception: Call to localhost/127.0.0.1:88

    88 failed on connection exception: java.net.ConnectException: Connection refused

    : no further information”

     起初怀疑是fs服务没有启动,但反复关闭启动多次后仍没用,请教高手后,被建议重新格式化namenode,就可以了。

    格式化指令如下(在hadoop的bin目录下):

    Shell代码   收藏代码

    1. $ ./hadoop namenode -format  

    成功 之后重启hadoop就可以了

    2,如果显示的像一下错误信息:

    Error代码   收藏代码

    1. $ bin/hadoop fs -ls /  
    2. 11 / 08 / 18   17 : 02 : 35  INFO ipc.Client: Retrying connect to server: localhost/127.0 . 0   
    3. . 1 : 9000 . Already tried  0  time(s).  
    4. 11 / 08 / 18   17 : 02 : 37  INFO ipc.Client: Retrying connect to server: localhost/127.0 . 0   
    5. . 1 : 9000 . Already tried  1  time(s).  
    6. 11 / 08 / 18   17 : 02 : 39  INFO ipc.Client: Retrying connect to server: localhost/127.0 . 0   
    7. . 1 : 9000 . Already tried  2  time(s).  
    8. 11 / 08 / 18   17 : 02 : 41  INFO ipc.Client: Retrying connect to server: localhost/127.0 . 0   
    9. . 1 : 9000 . Already tried  3  time(s).  
    10. 11 / 08 / 18   17 : 02 : 43  INFO ipc.Client: Retrying connect to server: localhost/127.0 . 0   
    11. . 1 : 9000 . Already tried  4  time(s).  
    12. 11 / 08 / 18   17 : 02 : 45  INFO ipc.Client: Retrying connect to server: localhost/127.0 . 0   
    13. . 1 : 9000 . Already tried  5  time(s).  
    14. 11 / 08 / 18   17 : 02 : 46  INFO ipc.Client: Retrying connect to server: localhost/127.0 . 0   
    15. . 1 : 9000 . Already tried  6  time(s).  
    16. 11 / 08 / 18   17 : 02 : 48  INFO ipc.Client: Retrying connect to server: localhost/127.0 . 0   
    17. . 1 : 9000 . Already tried  7  time(s).  
    18. 11 / 08 / 18   17 : 02 : 50  INFO ipc.Client: Retrying connect to server: localhost/127.0 . 0   
    19. . 1 : 9000 . Already tried  8  time(s).  
    20. 11 / 08 / 18   17 : 02 : 52  INFO ipc.Client: Retrying connect to server: localhost/127.0 . 0   
    21. . 1 : 9000 . Already tried  9  time(s).  

    Error代码   收藏代码

    1. Bad connection to FS. command aborted.  

    错误提示“Bad connection to FS. command aborted.”

      把你DataNode上的DFS数据全删了,再重新格式化NameNode。

     即:先将你D盘下tmp目录下所有文件删了,在重复上面第一点的过程

    3, 在cygwin上执行wordcount时报FileNotFoundException

    原因: tmp路径有问题。配置文件mapred-site.xml中mapred.child.tmp默认是"./tmp",在windows里会出问题

    解决:将其改为D:/tmp(这个是windows下默认的,听说改成其他绝对路径也可以,会自动创建),之后重启hadoop即可

  • 相关阅读:
    JS 时间格式化函数
    jQuery 输入框 在光标位置插入内容, 并选中
    js Html结构转字符串形式显示
    .aspx 页面引用命名空间
    sql随机实现,sql GUID
    一个清华女大学生与一个普通二本男大学生的QQ聊天记录
    asp.net inc 的使用
    JS编码,解码. asp.net(C#)对应解码,编码
    SQL的小常识, 备忘之用, 慢慢补充.
    Js 时间间隔计算(间隔天数)
  • 原文地址:https://www.cnblogs.com/catWang/p/4013410.html
Copyright © 2020-2023  润新知