Created 05-17-2018 01:32 PM
I am trying to install a non-default database for Ambari and have chosen MySQL as the non-default database on a Centos7 VM environment.
I have followed all the instructions on this link :
I have installed the mysql connector using :
1. yum install mysql-connector-java and also tried using
2. downloading mysql-connector-java-5.1.46.tar.gz , copying the 2 mysql-connector-java-5.1.46.jar file to /usr/share/java as well as /var/lib/ambari-server/resources/ folder.
3. I also provided a symlink as mysql-connector-java.jar file both in the /usr/share/java as well as /var/lib/ambari-server/resources/ folder , I have also tried them seperately.
I have also added the property server.jdbc.driver.path=/usr/share.java/mysql-connector-java.jar to /etc/ambari-server/conf/ambari.properties
I have also created the ambari database, amabri user with all permission and also run the script - Ambari-DDL-MySQL-CREATE.sql
My ambari server version is 2.6.1.5.3 and my MySQL version is 5.6.40 MySQL Community Server (GPL)
I can access my MySQL and MySQL is running fine.
Despite trying all types of permutation and combination, I am getting this error after successfully installing ambari-server and ambari-setup. I have also tried ambari-server setup --jdbc-db=mysql --jdbc-driver=/usr/share/java/mysql-connector-java.jar
But everytime I run the ambari-server start command I end with the following error.
ERROR [main] DBAccessorImpl:119 - Error while creating database accessor java.sql.SQLException: Access denied for user 'ambari'@'xxxx.com' (using password: YES)
Anyhelp would be greatly appreciated !
Created 05-17-2018 01:43 PM
That's a permission issue on the ambari database, can you try running the following
grant all privileges on *.* to 'ambari'@'xxxx.com' identified by 'ambari_user_password'; flush privileges;
Please try that and revert
Created 05-17-2018 01:43 PM
That's a permission issue on the ambari database, can you try running the following
grant all privileges on *.* to 'ambari'@'xxxx.com' identified by 'ambari_user_password'; flush privileges;
Please try that and revert
Created 05-17-2018 01:46 PM
USE ambaridb;
CREATE USER 'ambari'@'localhost' IDENTIFIED BY 'panther';
GRANT ALL PRIVILEGES ON *.* TO 'ambari'@'localhost';
CREATE USER 'ambari'@'%' IDENTIFIED BY 'panther';
GRANT ALL PRIVILEGES ON *.* TO 'ambari'@'%';
FLUSH PRIVILEGES;
Created 05-17-2018 01:46 PM
I had created user ambari with all privileges.
Created 05-17-2018 01:56 PM
You will need explicitly add this privilege because that's the error being thrown out !!
grant all privileges on *.* to 'ambari'@'xxxx.com' identified by 'panther'; flush privileges;
Please do that and revert
Created 05-17-2018 02:28 PM
Thank You ! That seems to have done the trick. Much appreciated