Support Questions

Find answers, ask questions, and share your expertise
Announcements
Celebrating as our community reaches 100,000 members! Thank you!

User:amb_ranger_admin credentials on Ambari UI are not in sync with Ranger

avatar
Contributor

I am getting : User:amb_ranger_admin credentials on Ambari UI are not in sync with Ranger

followed the link : https://community.hortonworks.com/questions/19948/this-alert-is-used-to-ensure-that-the-ranger-admin... , still no luck.

Ranger version : 0.6.0.2.5

HDP : 2.5.3.0

could able to login to Ranger Admin UI , using both amb_ranger_admin and admin , with their respective passwords.

From Ambari, i tired to change admin password to match with amb_ranger_admin's password . But could not modify. Also tired to modify amb_ranger_admin to match with admin's password. It also could not modify.

I bounced both Ranger and Ambari also. Still no lock.

Do we need to modify these password , from mysql?

or

After login to Ranger Admin UI , as both amb_ranger_admin and admin , users , can we update their password to same value?

Any Help is appreciated.

Thanks

Naveen.

1 ACCEPTED SOLUTION

avatar
Rising Star

@naveen sangam: Values for 'Ranger Admin username for Ambari' and 'Ranger Admin user's password for Ambari' should be set when installing Ranger through Ambari as the user set here is used by Ambari to create Ranger repo/policies.

The user you set under 'admin_username' and 'admin_password' is used for logging into Ranger UI as an admin user. This user gets created in Ranger Ui with same password as is set in Ambari UI.

Were you ever able to login to Ranger UI using the username and password you set in 'admin_username' and 'admin_password'? What did you do after that?

After installing Ranger, Ideally the only time you want to update these passwords in Ambari are if you changed the passwords of these users in Ranger first, not the other way round.

Also refer: http://docs.hortonworks.com/HDPDocuments/HDP2/HDP-2.3.4/bk_Ranger_Install_Guide/content/updating_ran...

View solution in original post

7 REPLIES 7

avatar
Rising Star

@naveen sangam Are you seeing any errors when you try to change the password. You need to keep the password for "amb_ranger_admin" on Ambari UI and Ranger Admin in sync.

avatar
Contributor

Santhosh,

I see error : User:amb_ranger_admin credentials on Ambari UI are not in sync with Ranger

though , i sync password ( to same password) , Changes / new passwords are not are not getting saved.

Thanks

Naveen

avatar
Rising Star

@naveen sangam amb_ranger_admin is the admin user used by Ambari to create repo/policies in Ranger. If you are able to login to Ranger UI using amb_ranger_admin, set the same password in Ambari as well under Ranger Configs > Advanced> Ranger Admin user's password for Ambari and restart Ranger via Ambari for the change to take into effect.

avatar
Rising Star

@naveen sangam: Values for 'Ranger Admin username for Ambari' and 'Ranger Admin user's password for Ambari' should be set when installing Ranger through Ambari as the user set here is used by Ambari to create Ranger repo/policies.

The user you set under 'admin_username' and 'admin_password' is used for logging into Ranger UI as an admin user. This user gets created in Ranger Ui with same password as is set in Ambari UI.

Were you ever able to login to Ranger UI using the username and password you set in 'admin_username' and 'admin_password'? What did you do after that?

After installing Ranger, Ideally the only time you want to update these passwords in Ambari are if you changed the passwords of these users in Ranger first, not the other way round.

Also refer: http://docs.hortonworks.com/HDPDocuments/HDP2/HDP-2.3.4/bk_Ranger_Install_Guide/content/updating_ran...

avatar
Expert Contributor

I keep asking myself because so many people feels the necessity to respond something even when then don't know how to response the original question raised by the user with the problem. When someone post a question here it's supposed they have checked the (sometimes very) basic instructions in the manual, and even more if there is a clear description about that, and about the problem persisting after doing the basic steps as in this case.

So, it is a matter of personal pride or winning some points with this forum or even Hortonworks company for the number of useless responses you submit?

Not a single response here address the real problem the user is asking about, and most of them are treating the one asking as a total dummy.

Please filter yourself, read carefully the submitting question and think I you really are contributing something valuable or asking some feedback important for the "real" problem, before responding as a reflex act, to avoid lowering the quality of this forum and making people lose time reading again and again the very same "quotes" from the (many times incomplete) manuals.

avatar
Expert Contributor

Respect to the problem of keeping in sync amb_ranger_admin password between Ranger and Ambari, via the Web UI you can change these values as follows:

  • Ambari Server: into the Ambari Server UI at the Ranger -> Config -> Advanced -> Admin Settings section as stated in the manuals and as you said you had already done.
  • Ranger: into the Ranger Admin UI into Settings -> User/Groups section and searching "User Name: amb_ranger_admin".

However if you have already tested and succeeded logging in to the Ranger Admin with this user and the password you have already setup in Ambari this may no be the problem.

To go to the source and check the real passwords in the Ambari and Ranger configuration you have to go to the info in the corresponding databases.

  1. In Ambari the information is saved into a JSON text entry in the field "ranger_admin_password" from the table "clusterconfig". This table keeps all versions for each configuration type so you will have to search for the last entry on the type "type_name='ranger-env'" and select the field "config_data". A SELECT like following will be useful:
    SELECT version,create_timestamp,type_name,config_data FROM ambari.clusterconfig WHERE type_name LIKE 'ranger-env' ORDER BY version DESC LIMIT 1
  2. In Ranger you have to check the x_portal_user table and search the password field for the user with the login_id=amb_ranger_env with a select like this:
    SELECT login_id, password, status from x_portal_user
    In this case the password field is a hash combining the password and the user name; so you will have to use the following to compare with the previous value:
    echo -n 'yourpassword{amb_ranger_admin}' | md5sum

If the previous passwords are differents and you have done the steps from the beginning in each UI then you have to check why Ambari (most certainly) is not updating your configuration. On the other side if the passwords match, then probably you have another problem with Ambari configuration.

avatar

If you want to be sure whether one of the two components is updating the password, consider checking the md5sum before and after you change it (and make sure to change it to a different value).


- Dennis Jaheruddin

If this answer helped, please mark it as 'solved' and/or if it is valuable for future readers please apply 'kudos'.