3) make sure root user have access to the db from ranger host and ranger kms host.
eg: your ranger host is ranger.host.com & ranger kms host is ranger.kms.host.com
then you should run following command on the mysql database:
GRANT ALL ON *.* TO 'root'@'ranger.host.com' IDENTIFIED BY '<root_password>' WITH GRANT OPTION; GRANT ALL ON *.* TO 'root'@'ranger.kms.host.com' IDENTIFIED BY '<root_password>' WITH GRANT OPTION; flush privileges;
1) go to the ambari and go to the add service wizard
2) select the ranger and ranger kms host
3) make sure you fill following properties carefully in Ranger & Ranger KMS both:
DB_FLAVOR = mysql
Ranger DB host = <db_host> eg: test.mysql.com
Setup Database and Database User = yes
Database Administrator (DBA) username = root
Database Administrator (DBA) password = <root_password>
4) any name can be configured to following db or user properties as they will be created by root user as fresh database or user since we selected "Setup Database and Database User" to yes
Ranger DB name = ranger
Ranger DB username = rangeradmin
Ranger DB password = rangeradmin
5) Ranger KMS has an additional property:
KMS master key password: <kms_password> , this is also newly configured password of your choice.
6)) audit can configured based on your choice if you want audit for service operations,
Note: I have not given details of all the properties in this article because these are the important properties where people make mistakes.