从CDSW找到群集版本的程序化方法-Cloudera Data Science Workbench
是否有任何程序化方法可以从CDSW会话中找出群集版本(CDH6或CDP7)? 任何环境变量都可以提供一种愚蠢的方式来确定群集版本吗?
Is there any programmatic way to find out the cluster version(CDH6 or CDP7) from a CDSW session?
Could any environment variable give a fool-proof way to determine the cluster version?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您可以使用Cloudera REST API来实现这一目标。
https://:7180/api/v43/cm/版本
结果:
{
“版本”:版本,
“建筑商”:“詹金斯”,
“ buildTimestamp”:“ 20180402-2150”,
“ githash”:“ 4ADCD280DDE9C492680ADA3EE369B4E97D22137A”,
“快照”:false
}
api docs: https> https:// archive。 cloudera.com/cm7/7.2.4/generic/jar/cm_api/apidocs/index.html
You can use cloudera rest apis to achieve this.
https://:7180/api/v43/cm/version
Result:
{
"version" : version,
"buildUser" : "jenkins",
"buildTimestamp" : "20180402-2150",
"gitHash" : "4adcd280dde9c492680ada3ee369b4e97d22137a",
"snapshot" : false
}
API docs : https://archive.cloudera.com/cm7/7.2.4/generic/jar/cm_api/apidocs/index.html