--- /dev/null
+#! /bin/sh
+# Startup script for udpgate
+#
+# chkconfig: 2345 98 02
+# description: UDP packats gateway
+
+# Source function library.
+. /etc/rc.d/init.d/functions
+
+[ -f /usr/sbin/udpgate ] || exit 0
+
+prog="udpgate"
+
+start() {
+ echo -n $"Starting $prog: "
+ daemon udpgate --start
+ RETVAL=$?
+ echo
+ return $RETVAL
+}
+
+stop() {
+ if test "x`pidof udpgate`" != x; then
+ echo -n $"Stopping $prog: "
+ killproc udpgate
+ echo
+ fi
+ RETVAL=$?
+ return $RETVAL
+}
+
+case "$1" in
+ start)
+ start
+ ;;
+
+ stop)
+ stop
+ ;;
+
+ status)
+ status udpgate
+ ;;
+ restart)
+ stop
+ start
+ ;;
+ condrestart)
+ if test "x`pidof udpgate`" != x; then
+ stop
+ start
+ fi
+ ;;
+
+ *)
+ echo $"Usage: $0 {start|stop|restart|condrestart|status}"
+ exit 1
+
+esac
+
+exit $RETVAL