NameNode HA when using hdfs:// URI
问题 With HDFS or HFTP URI scheme (e.g. hdfs://namenode/path/to/file ) I can access HDFS clusters without requiring their XML configuration files. It is very handy when running shell commands like hdfs dfs -get , hadoop distcp or reading files from Spark like sc.hadoopFile() , because I don't have to copy and manage xml files for all relevant HDFS clusters to all nodes that those codes might potentially run. One drawback of this approach is that I have to use the active NameNode's hostname,