step1:flink连接hive配置
- 首先确保启动hive metastore远程服务
- flink安装目录下新建文件夹hive-conf,然后vi hive-site.xml,配置hive仓库地址和metastore远程服务连接地址。(此配置为了在flink集群中启动hive客户端来远程访问hive metastore服务)具体如下:
- 新建hive-conf文件夹:
- hive-site.xml配置
<configuration>
<property>
<name>hive.metastore.uris</name>
<value>thrift://ip:9083</value>
</property>
<property>
<name>hive.metastore.warehouse.dir</name>
<value>/user/hive/warehouse</value>
</property>