9 stat_busy
"Starting Vuurmuur Firewall"
12 # check if vuurmuur is configured
13 IFNUM
=`/usr/bin/vuurmuur_script --list --interface any | wc -l`
14 if [ $IFNUM = 0 ]; then
15 stat_busy
"Please configure Vuurmuur first by defining at least one interface."
21 .
/etc
/vuurmuur
/modules.conf
22 for MODULE
in `echo $MODULES_TO_LOAD`; do
23 /sbin
/modprobe
$MODULE &>/dev
/null
25 stat_busy
"Error when loading module $MODULE. Check log files."
31 # start vuurmuur daemon
32 if [ ! -f /var
/run
/vuurmuur.pid
]; then
35 stat_busy
"Error when starting Vuurmuur daemon. Check log files."
39 PID
=`cat /var/run/vuurmuur.pid | cut -d " " -f 1`
40 stat_busy
"Error when starting Vuurmuur daemon. Already running at pid $PID."
44 # start vuurmuur log parsing daemon
45 if [ ! -f /var
/run
/vuurmuur_log.pid
]; then
48 stat_busy
"Error when starting Vuurmuur log parsing daemon. Check log files."
52 PID
=`cat /var/run/vuurmuur_log.pid | cut -d " " -f 1`
53 stat_busy
"Error when starting Vuurmuur log parsing daemon. Already running at pid $PID."
58 if [ $STATUS = "ok" ]; then
69 stat_busy
"Stopping Vuurmuur Firewall"
72 # stop vuurmuur log parsing daemon
73 PID
=`cat /var/run/vuurmuur_log.pid | cut -d " " -f 1`
74 if [[ ! -z $PID ]] && kill "$PID" &>/dev
/null
; then
75 rm -f /var
/run
/vuurmuur_log.pid
77 stat_busy
"Error when stopping Vuurmuur log parsing daemon. Check log files."
81 # stop vuurmuur daemon
82 PID
=`cat /var/run/vuurmuur.pid | cut -d " " -f 1`
83 if [[ ! -z $PID ]] && kill "$PID" &>/dev
/null
; then
84 rm -f /var
/run
/vuurmuur.pid
86 stat_busy
"Error when stopping Vuurmuur daemon. Check log files."
91 if [ $STATUS = "ok" ]; then
106 echo "Usage: $0 {start|stop|restart}" >&2