07-18-2018 07:55 AM - edited 07-18-2018 08:06 AM
Now I am able to
- create management service
- download cdh parcels
- distribute cdh parcels
- activate cdh parcels
- insepct host
- create services (such as Kafka, ZooKeeper)
However, the script fails when executing first run command. It complains
Excuting first run command. This might take a while. The first run command failed: Failed to perform First Run of services.
Checking the endpoint localhost:7180/cmf/commands/commands, in Recent Commands there exists hightlight error (in red) about command Start, Restart, displaying
First error: Service mgmt has 0 Service Monitors. Cloudera Management Service requires at least 1 Service Monitor.
How do I create Servicie Monitor? From doc (https://cloudera.github.io/cm_api/docs/python-client/), RESTful api (https://cloudera.github.io/cm_api/apidocs/v5.15.0/index.html), pydoc (https://cloudera.github.io/cm_api/epydoc/5.15.0/index.html), and github.com (https://github.com/cloudera/cm_api/search?q=service+monitor&unscoped_q=service+monitor) I do not discover any related info on how to create service monitors.
Any code snippet or doc that tells how to create service monitor? Or how to pass first run command?
This time my script doesn't conttains lines 194 ~ 231 (that create hive and report manager) as listed at https://github.com/cloudera/cm_api/blob/master/python/examples/cluster_set_up.py Another problem raised if trying to create hive and report manager, the script complains No REPORTSMANAGER role found error.
07-18-2018 09:40 AM
Ok. Seems to work based on the below code snippet.
Between lines 488 ~ 493 and 518. Basically can fix service monitor error. (There are some other error, but it's not related to this problem any more).