zoukankan      html  css  js  c++  java
  • ambari安装hive检测TEST CONNECTION时报Access denied for user 'hive'@'xxxxx' (using password: YES)错误,一直连接不上

    2021-02-05 22:35:36,606 - Check db_connection_check was unsuccessful. Exit code: 1. Message: Loading class `com.mysql.jdbc.Driver'. This is deprecated. The new driver class is `com.mysql.cj.jdbc.Driver'. The driver is automatically registered via the SPI and manual loading of the driver class is generally unnecessary.
    ERROR: Unable to connect to the DB. Please check DB connection properties.
    java.sql.SQLException: Access denied for user 'hive'@'VM-16-6-centos' (using password: YES)
    
    Traceback (most recent call last):
      File "/var/lib/ambari-agent/cache/custom_actions/scripts/check_host.py", line 546, in <module>
        CheckHost().execute()
      File "/usr/lib/ambari-agent/lib/resource_management/libraries/script/script.py", line 352, in execute
        method(env)
      File "/var/lib/ambari-agent/cache/custom_actions/scripts/check_host.py", line 207, in actionexecute
        raise Fail(error_message)
    resource_management.core.exceptions.Fail: Check db_connection_check was unsuccessful. Exit code: 1. Message: Loading class `com.mysql.jdbc.Driver'. This is deprecated. The new driver class is `com.mysql.cj.jdbc.Driver'. The driver is automatically registered via the SPI and manual loading of the driver class is generally unnecessary.
    ERROR: Unable to connect to the DB. Please check DB connection properties.
    java.sql.SQLException: Access denied for user 'hive'@'VM-16-6-centos' (using password: YES)
    
    • 解决方法:
      Access denied for user 'hive'@'VM-16-6-centos' (using password: YES)来看,是mysql没有获取授权导致,通过以下操作即可解决:
    GRANT ALL PRIVILEGES ON *.* TO 'ambari'@'VM-16-6-centos' IDENTIFIED BY '密码' WITH GRANT OPTION;
    GRANT ALL PRIVILEGES ON *.* TO 'hive'@'VM-16-6-centos' IDENTIFIED BY '密码' WITH GRANT OPTION;
    GRANT ALL PRIVILEGES ON *.* TO 'oozie'@'VM-16-6-centos' IDENTIFIED BY '密码' WITH GRANT OPTION;
    
    -----------------------------------------------------------
    shotting source code
  • 相关阅读:
    使用Supervisor守护Python进程
    Python 程序员经常犯的 10 个错误
    DNS的view加速
    转-Gitorious搭建步骤
    linux下curl的地址使用双引号引用的原因
    java poi ppt操作示例
    CentOS 6.3下Samba服务器的安装与配置
    Linux NFS服务器的安装与配置
    Linux下安装JDK和tomcat
    Oracle数据库合并行记录,WMSYS.WM_CONCAT 函數的用法
  • 原文地址:https://www.cnblogs.com/zh672903/p/14380110.html
Copyright © 2011-2022 走看看