Home | About | Sematext search-lucene.com search-hadoop.com
 Search Hadoop and all its subprojects:

Switch to Threaded View
HDFS >> mail # user >> Rack Awareness


I used this script . In core-site.xml i have set
net.topology.script.file.name to this file's path. Then i executed the
script and passed my computers IP address. It returned /dc1/rack1 . However
, when i ran my MapReduce job it still says the job ran on default-rack .
How can i change that??
Thank you
Preethi Ganeshan
( I have made the changes accordingly to fit my computer )


while [ $# -gt 0 ] ; do
  exec< ${HADOOP_CONF}/topology.data
  while read line ; do
    ar=( $line )
    if [ "${ar[0]}" = "$nodeArg" ] ; then
  if [ -z "$result" ] ; then
    echo -n "/default/rack "
    echo -n "$result "

Topology data

hadoopdata1.ec.com     /dc1/rack1
hadoopdata1            /dc1/rack1               /dc1/rack2