cloudera manager sets the method for starting the machine

  • 2020-05-17 07:23:39
  • OfStack

Recently Cloudera manager was used to manage hadoop clusters. In order to facilitate automatic management, it is necessary to add automatic boot. Did a search on the web and found a method in an installation tutorial. Here I'm using the installation of cloudera-manager-el5-cm5.3.2 _x86_64.tar.gz. So the default is under /opt.

Solutions:

step1: copy the startup script will/opt/cm - 5.3.2 / etc/init d/directory cloudera scm - server server startup scripts and cloudera - scm - agent proxy service startup scripts are copied to the/etc/init d/directory. (/etc/ init.d/directory for startup scripts)

cloudera-scm-server is simply replicated on the machine on which the server is located. cloudera-scm-agent requires replication on all machines in the cluster.

step2: add boot boot

a, and then add boot on the server machine:

chkconfig --add cloudera-scm-server

chkconfig cloudera-scm-server on

Then check the status:

chkconfig --list cloudera-scm-server

If the 2-5 display is turned on, the configuration was successful.

b, and then add the agent boot to all the machines in the cluster to start automatically:

chkconfig --add cloudera-scm-agent

chkconfig cloudera-scm-agent on

Then check the status:

chkconfig --list cloudera-scm-agent

If the 2-5 display is turned on, the configuration was successful.

step3: modify cloudera-scm-server

At this point in the tutorial, the configuration is complete. In fact, I can also start automatically here, but only these two services are started, hdfs, yarn, zookeeper and other services managed by the cluster are not started. I found 1 problem, but it was found to be the problem of environment variables, and the script failed to find 1 variable.

a, 1 is the environment problem of jdk. Because the script was executed at startup, JAVA_HOME I configured was not read. So I need to add it by myself.

b, another one is also an environmental problem. I did not find my cm-5.3.2 directory, so I need to manually configure it.

Enter/etc/init. d/directory:

vim cloudera-scm-server

Add: export JAVA_HOME = / usr/local/jdk / # your java installation directory

Change: CMF_DEFAULTS=${CMF_DEFAULTS:-/etc/default} CMF_DEFAULTS=${CMF_DEFAULTS =${CMF_DEFAULTS:-/opt/ cm-5.3.2 /etc/default} # your cloudera manager installation directory, then save and exit.

In this way, the boot can start automatically. These two services and the hbase, hdfs and other services they manage are up and running. I have passed the test.


Related articles: