当我在 oozie 中执行 spark 过程时,出现以下错误。找不到数据库。
2018-09-26 15:27:23,576 INFO [main] org.apache.spark.deploy.yarn.Client:
client token: Token { kind: YARN_CLIENT_TOKEN, service: }
diagnostics: User class threw exception: org.apache.spark.sql.catalyst.analysis.NoSuchDatabaseException: Database 'zdm_datos_externos' not found;
ApplicationMaster host: 10.74.234.6
ApplicationMaster RPC port: 0
queue: default
queue user: administrador
start time: 1537986410475
final status: FAILED
tracking URL: https://BR-PC-CentOS-02:26001/proxy/application_1537467570666_4127/
user: administrador
这是我的火花配置
String warehouseLocation = new File("spark-warehouse").getAbsolutePath();
SparkSession spark = SparkSession
.builder()
.appName("Java Spark Hive Example")
.master("yarn")
.config("spark.sql.warehouse.dir", warehouseLocation)
.config("spark.driver.maxResultSize", "3g")
.config("spark.debug.maxToStringFields", "10000")
.config("spark.sql.crossJoin.enabled", "true")
.enableHiveSupport()
.getOrCreate();
spark.conf().set("spark.driver.maxResultSize", "3g");
Metastore,当前连接数:1 2018-09-26 17:31:42,598 WARN [main] hive.metastore: set_ugi() 不成功,可能的原因:新客户端与旧服务器通信。继续没有它。org.apache.thrift.transport.TTransportException 在 org.apache.thrift.transport.TIOStreamTransport.read(TIOStreamTransport.java:132) 在 org.apache.thrift.transport.TTransport.readAll(TTransport.java:86) 在 org. org.apache.thrift.protocol.TBinaryProtocol.readMessageBegin(TBinaryProtocol.java:230) 的 org.apache.thrift.TServiceClient.receiveBase(TServiceClient.java: 77)在 org.apache.hadoop.hive.metastore.api.ThriftHiveMetastore$Client.recv_set_ugi(ThriftHiveMetastore.java:3748) 在 org.apache.hadoop.hive。