automatic execution of shell script

Dear All,

I want to execute a shell script,whlie system is booting.
I was try using /etc/rc.d/rc.local file but its not working.

This will explain it:
Linux: Init Process and PC Boot Procedure