Troubleshooting init.d script

This is what I did:

  1. I wrote a simple init.d script (myscript.sh)

  2. I placed it under /etc/init.d (where many other default scripts already are)

  3. Set the perms to 755

  4. Run: update-rc.d myscript.sh defaults

I can run it perfectly by doing:

/etc/init.d/myscript.sh start

But it doesn't run at startup. What am I missing?

Did you set the user and group of the script to root?

Did you check de rc[0-n].d run level links? Do you have LSB comment headers in your init script?

From the man page: