Skip to content

Add HADOOP_CLIENT_LIB_DIR to accumulo-env.sh - #6531

Open
lbschanno wants to merge 1 commit into
apache:mainfrom
lbschanno:hadoop-client-lib-dir
Open

Add HADOOP_CLIENT_LIB_DIR to accumulo-env.sh#6531
lbschanno wants to merge 1 commit into
apache:mainfrom
lbschanno:hadoop-client-lib-dir

Conversation

@lbschanno

Copy link
Copy Markdown
Contributor

The accumulo-env.sh attempts to add Hadoop libraries to the classpath from the path $HADOOP_HOME/share/hadoop/client. There are times when Hadoop libraries are not installed in the tarball-style path, such as when Hadoop is installed via RPMs.

Add the environment variable HADOOP_CLIENT_LIB_DIR to accumulo-env with a default value of $HADOOP_HOME/share/hadoop/client. Update the construction of the CLASSPATH to add hadoop libraries using the HADOOP_CLIENT_LIB_DIR variable.

Closes #6530

The accumulo-env.sh attempts to add Hadoop libraries to the classpath
from the path $HADOOP_HOME/share/hadoop/client. There are times when
Hadoop libraries are not installed in the tarball-style path, such as
when Hadoop is installed via RPMs.

Add the environment variable HADOOP_CLIENT_LIB_DIR to accumulo-env with
a default value of $HADOOP_HOME/share/hadoop/client. Update the
construction of the CLASSPATH to add hadoop libraries using the
HADOOP_CLIENT_LIB_DIR variable.

Closes apache#6530
# lib is set by calling script that sources this env file
#shellcheck disable=SC2154
CLASSPATH="${CLASSPATH}:${lib}/*:${HADOOP_CONF_DIR}:${ZOOKEEPER_HOME}/*:${ZK_JARS}:${HADOOP_HOME}/share/hadoop/client/*"
CLASSPATH="${CLASSPATH}:${lib}/*:${HADOOP_CONF_DIR}:${ZOOKEEPER_HOME}/*:${ZK_JARS}:${HADOOP_CLIENT_LIB_DIR}/*"

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looking at lines starting at 58, the intention is to honor the CLASSPATH environment variable set by the user and put that first.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This change does not circumnavigate that intention.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Allow alternative path to be specified for Hadoop client JARs

2 participants