Custom Hortonworks HDP Boot service can do this: the original source of this article: http://blog.csdn.net/bluishglc/article/details/42109253 prohibited any form of reprint, Otherwise will be commissioned CSDN official maintenance rights!
Files found:/usr/lib/hue/tools/start_scripts/start_deps.mf,hortonworks HDP the command to start all services and components is in this file, The reason for these services to write the startup command in a makefile rather than a shell file, in fact, is to use make to rely on management to easily solve the dependencies between the components, services , which is worthy of our learning and reference, Especially if you need to provide a script to start the system, while the system components/services have dependencies.
Back to the point, first we have to make a backup:
CP /USR/LIB/HUE/TOOLS/START_SCRIPTS/START_DEPS.MF /USR/LIB/HUE/TOOLS/START_SCRIPTS/START_DEPS.MF . bak
And then:
VIM/USR/LIB/HUE/TOOLS/START_SCRIPTS/START_DEPS.MF
To find the "All:startup Ambari Others" line, append the custom startup item to the front, and if we only need hive, we can write:
#Added by Laurence:customized Startup
Customized:hdfs YARN Zookeeper Hive_metastore webhcat
Save and exit, and then open this file:/usr/lib/hue/tools/start_scripts/startup_script, also make a backup first:
CP /usr/lib/hue/tools/start_scripts/startup_script /usr/lib/hue/tools/start_scripts/startup_script . bak
And then:
Vim/usr/lib/hue/tools/start_scripts/startup_script
Find the line where the keyword "startup" is located, find the post comment and copy a row, and change the startup to customized on the new line
#make--makefile $SCRIPTS _path/start_deps.mf-b startup-j-I.
Make--makefile $SCRIPTS _path/start_deps.mf-b customized-j-I.
In this way, the boot is started exactly as we have listed in customized.
About Ambari and HBase boot-up:
Ambari and HBase start-up can be configured in the START_DEPS.MF, can also be controlled through the chkconfig! If you want the unified configuration in START_DEPS.MF , you need to turn off their startup items independently:
Chkconfig Ambari off
Chkconfig Hbase-starter off
Currently (at 2.2 just released) HBase's startup script is wrong, causing HBase to fail to start and need to manually modify several command lines in START_DEPS.MF to start hbase! Please refer to my next article on this question: http://blog.csdn.net/bluishglc/article/details/42110429
Hortonworks HDP Sandbox Custom (configuration) boot-up service (component)