Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我需要能够找到 Ambari 管理器正在使用的 core-site.xml 和 hdfs-site.xml 的位置。
我最初的想法是查询 Ambari API 来执行此操作,但我找不到任何将返回这两个文件中的任何一个的路径的端点。
谁能指出我正确的方向?我一直在通过 Ambari 文档和谷歌搜索无济于事。
提前致谢!!
~画了
这些服务的配置目录是静态的。它们在服务定义的 params.py 文件中定义。例如,在 Ambari 2.0 中,您可以在以下位置查看 HDFS 服务定义 params.py 文件:
/var/lib/ambari-server/resources/common-services/HDFS/2.1.0.2.0/package/scripts/params.py
您将在该文件中找到以下值:
hadoop_conf_dir = "/etc/hadoop/conf"