Need Boot up Script

Hai,

I want to run DYNDNS (inadyn) when the system is booted.
I placed this Directory in /opt/inadyn.

/opt/inadyn

And also I want to know how to run any script in system boot up and Steps to follow.

can anyone help me ?
Forward Message

From their site : "The inadyn executable found in bin/linux/inadyn is self contained and can be launched at any time" - in your case you've put the binary executable in /opt, which is fine I guess. So if you need to launch it on every system boot, put a script to call this pull path every time when the system boots, for example I have Fedora 8 as local workstation, I would put such commands in /etc/rc.local file, you just have to find the file where to place it, depending on your flavor of unix.

If i copy the inadyn file and put it in /etc/rc.local will it work

well, if rc.local is being executed upon system boot, then the answer is yes, here is the content of my rc.local file :

I am using UBUNTU.
here is my rc.local

#!/bin/sh -e
#
# rc.local
#
# This script is executed at the end of each multiuser runlevel.
# Make sure that the script will "exit 0" on success or any other
# value on error.
#
# In order to enable or disable this script just change the execution
# bits.
#
# By default this script does nothing.

exit 0
~
~

Will it work?
I have written a script and moved to /etc/init.d/
The file name is inadyn the content as follows

#!/bin/sh
case "$1" in
start)
/usr/sbin/inadyn
;;
stop)
;;
*)
echo @"Usage: $0{start}"
exit 1
esac
exit 0
~
And linked to rc2.d
ln -s /etc/init.d/inadyn S30inadyn

But not working.

Can u please help me ?

Before the "exit 0" part of your rc.local put the full path to the binary with the respective parameters.

As you told I added in rc.local .
Here is my rc.local

#!/bin/sh -e
#
# rc.local
#
# This script is executed at the end of each multiuser runlevel.
# Make sure that the script will "exit 0" on success or any other
# value on error.
#
# In order to enable or disable this script just change the execution
# bits.
#
# By default this script does nothing.
/opt/inadyn/bin/linux/inadyn
exit 0

But not working.What to do?

HI,

In 'rc.local' file, just give executable file_name.

For eg., if you store 'hello.sh' script in /opt directory and you 

want it to execute at boot time, then just write 'rc.local' file as:

sh /opt/hello.sh

 Note: this is extra part, you can write only 'hello.sh', but your executable 

 script must be in '/usr/bin' or '/usr/sbin/' directory......you can read more 

 on this from the website 'http://linuxhomenetworking.com/'

 I think you will enjoy it.

Have a nice day............

Regards,
JAGDISH