Reply
Explorer
Posts: 16
Registered: ‎02-09-2016

Auto-redeploy of client configuration...

Is there a way to programatically force a configuration redeploy/refresh?

 

We spin up lots of cluster instances from AWS AMIs that have Cloudera preinstalled, and we're manually having to go into the UI to accomplish this.

 

Thanks.

 

Highlighted
Cloudera Employee
Posts: 212
Registered: ‎07-08-2013

Re: Auto-redeploy of client configuration...

Explorer
Posts: 16
Registered: ‎02-09-2016

Re: Auto-redeploy of client configuration...

Is this method supported with Cloudera Express 5.6.0?

 

 

Cloudera Employee
Posts: 212
Registered: ‎07-08-2013

Re: Auto-redeploy of client configuration...

It should, have you noticed otherwise?

Explorer
Posts: 16
Registered: ‎02-09-2016

Re: Auto-redeploy of client configuration...

Cloudera Employee
Posts: 212
Registered: ‎07-08-2013

Re: Auto-redeploy of client configuration...

Perhaps /v17/ isn't applicable for your version of CM - check the /api/version endpoint and see what version your CM supports/returns with. 

 

Here's a table that map version of CM API to CM version

 

http://cloudera.github.io/cm_api/docs/releases/

Explorer
Posts: 16
Registered: ‎02-09-2016

Re: Auto-redeploy of client configuration...

I looks like I'm running CM 5.6, which isn't listed in the mapping table you refer to.

 

However, I tried different API versions using the following url: http://172.31.5.254:7180/api/v1/clusters/Cluster%201/services/hdfs, and got this back:

 

{
  "name" : "hdfs",
  "type" : "HDFS",
  "clusterRef" : {
    "clusterName" : "cluster"
  },
  "serviceUrl" : "http://172.31.5.254:7180/cmf/serviceRedirect/hdfs",
  "serviceState" : "STARTED",
  "healthSummary" : "GOOD",
  "healthChecks" : [ {
    "name" : "HDFS_BLOCKS_WITH_CORRUPT_REPLICAS",
    "summary" : "GOOD"
  }, {
    "name" : "HDFS_CANARY_HEALTH",
    "summary" : "GOOD"
  }, {
    "name" : "HDFS_DATA_NODES_HEALTHY",
    "summary" : "GOOD"
  }, {
    "name" : "HDFS_FREE_SPACE_REMAINING",
    "summary" : "GOOD"
  }, {
    "name" : "HDFS_HA_NAMENODE_HEALTH",
    "summary" : "GOOD"
  }, {
    "name" : "HDFS_MISSING_BLOCKS",
    "summary" : "GOOD"
  }, {
    "name" : "HDFS_UNDER_REPLICATED_BLOCKS",
    "summary" : "BAD"
  } ],
  "configStale" : false

 

So V1 is responding to something at least, but it maps to CM 4.0, which doesn't make any sense.

Cloudera Employee
Posts: 212
Registered: ‎07-08-2013

Re: Auto-redeploy of client configuration...

[ Edited ]

Quote: However, I tried different API versions using the following url: http://172.31.5.254:7180/api/v1

 

Based on the documentation linked previously, the endpoint you're trying to use was "Added in v3:"

 

With regards to the version check http://172.31.5.254:7180/api/version - the returned output can be then used in http://172.31.5.254:7180/api/v...

 

In addition this is a REST POST, not a GET, the expected response Body after the POST is documented here [0]

 

Let me know if this helps

 

 

[0] https://cloudera.github.io/cm_api/apidocs/v17/path__clusters_-clusterName-_services_-serviceName-_co...

Explorer
Posts: 16
Registered: ‎02-09-2016

Re: Auto-redeploy of client configuration...

Thanks, I was able to make all the calls I needed to redeploy the configuration and restart everything on the command line.

 

Announcements