The init script /etc/rc.d/init.d/ipchains fails when Linux 2.4 is compiled with legacy support for ipchains as a module. $ uname -r 2.4.0-test12pre5-mpls0.700-gdt16 $ rpm -q ipchains ipchains-1.3.10-1 The following code explicitly loads the module if it is required. $ cd /etc/rc.d/init.d $ rcsdiff -r1.1 -c ipchains =================================================================== RCS file: RCS/ipchains,v retrieving revision 1.1 diff -c -r1.1 ipchains *** ipchains 2000/12/19 12:35:13 1.1 --- ipchains 2000/12/19 12:52:09 *************** *** 8,13 **** --- 8,14 ---- # # Script Author: Joshua Jensen <joshua> # -- hacked up by gafton with help from notting + # -- modified for Linux 2.4 by glen.turner+linux.au # # config: /etc/sysconfig/ipchains *************** *** 29,39 **** --- 30,49 ---- if [ "$KERNELMAJ" -eq 2 -a "$KERNELMIN" -lt 2 ] ; then exit 0 fi + if [ "$KERNELMAJ" -eq 2 -a "$KERNELMIN" -ge 4 ] ; then + # Linux 2.4 doesn't use IP chains, backward compatibility + # is provided with a module. + MODULAR="y" + fi case "$1" in start) # don't do squat if we don't have the config file if [ -f $IPCHAINS_CONFIG ]; then + # Install module if needed + [ "$MODULAR" == "y" ] && + action "Installing IP chains kernel module:" modprobe ipchains + # If we don't clear these first, we might be adding to # pre-existing rules. action "Flushing all current rules and user defined chains:" ipchains -F *************** *** 58,63 **** --- 68,76 ---- success "Resetting built-in chains to the default ACCEPT policy" || \ failure "Resetting built-in chains to the default ACCEPT policy" echo + # Remove module if installed + [ "$MODULAR" == "y" ] && + action "Removing IP chains kernel module:" rmmod ipchains rm -f /var/lock/subsys/ipchains ;;
*** This bug has been marked as a duplicate of 22612 ***