I am using no-ip.com's redirection services to run my webserver on Gentoo.. I downloaded their client and installed it. Now I wanted it to load at startup. I looked at the readme and here are the instructions...





###########################################################################
HOW TO START THE CLIENT

The noip2 executable can be run by typing /usr/local/bin/noip2

If you want it to run automatically when the machine is booted, then
place the following script in your startup directory. (/etc/init.d/rcX.d
or /sbin/init.d/rcX.d or ???)

        #######################################################
        #! /bin/sh
        # . /etc/rc.d/init.d/functions  # uncomment/modify for your killproc
        case "$1" in
            start)
                echo "Starting noip2."
                /usr/local/bin/noip2
            ;;
            stop)
                echo -n "Shutting down noip2."
                killproc -TERM /usr/local/bin/noip2
            ;;
            *)
                echo "Usage: $0 {start|stop}"
                exit 1
        esac
        exit 0
        #######################################################

Where the 'X' in rcX.d is the value obtained by running the
following command
        grep initdefault /etc/inittab | awk -F: '{print $2}'

Killproc can be downloaded from ftp://ftp.suse.com/pub/projects/init
Alternatively, you can uncomment the line after #! /bin/sh





Now, if I'm not mistaken, if I add a proper script to /etc/init.d/ then I can add it to the default runlevel using rc-update. But, I have no knowledge of scripting and I'm wondering if the above script would work... Can anyone help me?

Thank you.
--
[email protected] mailing list



Reply via email to