Exception in thread “main” java.lang.UnsupportedClassVersionError:scala/tools/nsc/MainGenericRunner

Issue:

[hadoop@node1 ~]$ scala -version

Exception in thread “main” java.lang.UnsupportedClassVersionError: scala/tools/nsc/MainGenericRunner : Unsupported major.minor version 52.0

at java.lang.ClassLoader.findBootstrapClass(Native Method)

at java.lang.ClassLoader.findBootstrapClassOrNull(ClassLoader.java:1070)

 

Cause: 

Unsupported Version of Scala and Java

 

Resolution:

For Scala version scala-2.12.1, use Java 1.8 +. For Scala version 2.10.6, use java version 1.6+ (1.7 also works)

Advertisements
This entry was posted in Scala, Spark. Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s