Support Questions
Find answers, ask questions, and share your expertise
Announcements
Alert: Welcome to the Unified Cloudera Community. Former HCC members be sure to read and learn how to activate your account here.

jupyter error kerneros

Highlighted

jupyter error kerneros

Super Collaborator

Hi:

When i am trying execute from jupyter to kerberos cluster, i have this error:

16/12/27 19:35:47 WARN security.UserGroupInformation: PriviledgedActionException as:xxxxxxxx (auth:KERBEROS) cause:javax.security.sasl.SaslException: Failure to initialize security context [Caused by org.ietf.jgss.GSSException, major code: 13, minor code: 0
        major string: Invalid credentials
        minor string: Cannot get credential from JAAS Subject for principal: default principal ]
16/12/27 19:35:47 WARN ipc.Client: Exception encountered while connecting to the server : javax.security.sasl.SaslException: Failure to initialize security context [Caused by org.ietf.jgss.GSSException, major code: 13, minor code: 0
        major string: Invalid credentials
        minor string: Cannot get credential from JAAS Subject for principal: default principal ]
16/12/27 19:35:47 WARN security.UserGroupInformation: PriviledgedActionException as:xxxxxxx (auth:KERBEROS) cause:java.io.IOException: javax.security.sasl.SaslException: Failure to initialize security context [Caused by org.ietf.jgss.GSSException, major code: 13, minor code: 0
        major string: Invalid credentials
        minor string: Cannot get credential from JAAS Subject for principal: default principal ]
16/12/27 19:35:47 INFO retry.RetryInvocationHandler: Exception while invoking getClusterMetrics of class ApplicationClientProtocolPBClientImpl over rm112 after 1 fail over attempts. Trying to fail over immediately.
java.io.IOException: Failed on local exception: java.io.IOException: javax.security.sasl.SaslException: Failure to initialize security context [Caused by org.ietf.jgss.GSSException, major code: 13, minor code: 0
        major string: Invalid credentials
        minor string: Cannot get credential from JAAS Subject for principal: default principal ]; Host Details : local host is: "XXXXXXXXX"; destination host is: "XXXXXXXXXX":8032;
        at org.apache.hadoop.net.NetUtils.wrapException(NetUtils.java:772)
        at org.apache.hadoop.ipc.Client.call(Client.java:1475)
        at org.apache.hadoop.ipc.Client.call(Client.java:1408)
        at org.apache.hadoop.ipc.ProtobufRpcEngine$Invoker.invoke(ProtobufRpcEngine.java:230)
        at com.sun.proxy.$Proxy11.getClusterMetrics(Unknown Source)
        at org.apache.hadoop.yarn.api.impl.pb.client.ApplicationClientProtocolPBClientImpl.getClusterMetrics(ApplicationClientProtocolPBClientImpl.java:202)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:95)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:55)
        at java.lang.reflect.Method.invoke(Method.java:508)
        at org.apache.hadoop.io.retry.RetryInvocationHandler.invokeMethod(RetryInvocationHandler.java:256)
        at org.apache.hadoop.io.retry.RetryInvocationHandler.invoke(RetryInvocationHandler.java:104)
        at com.sun.proxy.$Proxy12.getClusterMetrics(Unknown Source)
        at org.apache.hadoop.yarn.client.api.impl.YarnClientImpl.getYarnClusterMetrics(YarnClientImpl.java:483)
        at org.apache.spark.deploy.yarn.Client$$anonfun$submitApplication$1.apply(Client.scala:130)
        at org.apache.spark.deploy.yarn.Client$$anonfun$submitApplication$1.apply(Client.scala:130)
        at org.apache.spark.Logging$class.logInfo(Logging.scala:58)
        at org.apache.spark.deploy.yarn.Client.logInfo(Client.scala:63)
        at org.apache.spark.deploy.yarn.Client.submitApplication(Client.scala:129)
        at org.apache.spark.scheduler.cluster.YarnClientSchedulerBackend.start(YarnClientSchedulerBackend.scala:57)

The code is:

from pyspark import SparkContext
from pyspark import SparkConf

conf = SparkConf()
conf.setMaster('yarn-client')
conf.setAppName('anaconda')
conf.set("spark.yarn.keytab", "XXXXX.keytab")
conf.set("spark.yarn.principal", "XXXXXXXXX")

sc = SparkContext(conf=conf)
1 REPLY 1

Re: jupyter error kerneros

Super Guru
Don't have an account?
Coming from Hortonworks? Activate your account here