Our Community is getting an upgrade! To get everything ready for the relaunch, we’ll be placing the site in read-only mode starting September 21st.
We really appreciate your understanding while we get things set up behind the scenes. Catch up on all the exciting details about the move here.
Need help or have questions? Drop us a line at [email protected]
Created 02-04-2016 07:38 AM
Hello
HDP 2.3.2
Ambari 2.1.2.1
After changing the admin password of Ranger - both in the ranger UI and in the ambari under Advanced ranger-env the HiveServer2 fails to start. Ranger starts flawlessly - but HiveServer2 (which has Ranger authorization enabled) doesn't. If i disable the Ranger authorization from Hive (switching to none) HiveServer2 will start.
The error in the ambari is:
Traceback (most recent call last):
File "/var/lib/ambari-agent/cache/common-services/HIVE/0.12.0.2.0/package/scripts/hive_server.py", line 193, in <module>
HiveServer().execute()
File "/usr/lib/python2.6/site-packages/resource_management/libraries/script/script.py", line 216, in execute
method(env)
File "/var/lib/ambari-agent/cache/common-services/HIVE/0.12.0.2.0/package/scripts/hive_server.py", line 85, in start
setup_ranger_hive(rolling_upgrade=rolling_restart)
File "/var/lib/ambari-agent/cache/common-services/HIVE/0.12.0.2.0/package/scripts/setup_ranger_hive.py", line 50, in setup_ranger_hive
hdp_version_override = hdp_version)
File "/usr/lib/python2.6/site-packages/resource_management/libraries/functions/setup_ranger_plugin_xml.py", line 78, in setup_ranger_plugin
policy_user)
File "/usr/lib/python2.6/site-packages/resource_management/libraries/functions/ranger_functions.py", line 92, in create_ranger_repository
repo = self.get_repository_by_name_urllib2(repo_name, component, 'true', ambari_username_password_for_ranger)
File "/usr/lib/python2.6/site-packages/resource_management/libraries/functions/ranger_functions.py", line 57, in get_repository_by_name_urllib2
response = json.loads(result.read())
File "/usr/lib/python2.6/site-packages/ambari_simplejson/__init__.py", line 307, in loads
return _default_decoder.decode(s)
File "/usr/lib/python2.6/site-packages/ambari_simplejson/decoder.py", line 335, in decode
obj, end = self.raw_decode(s, idx=_w(s, 0).end())
File "/usr/lib/python2.6/site-packages/ambari_simplejson/decoder.py", line 353, in raw_decode
raise ValueError("No JSON object could be decoded")I've noticed there's a registered bug around this issue but it is unassigned and unresolved -https://issues.apache.org/jira/browse/AMBARI-13168
Any ideas how to workaround this issue ??
Created 02-08-2016 04:39 PM
There are two users involved - admin (advanced ranger-env) and amb_ranger_admin (admin settings).
Can you verify both users password are correct in ranger and ambari UI?
Created 02-09-2016 11:33 AM
@Adi Jabkowsky I see that you accepted the answer. Were you able to resolve the issue? Looking forward to see the final fix 🙂
Created on 02-07-2016 03:41 PM - edited 08-19-2019 03:07 AM
I changed admin user password for ranger in Ranger UI
Logged into the ambari and updated only following entry with new password
restarted Namenode ...No issues
Created on 02-07-2016 04:02 PM - edited 08-19-2019 03:07 AM
I was referring to HiveServer2 - not Namenode. In my scenario the Ranger is managing Hive authorization. So unless Hive isn't set to use Ranger - you won't have this issue.
Created 02-07-2016 04:07 PM
@Adi Jabkowsky Did you update password in one location or 2 locations as described in official docs?
I changed the password entry only for admin setting as shared in my screenshot.
Restarted Hive process using ambari and no issues with Ranger auth
Created 02-07-2016 04:08 PM
I updated the 2 locations as described in official docs. Not just one.
Created 02-07-2016 04:10 PM
@Adi Jabkowsky That's the issue.
1st one is for Ranger UI admin password
2nd one is for Ambari admin user entry 😉 Rollback the 2nd password change (Put ambari admin password there)
Created 02-07-2016 04:40 PM
Please check if Hive is set for Ranger (Under Security just like in my screenshot). It might be set to NONE or SQLstdAuth
Created on 02-07-2016 04:43 PM - edited 08-19-2019 03:07 AM
@Adi Jabkowsky No, its Ranger
Created 02-07-2016 04:47 PM
Created 02-07-2016 04:59 PM
Tried every combination including reverting back to the default admin password in Ranger - still no luck. HiveServer2 won't start as long as it it's Auth are configured using Ranger. "No JSON object could be decoded"
😞
Thx a million for trying !