[英]unable to run hive from shell action in oozie,can anyone help me one this
here is my workflow and error logs respectively. 这分别是我的工作流程和错误日志。 shell file content: Shell文件内容:
#!/bin/bash
echo
echo
echo "testing"
echo
export HIVE_CONF_DIR=
echo "hive job got started"
cd /opt/mapr/hive/hive-2.1/bin
echo /cygdrive/c/Projects/JLR/embedded_software/main_unit/arm
hive -e "use ozzie_test; create table if not exists test_edh1(name string, id int);"
result=0
if [ -ne 0 ]; then
echo "Hive error number is: "
exit 1
else
echo "hive job got completed successfully"
fi
error message: 错误信息:
getting the errorcode as 127
Hive error number is: 127
./testScript.sh: line 11: cd: /opt/mapr/hive/hive-2.1/bin: No such file or directory
./testScript.sh: line 13: **hive: command not found**
Is this ' /opt/mapr/hive/hive-2.1/bin ' an hdfs path? 这是/opt/mapr/hive/hive-2.1/bin的hdfs路径吗? If yes, you are trying to use 'cd' command on hdfs path whereas shell checks for that path in local directory and hence the error. 如果是,则您尝试在hdfs路径上使用“ cd”命令,而Shell会在本地目录中检查该路径,从而检查错误。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.