You should read up on runlevel scripts. They are all owned by root, mode 755. For Fedora, they are in /etc/rc.d/init.d, for debian /etc/init.d.
But they need to be linked into a runlevel directory (/etc/rc?.d). You will have to do some googling and reading to figure out which one. Basically, you do this:
ln -s /etc/init.d/myscript /etc/rc5.d/S50myscript
The rc?.d number corresponds to the runlevels managed by init (0,1,2,3,4,5,6)
The softlink name must begin with "S" for start and a number 0-99, which is the priority. You will find these directories full of such things.
The scripts have a particular start|stop|restart structure, which it is up to you whether to follow that or not, they will work fine anyway (that is up to you too).