Set the Rack ID Using a Custom Topology Script
If you do not want to have Ambari manage the rack information for hosts, you can use a custom topology script. To do this, you mustcreate your own topology script and manage distributing the script to all hosts. Note also that because Ambari will have no access to host rack information, heatmaps will not display by rack in Ambari Web.
To manage rack information by custom script:
Steps
Browse to Services > HDFS > Configs.
Modify
net.topology.script.file.name
to your own custom topology script.For example:
/etc/hadoop/conf/topology.sh
:Distribute that topology script to your hosts.
You can now manage the rack mapping information for your script outside of Ambari.