[
https://issues.apache.org/jira/browse/FLINK-6286?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15967622#comment-15967622
]
ASF GitHub Bot commented on FLINK-6286:
---------------------------------------
Github user greghogan commented on a diff in the pull request:
https://github.com/apache/flink/pull/3711#discussion_r111397645
--- Diff: flink-dist/src/main/flink-bin/bin/config.sh ---
@@ -310,8 +310,16 @@ fi
INTERNAL_HADOOP_CLASSPATHS="${HADOOP_CLASSPATH}:${HADOOP_CONF_DIR}:${YARN_CONF_DIR}"
if [ -n "${HBASE_CONF_DIR}" ]; then
- # Setup the HBase classpath.
- INTERNAL_HADOOP_CLASSPATHS="${INTERNAL_HADOOP_CLASSPATHS}:`hbase
classpath`"
+ # Search hbase command in PATH.
+ HBASE_IN_PATH=$(PATH="${HBASE_HOME}/bin:$PATH" \
+ which hbase 2>/dev/null)
+ # Whether the hbase command is found.
+ if [ -f "${HBASE_IN_PATH}" ]; then
+ # The hbase command is found, then setup the HBase classpath.
+
INTERNAL_HADOOP_CLASSPATHS="${INTERNAL_HADOOP_CLASSPATHS}:`${HBASE_IN_PATH}
classpath`"
+ else
+ echo "The HBASE_IN_PATH is setted but can't setup HBase classpath.
Please verify hbase command exists."
--- End diff --
Perhaps more like "HBASE_CONF_DIR=\"${HBASE_CONF_DIR}\" is set but 'hbase'
command was not found in \"${HBASE_PATH}\" so classpath could not be updated."?
I assumed HBASE_PATH="${HBASE_HOME}/bin:$PATH" as a local variable.
> hbase command not found error
> -----------------------------
>
> Key: FLINK-6286
> URL: https://issues.apache.org/jira/browse/FLINK-6286
> Project: Flink
> Issue Type: Bug
> Components: Batch Connectors and Input/Output Formats, Startup Shell
> Scripts
> Reporter: Jinjiang Ling
> Priority: Minor
> Attachments: FLINK-6286-0.patch, FLINK-6286-1.patch,
> FLINK-6286-2.patch
>
>
> As I'm using flink with the HBASE_CONF_DIR env variable and don't install
> hbase, then I get the error message below.
> {quote}
> *bin/config.sh: line 303: hbase: command not found*
> {quote}
--
This message was sent by Atlassian JIRA
(v6.3.15#6346)