hive 批量导入数据、insert报错:Concurrency mode is disabled, not creating a lock managerError: Error while processing stat

问题描述

hive中通过查询方式进行数据导入时,或者批量插入多条数据时,会因为 内存不足 报错:

解决办法

增大内存

步骤一

切换下面目录:

cd /program/hive-3.1.2/conf

复制 hive-env.sh.template 文件:

cp hive-env.sh.template hive-env.sh

步骤二

修改 hive-env.sh 文件:

vim hive-env.sh

然后将里面的 exprot HADOOP_HEAPSIZE=1024 的注释放开(倒数10多行,如果找不到,就在末尾加上这句)

步骤三

重启 hive 或者 hiveserver2


原文出处:/show_1IX2y76Urof9.html