Hi,

I have made this script to be used with Linux-IrDA and Redhat, so you can
start IrDA (irmanger) at startup and shut it down at reboot or halt. I'll
eventually put it into irda-utils.

You should put it into /etc/rc.d/init.d and make the needed links from the
runlevel you are using (I used the control-panel for this). You should
start it somewhere after networking and before PCMCIA.

-- Dag

-- 
   / Dag Brattli                   | The Linux-IrDA Project               /
  // University of Tromsoe, Norway | Infrared communication for Linux    //
 /// http://www.cs.uit.no/~dagb    | http://www.cs.uit.no/linux-irda/   ///

#!/bin/sh
#
# irmanager     This shell script takes care of starting and stopping
#               irmanger (irda daemon).
#
# description: lrmanager is the irda daemon required for irda to work \
# properly. 
#

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

# Source networking configuration.
. /etc/sysconfig/network

# Check that networking is up.
[ ${NETWORKING} = "no" ] && exit 0

[ -f /usr/sbin/irmanager ] || exit 0

# See how we were called.
case "$1" in
  start)
        # Start daemons.
        echo -n "Starting irmanager: "
        daemon irmanager -d 1
        echo
        ;;
  stop)
        # Stop daemons.
        echo -n "Shutting down irmanager: "
        killproc irmanager
        echo
        ;;
  status)
        status irmanager
        ;;
  restart|reload)
        $0 stop
        $0 start
        ;;
  *)
        echo "Usage: irda {start|stop|restart|reload|status}"
        exit 1
esac

exit 0



_______________________________________________
Linux-IrDA mailing list  -  [EMAIL PROTECTED]
http://www.pasta.cs.UiT.No/mailman/listinfo/linux-irda

Reply via email to