社区微信群开通啦,扫一扫抢先加入社区官方微信群
社区微信群
Note:working with user root.
1. 创建自启动脚本test.sh,一般放置到/etc/init.d/目录(optional)
#!bin/sh
xxxxxxxxxxxxxxx
2. 确定系统的启动level.
cat /etc/inittab
See the output line “id:?:initdefaut”, the value of the ? is the value for your system
3.链接启动脚本到启动序列目录
cd /etc/rc.d/rc?.d/
ln -s ../init.d/test.sh S##test
Where ## must be replaced by a number that is notcurrently in use by another symbolic link in the folder
如果觉得我的文章对您有用,请随意打赏。你的支持将鼓励我继续创作!