How to successfully make a hive jdbc call inside a

2019-09-09 11:20发布

I am writing a utility that is a map reduce job where the reducer makes calls to various databases and Hive is one of them.

Our cluster is kerberized. I am doing kinit before kicking off the MR job, but when the reducer runs, it fails with an error "No valid credentials provided (Mechanism level: Failed to find any Kerberos tgt)"

This indicates that it doesnt have a valid ticket. I tried to get a delegation token for Hive service in the MR driver, but it failed because the Hive service account is not allowed to impersonate my user.

I don't want to copy the keytab file onto all worker nodes, I want to somehow make either delegation token work or pass the credentials from MR driver to the mappers & reducers.

Can anyone suggest another method to get a valid ticket in the mappers & reducers to make Hive JDBC calls.

Thanks, Arun.

0条回答
登录 后发表回答