RE: RH9 Processes Failing

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> This is a strange place to be running these sorts of applications.  You
> should, instead, create a start/stop script for in /etc/rc.d/init.d - a
> good approach would be to copy one of the scripts there and modify it
> accordingly.  Then do:
> # chckconfig --add cam          or whatever you call your script
> # service cam start             to start it now
>
> I suspect the issue you're seeing with putting it in inittab is that
> /home might not be mounted at the time your application starts.

Needless to say, Im a bit new at this.  Ive been researching since your
suggestion, and I havent found where a file in /etc/rc.d/init.d actually
runs the application.
For example, here is the contents of the yum file there:
***
# cat yum
#!/bin/bash
#
# yum           This shell script enables the automatic use of YUM
#
# Author:       Seth Vidal <skvidal@xxxxxxxxxxxx>
#
# chkconfig:    - 50 01
#
# description:  Enable daily run of yum, a program updater.
# processname:  yum
# config: /etc/yum.conf
#

# source function library
. /etc/rc.d/init.d/functions

lockfile=/var/lock/subsys/yum

RETVAL=0

start() {
        echo -n $"Enabling nightly yum update: "
        touch "$lockfile" && success || failure
        RETVAL=$?
        echo
}

stop() {
        echo -n $"Disabling nightly yum update: "
        rm -f "$lockfile" && success || failure
        RETVAL=$?
        echo
}

restart() {
        stop
        start
}

case "$1" in
  start)
        start
        ;;
  stop)
        stop
        ;;
  restart|force-reload)
        restart
        ;;
  reload)
        ;;
  condrestart)
        [ -f "$lockfile" ] && restart
        ;;
  status)
        if [ -f $lockfile ]; then
                echo $"Nightly yum update is enabled."
                RETVAL=0
        else
                echo $"Nightly yum update is disabled."
                RETVAL=3
        fi
        ;;
  *)
        echo $"Usage: $0
{start|stop|status|restart|reload|force-reload|condrest
art}"
        exit 1
esac

exit $RETVAL
***

What about that script actually runs anything?
Where can I learn more about doing what Im looking for?

.salvatore
http://www.sienar.org/
http://www.palmisanonet.com/



-- 
redhat-list mailing list
unsubscribe mailto:redhat-list-request@xxxxxxxxxx?subject=unsubscribe
https://www.redhat.com/mailman/listinfo/redhat-list

[Index of Archives]     [CentOS]     [Kernel Development]     [PAM]     [Fedora Users]     [Red Hat Development]     [Big List of Linux Books]     [Linux Admin]     [Gimp]     [Asterisk PBX]     [Yosemite News]     [Red Hat Crash Utility]


  Powered by Linux