Wednesday, June 17, 2009

Add or remove a script on startup in Debian or Ubuntu

Add a script:

1. put the script under /etc/init.d/
2. #chmod 755 myscript
3. #update-rc.d myscript defaults
4. #reboot

-------------------------------------------------------
Remove :

1. #cd /etc/init.d/
2. #update-rc.d -f myscript remove
3. #reboot

more over , please use "man update-rc.d" command

No comments: