进行Spark,Kafka针对Kerberos相关配置

1. 提交任务的命令

spark-submit \
--class <classname> \
--master yarn \
--deploy-mode client \
--executor-memory 2g \
--executor-cores 2 \
--driver-memory 2g \
--num-executors 2 \
--queue default \
--principal ocsp-yg@ASIAINFO.COM \
--keytab /etc/security/keytabs/hdfs.headless.keytab \
--files "/usr/OCSP/conf/kafka_client_jaas.conf,/usr/OCSP/conf/ocsp.keytab" \
--driver-java-options "-Djava.security.auth.login.config=http://www.likecs.com/usr/OCSP/conf/kafka_client_jaas.conf" \
--conf "spark.executor.extraJavaOptions=-Djava.security.auth.login.config=./kafka_client_jaas.conf" \
--jars <your jars>,/usr/OCSP/lib/spark-kafka-0-10-connector-assembly_2.10-1.0.1.jar /usr/OCSP/lib/ocsp-core_1.6-2.1.0.jar

内容版权声明:除非注明,否则皆为本站原创文章。

转载注明出处:https://www.heiqu.com/zwwssx.html