abusehelper: Changed init start/stop order, sleep between botnet (re)starts
This commit is contained in:
parent
9054f4a5f8
commit
c6f81dafa1
1 changed files with 11 additions and 5 deletions
|
@ -1,6 +1,6 @@
|
|||
#!/bin/sh
|
||||
|
||||
# chkconfig: 2345 90 10
|
||||
# chkconfig: 2345 99 01
|
||||
# description: AbuseHelper botnets
|
||||
# processname: botnet
|
||||
|
||||
|
@ -56,8 +56,11 @@ botnet_action() {
|
|||
}
|
||||
|
||||
start_botnets() {
|
||||
for botnet in ${BOTNETS}; do
|
||||
botnet_action start ${botnet}
|
||||
set -- ${BOTNETS}
|
||||
while [ $# -gt 0 ]; do
|
||||
botnet_action start ${1}
|
||||
shift
|
||||
test -n "${1}" && sleep 10
|
||||
done
|
||||
}
|
||||
|
||||
|
@ -68,8 +71,11 @@ stop_botnets() {
|
|||
}
|
||||
|
||||
restart_botnets() {
|
||||
for botnet in ${BOTNETS}; do
|
||||
botnet_action restart ${botnet}
|
||||
set -- ${BOTNETS}
|
||||
while [ $# -gt 0 ]; do
|
||||
botnet_action restart ${1}
|
||||
shift
|
||||
test -n "${1}" && sleep 10
|
||||
done
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue