-
问题
WARNING: An illegal reflective access operation has occurred
WARNING: Illegal reflective access by org.apache.hadoop.security.authentication.util.KerberosUtil (file:/usr/local/hbase/lib/hadoop-auth-2.5.1.jar) to method sun.security.krb5.Config.getInstance()
WARNING: Please consider reporting this to the maintainers of org.apache.hadoop.security.authentication.util.KerberosUtil
WARNING: Use --illegal-access=warn to enable warnings of further illegal reflective access operations
WARNING: All illegal access operations will be denied in a future release -
问题描述
今天在用eclipse写Hbse Java程序的时候,遇到这样一个问题,虽然是WARNING, 但是在后面写数据库的时候就抛出一系列的问题,例如下面这个:
java.io.IOException: java.lang.reflect.InvocationTargetException
at org.apache.hadoop.hbase.client.ConnectionFactory.createConnection(ConnectionFactory.java:240)
at org.apache.hadoop.hbase.client.ConnectionFactory.createConnection(ConnectionFactory.java:218)
at org.apache.hadoop.hbase.client.ConnectionFactory.createConnection(ConnectionFactory.java:119)
at ExampleForHbase.init(ExampleForHbase.java:55)
at ExampleForHbase.createTable(ExampleForHbase.java:83)
at ExampleForHbase.main(ExampleForHbase.java:14)
,导致无法对hbase进行操作!!! -
解决办法
在查找网上的信息后,找到解决办法:更换低版本的jdk,一开始我用的jdk_12.0.1,然后我改为jdk_1.8.0_211
然后问题就解决啦。
大数据原理与技术学习——问题(2)
最新推荐文章于 2023-07-06 10:36:31 发布