Run Script at Startup in /Etc/Init. D/
Trying to Make My Script Run at Startup by Placing It in /Etc/Init. D/. but This Doesn't Helped. What Else I Must Do? 1 Answer It Needs to Be Executable and...
Trying to make my script run at startup by placing it in /etc/init.d/. But this doesn't helped. What else I must do?
1 Answer
It needs to be executable and installed.
Make it executable:
sudo chmod +x /etc/init.d/YOUR_SCRIPT
Install it to all runlevels:
sudo update-rc.d YOUR_SCRIPT defaults
Now restart and see your script gets run at startup.
Have Fun!
[edit]
Btw. Your script is a service now. You could always stop/start/restart it with
sudo service YOUR_SCRIPT stop/start/restart
[/edit]