iptables check every hour
Always use full path i.e /sbin/iptables for setting iptables in crontab 0 * * * * /bin/sh /bum/iptables_check.sh #!/bin/bash##Check if firewall is upISUP=`/sbin/iptables -L -n | grep DROP`if [ -z “$ISUP” ]thenecho “Firewall is down on `hostname`” | mail -s “Firewall Status” [email protected] chmod 700 iptables_check.sh