#!/bin/sh # Description: Now that TCP/IP is configured, mount the NFS file # systems in /etc/fstab if needed. If possible, # start the portmapper before mounting (this is needed for # Linux 2.1.x and up). # # Also mounts SMB filesystems now, so the name of # this script is getting increasingly inaccurate. PATH=/sbin:/bin . /lib/init/vars.sh . /lib/lsb/init-functions do_start() { log_action_begin_msg "Loading iptables rule set" [ -f /var/lib/iptables/active ] || ( log_action_end_msg && return ) /sbin/iptables-restore < /var/lib/iptables/active > /dev/null 2>&1 ret=$? log_action_end_msg $ret return $ret } do_end() { log_action_begin_msg "Unloading iptables rule set" [ -f /var/lib/iptables/inactive ] || ( log_action_end_msg && return ) /sbin/iptables-restore < /var/lib/iptables/inactive > /dev/null 2>&1 ret=$? log_action_end_msg $ret return $ret } # Not for loopback! [ "$IFACE" != "lo" ] || exit 0 case "$PHASE" in up|post-up) do_start exit $? ;; post-down) do_end exit $? ;; *) log_failure_msg "$0: called with unknown action \`$2'" exit 1 ;; esac exit 0