zoukankan      html  css  js  c++  java
  • Kudu遇到的坑,是真的坑~

    在我使用spark对接kudu的过程中,出现如下错误:

    坑1: Caused by: org.apache.kudu.client.NoLeaderFoundException

    Caused by: org.apache.kudu.client.NoLeaderFoundException: Master config (192.168.1.117:7051) has no leader.
    Exceptions received: org.apache.kudu.client.RecoverableException:
    [peer master-192.168.1.117:7051(192.168.1.117:7051)] encountered a read timeout; closing the channel

    重点分析:

    Master config (192.168.1.117:7051) has no leader : 客户端找不到master的leader
    encountered a read timeout : 遭遇读取超时

    因为kudu客户端连接kudu服务器时,服务器返回master的主机名

    要想知道master返回的主机名是什么,可以直接到web-ui上去查看。
    注意是master的web-ui,即8051端口页面:
    在这里插入图片描述

    查看自己master 返回的leader:
    http://192.168.1.117:8051/masters

    rpc_addresses { host: "spark003" port: 7051 } 
    http_addresses { host: "spark003" port: 8051 } 
    software_version: "kudu 1.7.0-cdh5.15.0 (rev 7dd4889729bb5ee0b331a5a6c3cd4427dbf79308)" 
    https_enabled: false
    

    这个rpc_addresses 的 spark003 会返回给你的客户端,这个时候你的客户端就得能够解析才行

    问题就是出在这儿。我本地的hosts 文件并没有这个解析

    我是windows ,hosts文件位置在:

    C:WindowsSystem32driversetc

    # add a record
    192.168.1.117 spark003
    

    最后,问题,完美解决~~

    坑2: Caused by: java.lang.IllegalArgumentException: cannot import authentication data from a different user: old=’’, new=‘liuge’

    在这里插入图片描述

    最终解决:

    [root@spark001 conf]# vim master.gflagfile
    -rpc_encryption=disabled
    -rpc_authentication=disabled
    -trusted_subnets=0.0.0.0/0
    
    # 重启master server
    [root@spark001 conf]# /etc/init.d/kudu-master restart
    Stopped Kudu Master Server:                                [  OK  ]
    Started Kudu Master Server (kudu-master):                  [  OK  ]
    [root@spark001 conf]# 
    
    

    坑3:Exception in thread “main” org.apache.kudu.client.NonRecoverableException: can not complete before timeout: KuduRpc

    我一开始对于这个错误,还真的是很纳闷。各种搜索解决,都无果,
    后来,我尝试把tserver.gflagfile 也添加如上配置就可以了

    [root@spark001 conf]# vim tserver.gflagfile
    -rpc_encryption=disabled
    -rpc_authentication=disabled
    -trusted_subnets=0.0.0.0/0
    
    # 重启master server
    [root@spark001 conf]# /etc/init.d/kudu-master restart
    Stopped Kudu Master Server:                                [  OK  ]
    Started Kudu Master Server (kudu-master):                  [  OK  ]
    [root@spark001 conf]# 
    
    
  • 相关阅读:
    如何实现CSS限制字数,超出部份显示省略号
    html禁止手机页面放大缩小
    jQuery 获取屏幕高度、宽度
    谷歌api 二维码生成 实例
    java.security.NoSuchAlgorithmException: Cannot find any provider supporting RSA
    eclipse安装阿里开发规范
    tomcat下配置http和https
    linux安装redis
    修改java配置文件
    Linux下安装Mysql
  • 原文地址:https://www.cnblogs.com/liuge36/p/12614716.html
Copyright © 2011-2022 走看看