legendtkl opened a new issue #1164:
URL: https://github.com/apache/incubator-linkis/issues/1164
**Describe the bug**
When the env 'KERBEROS_ENABLE' is not set, we will encounter the following
Exception when we submit job.
```
2021-12-07 20:14:55.014 ERROR Task is Failed,errorMsg: errCode: 12003 ,desc:
xxx:9101_0 Failed to async get EngineNode RMErrorException: errCode: 11006
,desc: Failed to request external resourceClassCastException: java.lang.String
cannot be cast to java.lang.Boolean ,ip: xxx ,port: 9101 ,serviceKind:
linkis-cg-linkismanager ,ip: xxx ,port: 9104 ,serviceKind: linkis-cg-entrance
```
(IP hided)
**Root Cause**
`install.sh` will override the SQL `linkis_dml.sql` when the env
'KERBEROS_ENABLE' is set. But it will leave it there when the env
is not set.
**How to fix**
modify the `install.sh` as follow, namely, set it to false when the env is
absent.
```
if [ "$KERBEROS_ENABLE" != "" ]
then
sed -i ${txt} "s#@KERBEROS_ENABLE#$KERBEROS_ENABLE#g"
$LINKIS_HOME/db/linkis_dml.sql
sed -i ${txt} "s#@PRINCIPAL_NAME#$PRINCIPAL_NAME#g"
$LINKIS_HOME/db/linkis_dml.sql
sed -i ${txt} "s#@KEYTAB_PATH#$KEYTAB_PATH#g"
$LINKIS_HOME/db/linkis_dml.sql
sed -i ${txt} "s#@KRB5_PATH#$KRB5_PATH#g" $LINKIS_HOME/db/linkis_dml.sql
else
sed -i ${txt} "s#@KERBEROS_ENABLE#false#g" $LINKIS_HOME/db/linkis_dml.sql
fi
```
I will submit a PR to fix this.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]