Details
-
Bug
-
Status: Open
-
Major
-
Resolution: Unresolved
-
2.3.0
-
None
-
None
Description
After I set hadoop.security.token.service.use_ip=false in core-site.xml, I found java.lang.NoClassDefFoundError: org/xbill/DNS/ResolverConfig in usersync log.
I found that it is caused by missing dnsjava library in ranger usersync jar as dependency.
Ranger usersync should have dnsjava library.
28 Jan 2023 00:50:18 DEBUG o.a.h.s.SecurityUtil [UnixUserSyncThread] - Setting hadoop.security.token.service.use_ip to false
28 Jan 2023 00:50:18 ERROR o.a.r.u.UserGroupSync [UnixUserSyncThread] - Failed to initialize UserGroup source/sink. Will retry after 60000 milliseconds. Error details:
java.lang.NoClassDefFoundError: org/xbill/DNS/ResolverConfig
at org.apache.hadoop.security.SecurityUtil$QualifiedHostResolver.<init>(SecurityUtil.java:592)
at org.apache.hadoop.security.SecurityUtil.setTokenServiceUseIp(SecurityUtil.java:129)
at org.apache.hadoop.security.SecurityUtil.setConfigurationInternal(SecurityUtil.java:102)
at org.apache.hadoop.security.SecurityUtil.<clinit>(SecurityUtil.java:88)
at org.apache.hadoop.security.UserGroupInformation.initialize(UserGroupInformation.java:312)
at org.apache.hadoop.security.UserGroupInformation.ensureInitialized(UserGroupInformation.java:300)
at org.apache.hadoop.security.UserGroupInformation.getCurrentUser(UserGroupInformation.java:567)
at org.apache.hadoop.fs.FileSystem$Cache$Key.<init>(FileSystem.java:3614)
at org.apache.hadoop.fs.FileSystem$Cache$Key.<init>(FileSystem.java:3604)
at org.apache.hadoop.fs.FileSystem$Cache.get(FileSystem.java:3441)
at org.apache.hadoop.fs.FileSystem.get(FileSystem.java:524)
at org.apache.hadoop.fs.Path.getFileSystem(Path.java:365)
at org.apache.hadoop.security.alias.JavaKeyStoreProvider.initFileSystem(JavaKeyStoreProvider.java:89)
at org.apache.hadoop.security.alias.AbstractJavaKeyStoreProvider.<init>(AbstractJavaKeyStoreProvider.java:85)
at org.apache.hadoop.security.alias.JavaKeyStoreProvider.<init>(JavaKeyStoreProvider.java:49)
at org.apache.hadoop.security.alias.JavaKeyStoreProvider.<init>(JavaKeyStoreProvider.java:41)
at org.apache.hadoop.security.alias.JavaKeyStoreProvider$Factory.createProvider(JavaKeyStoreProvider.java:100)
at org.apache.hadoop.security.alias.CredentialProviderFactory.getProviders(CredentialProviderFactory.java:73)
at org.apache.ranger.credentialapi.CredentialReader.getDecryptedString(CredentialReader.java:74)
at org.apache.ranger.unixusersync.config.UserGroupSyncConfig.getSSLKeyStorePathPassword(UserGroupSyncConfig.java:439)
at org.apache.ranger.unixusersync.process.PolicyMgrUserGroupBuilder.init(PolicyMgrUserGroupBuilder.java:216)
at org.apache.ranger.usergroupsync.UserGroupSync.run(UserGroupSync.java:49)