From: Michael Prokop Date: Sun, 6 May 2007 09:15:26 +0000 (+0200) Subject: grml-iptstate: check for '_conntrack' module instead of ip_conntrack, some formating... X-Git-Tag: 0.9.46 X-Git-Url: http://git.grml.org/?p=grml-scripts.git;a=commitdiff_plain;h=b42f83d9c02a4dc3e1d950625b442a98283d25b7 grml-iptstate: check for '_conntrack' module instead of ip_conntrack, some formating changes. --- diff --git a/debian/changelog b/debian/changelog index 7169c7d..5283a14 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,10 @@ +grml-scripts (0.9.46) unstable; urgency=low + + * grml-iptstate: check for '_conntrack' module instead of + ip_conntrack, some formating changes. + + -- Michael Prokop Sun, 6 May 2007 11:14:30 +0200 + grml-scripts (0.9.45) unstable; urgency=low * bt-audio: use /etc/grml/script-functions, some more small diff --git a/usr_sbin/grml-iptstate b/usr_sbin/grml-iptstate index df254b1..0398cfa 100755 --- a/usr_sbin/grml-iptstate +++ b/usr_sbin/grml-iptstate @@ -8,20 +8,26 @@ ################################################################################ . /etc/grml/script-functions +. /etc/grml/lsb-functions check4progs iptstate || exit 1 -if grep -q ip_conntrack /proc/modules ; then +if grep -q '_conntrack' /proc/modules ; then iptstate else - echo "Module ip_conntrack is not present. Can not start iptstate therefore." - echo -n "Do you want to load it and invoke iptstate afterwards? [YES|no] " - read a - if [ "$a" = YES -o "$a" = yes -o "$a" = '' -o "$a" = y -o "$a" = Y ] ; then - modprobe ip_conntrack && exec iptstate - else - echo "Aborting as requested." - exit 1 - fi + einfo "iptstate is a top-like display of IP Tables state table entries." + echo + ewarn "Module ip_conntrack is not present. Can not start iptstate therefore." + eindent + einfon "Do you want to load it and invoke iptstate afterwards? [YES|no] " + read a + if [ "$a" = YES -o "$a" = yes -o "$a" = '' -o "$a" = y -o "$a" = Y ] ; then + modprobe ip_conntrack ; RC=$? + eend $RC + [ "$RC" = 0 ] && exec iptstate + else + echo "Aborting as requested." + exit 1 + fi fi ## END OF FILE #################################################################