aboutsummaryrefslogtreecommitdiffstats
path: root/testing/tests/ikev2/dhcp-static-client-id/hosts/venus/etc/init.d/dhcpd
blob: 4044dcc35ea8f09b0d6573ea10d6d9572cd493c2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#!/sbin/runscript
# Copyright 1999-2004 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2

opts="start stop"

depend() {
	need net
	need logger
}

start() {
	ebegin "Starting DHCP server"
	start-stop-daemon --start --quiet --exec /usr/sbin/dhcpd
	eend $?
}

stop() {
	ebegin "Stopping DHCP server"
	start-stop-daemon --stop --quiet --pidfile /var/run/dhcpd.pid
	rm -f /var/state/dhcp/dhcpd.leases
	touch /var/state/dhcp/dhcpd.leases
	eend $?
}