We use proprietary and third party´s cookies to improve your experience and our services, identifying your Internet Browsing preferences on our website; develop analytic activities and display advertising based on your preferences. If you keep browsing, you accept its use. You can get more information on our Cookie Policy
Cookies Policy

First time here? Check out the FAQ!

Ask Your Question
0

Error Hive

asked Mar 21 '16

migmobl gravatar image

I'm following the basic steps in Cosmos and when I write this command:

hive

hive - select * from <my_user>starwars; // or any other SQL-like sentence, properly called HiveQL

the terminal shows this message: log4j:ERROR Could not instantiate class [org.apache.hadoop.hive.shims.HiveEventCounter]. java.lang.RuntimeException: Could not load shims in class org.apache.hadoop.log.metrics.EventCounter at org.apache.hadoop.hive.shims.ShimLoader.createShim(ShimLoader.java:123) at org.apache.hadoop.hive.shims.ShimLoader.loadShims(ShimLoader.java:115) at org.apache.hadoop.hive.shims.ShimLoader.getEventCounter(ShimLoader.java:98) at org.apache.hadoop.hive.shims.HiveEventCounter.<init>(HiveEventCounter.java:34) at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27) at java.lang.reflect.Constructor.newInstance(Constructor.java:513) at java.lang.Class.newInstance0(Class.java:357) at java.lang.Class.newInstance(Class.java:310) at org.apache.log4j.helpers.OptionConverter.instantiateByClassName(OptionConverter.java:330) at org.apache.log4j.helpers.OptionConverter.instantiateByKey(OptionConverter.java:121) at org.apache.log4j.PropertyConfigurator.parseAppender(PropertyConfigurator.java:664) at org.apache.log4j.PropertyConfigurator.parseCategory(PropertyConfigurator.java:647) at org.apache.log4j.PropertyConfigurator.configureRootCategory(PropertyConfigurator.java:544) at org.apache.log4j.PropertyConfigurator.doConfigure(PropertyConfigurator.java:440) at org.apache.log4j.PropertyConfigurator.doConfigure(PropertyConfigurator.java:476) at org.apache.log4j.PropertyConfigurator.configure(PropertyConfigurator.java:354) at org.apache.hadoop.hive.common.LogUtils.initHiveLog4jDefault(LogUtils.java:127) at org.apache.hadoop.hive.common.LogUtils.initHiveLog4jCommon(LogUtils.java:77) at org.apache.hadoop.hive.common.LogUtils.initHiveLog4j(LogUtils.java:58) at org.apache.hadoop.hive.cli.CliDriver.run(CliDriver.java:641) at org.apache.hadoop.hive.cli.CliDriver.main(CliDriver.java:625)

edit

Comments

Are you using the Hive CLI inside the cluster?

frb gravatar imagefrb (Mar 29 '16)

I am using the Hive CLI in the Cosmos Machine: ssh user@cosmos.lab.fi-ware.org

migmobl gravatar imagemigmobl (Mar 29 '16)

1 answer

Sort by » oldest newest most voted
1

answered Apr 4 '16

frb gravatar image

Despite the error above, the Hive CLI should prompt you for a query with "hive>". Please, have a look a the end of my execution:

$ hive
log4j:ERROR Could not instantiate class [org.apache.hadoop.hive.shims.HiveEventCounter].
java.lang.RuntimeException: Could not load shims in class org.apache.hadoop.log.metrics.EventCounter
...
log4j:ERROR Could not instantiate appender named "EventCounter".

Logging initialized using configuration in jar:file:/usr/local/apache-hive-0.13.0-bin/lib/hive-common-0.13.0.jar!/hive-log4j.properties
hive>

Such an error is because a version missmatching when starting a Hive component, but nothing important.

edit link
Login/Signup to Answer

Question Tools

1 follower

Stats

Asked: Mar 21 '16

Seen: 9,423 times

Last updated: Apr 04 '16