CentOS五、6的启动流程

CentOS5/6的启动流程centos

启动流程画了张图,看着更清晰些: (centos7的启动流程变化挺大的,这部分待补充)bash

image.png


补充(/etc/rc.d/rc.local 不属于任何服务,为特殊文件,可将不能定义为服务又想开机运行的命令定义在此文件中)ide

 

添加自定义服务:centos7

[root@el5 init.d]# vi  /etc/init.d/testsrv spa

#!/bin/bashblog

#chkconfig: 223 92 60ip

#description:              programs at periodic scheduled times. vixie cron adds a \it

#              number of features to the basic UNIX cron, including better \io

#              security and more powerful configuration options.#table

echo "hello"

 

[root@el5 init.d]# chkconfig --add  testsrv

 

[root@el5 init.d]# service testsrv

hello

相关文章
相关标签/搜索