How can I specify Hadoop XML configuration variables via the Hadoop shell scripts? How can I specify Hadoop XML configuration variables via the Hadoop shell scripts? hadoop hadoop

How can I specify Hadoop XML configuration variables via the Hadoop shell scripts?


We had a similar requirement earlier. Configuring dfs.data.dir and dfs.name.dir as part of HADOOP_OPTS worked well for us. For e.g.

export HADOOP_OPTS="-Ddfs.name.dir=$NAMENODE_DATA -Ddfs.data.dir=$DFS_DATA"

This method can be used to configure other configurations also, like namenode url.