packages/ipv6/ahcpd/files/ahcpd.init
kerneis ddee128613 [package] ahcpd: update to 0.51, fix scripts
- Full-featured UCI configuration file (including server mode).
- Client mode configuration in /etc/config/network (proto ahcp).
- Launch at most one instance in server/forwarder mode, and as many
  instance as interfaces in client mode.
- Add status and reload options to init script.
- Make /etc/config/ahcpd a config file, simplify Makefile.
- Do not check the pid file (useless).
- 29 January 2010: ahcpd 0.51
  * Servers are now configured with a plain-text configuration file.
  * Implemented client-side support for prefix delegation (-P).
  * Made requesting state more persistent, to deal with packet loss.
  * Fixed a typo that prevented the -I option from working.
  * Fixed compilation on BSD systems.
  * Fixed a bug that could cause an expired lease to be discarded when
    older ones are available.

Signed-off-by: Gabriel Kerneis <kerneis@pps.jussieu.fr>

git-svn-id: svn://svn.openwrt.org/openwrt/packages@19813 3c298f89-4303-0410-b956-a3cf2f4a3e73
2010-02-22 11:00:30 +00:00

32 lines
581 B
Bash

#!/bin/sh /etc/rc.common
START=71
PID_F="/var/run/ahcpd.pid"
EXTRA_COMMANDS="status"
EXTRA_HELP=" status Print ahcpd's status to the log file."
. /lib/network/ahcp.sh
start() {
mkdir -p /var/lib
config_load ahcpd
unset args
unset interfaces
config_foreach ahcp_config ahcpd
config_foreach ahcp_server ahcpd
[ -z "$interfaces" ] && return 0
eval "/usr/sbin/ahcpd -D -I $PID_F $args $interfaces"
}
stop() {
[ -f "$PID_F" ] && kill $(cat "$PID_F")
}
status() {
[ -f $PID_F ] && kill -USR1 $(cat $PID_F)
}
reload() {
[ -f $PID_F ] && kill -USR2 $(cat $PID_F)
}