4

When I start spark I get this warnings:

Using Scala version 2.10.5 (OpenJDK 64-Bit Server VM, Java 1.8.0_77)
Type in expressions to have them evaluated.
Type :help for more information.
Spark context available as sc.
16/04/03 15:07:31 WARN Connection: BoneCP specified but not present in CLASSPATH (or one of dependencies)
16/04/03 15:07:31 WARN Connection: BoneCP specified but not present in CLASSPATH (or one of dependencies)
16/04/03 15:07:39 WARN ObjectStore: Version information not found in metastore. hive.metastore.schema.verification is not enabled so recording the schema version 1.2.0
16/04/03 15:07:39 WARN ObjectStore: Failed to get database default, returning NoSuchObjectException
SQL context available as sqlContext.

scala> 

And also when I execute this command: var sqlContext = new org.apache.spark.sql.hive.HiveContext(sc)

I get again this warning:

scala> var sqlContext = new org.apache.spark.sql.hive.HiveContext(sc)
16/04/03 15:04:31 WARN Connection: BoneCP specified but not present in CLASSPATH (or one of dependencies)
16/04/03 15:04:31 WARN Connection: BoneCP specified but not present in CLASSPATH (or one of dependencies)
16/04/03 15:04:35 WARN ObjectStore: Failed to get database default, returning NoSuchObjectException
sqlContext: org.apache.spark.sql.hive.HiveContext = org.apache.spark.sql.hive.HiveContext@13453610

So my question is if you know why this warning is happening and if, although the warning is happening, the command var sqlContext = new org.apache.spark.sql.hive.HiveContext(sc) its working correctly?

codin
  • 743
  • 5
  • 15
  • 27

3 Answers3

1

BoneCP is a Java JDBC connection pool and it's tries to bind to a JDBC connection and this is why you receive these warnings. You may suppress this kind of warnings by configure the logger level.

Eugene
  • 1,865
  • 3
  • 21
  • 24
  • 1
    Thanks for your answer. And the other warning about failed to get database default? Do you know if although the warning is appearing the command works correctly? – codin Apr 03 '16 at 15:23
  • 1
    Why is it returning a NoSuchObjectException! and Failure? – Chaitanya Bapat Mar 12 '17 at 14:18
1

I meet this warning,too as :

"Failed to get database default, returning NoSuchObjectException"

but i can connect to hive correctly,so check your hive-site.xml and i am not sure if this warning will affect the sentry.

LuFFy
  • 8,799
  • 10
  • 41
  • 59
hu li
  • 11
  • 2
0

Check if you have assigned SQLContext:

sqlContext = pyspark.SQLContext(sc)  
סטנלי גרונן
  • 2,917
  • 23
  • 46
  • 68