How to connect to remote hive server from spark [duplicate]

JDBC is not required Spark connects directly to the Hive metastore, not through HiveServer2. To configure this, Put hive-site.xml on your classpath, and specify hive.metastore.uris to where your hive metastore hosted. Also see How to connect to a Hive metastore programmatically in SparkSQL? Import org.apache.spark.sql.hive.HiveContext, as it can perform SQL query over Hive tables. Define … Read more