Many times we need to set some services or scripts to start automatically on Linux, so as to avoid service interruption and other problems caused by machine restart. Let's take a look at how to set up auto-start under Linux: cd /etc/init.d vi myscript.sh #Modify myscript.sh to your own script name, write your own script, save and exit. When writing a script, please add the following comments #add for chkconfig #description: #A brief description of the script: 2345 refers to the running level of the script, that is, it can run in the four modes of 2345, 234 is a text interface, and 5 is a graphical interface. X70 refers to the future startup sequence number of the script. , if the startup sequence number of other programs is smaller than 70 (such as 44, 45), the script needs to wait until these programs are started before starting. 30 refers to the stop sequence number of the script when the system is shut down. Add executable rights to the script
1. Detailed introduction to startup programs or scripts in Linux
Introduction: Many times we need to set some services or scripts to start automatically on Linux, so as to avoid service interruption and other problems caused by machine restart. Let’s take a look at how to set up under Linux
2. hadoop configuration rack awareness
Introduction: Zhou Haihan? 2013.7.24 http://abloz.com If the device link level is divided into three layers, the first layer switch d1 is connected to multiple switches rk1, rk2, rk3, rk4,. Each switch corresponds to a rack. d1(rk1(hs11,hs12,),rk2(hs21,hs22,), rk3(hs31,hs32,),rk4(hs41,hs42,),) You can use a program or script to complete the mapping from host to device
The above is the detailed content of Detailed introduction to the program or script. For more information, please follow other related articles on the PHP Chinese website!