kylin启动:Failed to create /kylin

版权声明:本文为博主九师兄(QQ群:spark源代码 198279782 欢迎来探讨技术)原创文章,未经博主允许不得转载。 https://blog.csdn.net/qq_21383435/article/details/90019927

一:当在ubuntu下执行check_env.sh时遇到问题:

KYLIN_HOME is set to /usr/local/apache-kylin-1.5.4.1-bin cat: invalid option -- '1' Try 'cat --help' for more information. -mkdir: Not enough arguments: expected 1 but got 0 Usage: hadoop fs [generic options] -mkdir [-p] ... failed to create , Please make sure the user has right to access

可能是由于get-properties.sh里的某条命令与ubuntu不相符,将get-propertie中的内容替换如下得以解决

if [ $# != 1 ]
then
    echo 'invalid input'
    exit -1
fi


result=`cat ${KYLIN_HOME}/conf/kylin.properties | grep -w "^$1" | grep -v '^#' | awk -F= '{ n = index($0,"="); print substr($0,n+1)}' | cut -c 1- |tail -1`
echo $result

二:当执行./check_env.sh 时遇到

mkdir: Permission denied: user=root, access=WRITE, inode="/":hdfs:supergroup:drwxr-xr-x
failed to create /kylin, Please make sure the user has right to access /kylin

可以在check-env.sh中 将hadoop fs -mkdir -p $WORKING_DIR 变成 sudo -u hdfs hadoop fs -mkdir -p $WORKING_DIR,得以解决

猜你喜欢

转载自blog.csdn.net/qq_21383435/article/details/90019927