#!/bin/bash
# chkconfig: - 90 10
# description: just a test
echo "Hello,$1"
mv test /etc/init.d/
chmod +x /etc/init.d/test
chkconfig --add test
service test start //可以看到Hello,start表示成功
如有问题,可以QQ搜索群1028468525加入群聊,欢迎一起研究技术
转载请注明:将自己编写的shell加入到service 出自老鄢博客 | 欢迎分享