1.建立 .sh文件 #/bin/bash killall xxx slepp 2 cd /home/xxx/xxx ./xxx 2.在/etc/rc.local 中加上 .sh文件路径 例如 bash /home/xxx.sh