Created 03-08-2022 10:59 PM
We try to run oozie shell action on kerberos environment (Cloudera Enterprise 5.16.2) with command spark2-submit. In script we use HiveContext(sc) to show databases and the result shown that it shows only default database.
Result
Here is my script:
job.properties
val sc = new SparkContext(new SparkConf().setAppName("spark-test"))
var conf: SparkConf = new SparkConf()
val spark = SparkSession.builder.config(conf).enableHiveSupport().getOrCreate()
spark.sql("show databases").show()
val sqlContext = new HiveContext(sc)
sqlContext.sql("show databases").show()
Created 03-10-2022 08:59 AM
Hello @moth
Can you please verify if a hive gateway role (CM > Hive Service > Instances > Add role instance > Gateway) and Spark2 gateway role (CM > Spark2 Service > Instances > Add role instance > Gateway) are installed on every Nodemanager host? Oozie shell actions run as yarn jobs, so the spark2-submit may be run on any NM host in the cluster, so the corresponding gateways need to be installed as well
Created 03-21-2022 07:01 AM
I have the same problem, any solution?