3 # Startup script for pptpd
6 # description: PPTP server
8 # config: /etc/pptpd.conf
11 # Source function library.
12 .
/etc
/rc.d
/init.d
/functions
13 # See how we were called.
16 echo -n "Starting pptpd: "
17 if [ -f /var
/lock
/subsys
/pptpd
] ; then
21 daemon
/usr
/sbin
/pptpd
23 touch /var
/lock
/subsys
/pptpd
26 echo -n "Shutting down pptpd: "
29 rm -f /var
/lock
/subsys
/pptpd
35 if [ -f /var
/lock
/subsys
/pptpd
]; then
43 echo "Warning: a pptpd restart does not terminate existing "
44 echo "connections, so new connections may be assigned the same IP "
45 echo "address and cause unexpected results. Use restart-kill to "
46 echo "destroy existing connections during a restart."
50 ps
-ef |
grep pptpd |
grep -v grep |
grep -v rc.d |
awk '{print $2}' |
uniq |
xargs kill 1> /dev
/null
2>&1
54 echo "Usage: $0 {start|stop|restart|restart-kill|status}"