Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 13 Oct 1998 12:41:20 -0700 (PDT)
From:      gelderen@mediaport.org
To:        freebsd-gnats-submit@FreeBSD.ORG
Subject:   conf/8306: NATD get loaded late in bootsequence
Message-ID:  <199810131941.MAA08043@hub.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         8306
>Category:       conf
>Synopsis:       NATD get loaded late in bootsequence
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    freebsd-bugs
>State:          open
>Quarter:
>Keywords:
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Tue Oct 13 12:50:00 PDT 1998
>Last-Modified:
>Originator:     Jeroen C. van Gelderen
>Organization:
>Release:        2.2.7/STABLE
>Environment:
FreeBSD wit395306.utwente.nl 2.2.7-RELEASE FreeBSD 2.2.7-RELEASE #0: Sat Oct 10 15:57:08 GMT 1998     root@wit395306.student.utwente.nl:/usr/src/sys/compile/FIREWALL  i386
>Description:
I've enabled natd in my rc.conf which works fine except when booting. This
has something to do with NATD only getting loaded in pass 3 of rc.network.

In the first pass of rc.network ipfw gets initialized and it is instructed
to divert everything to the natd which is not running at the time. Then the
various services (sendmail, etc) are started. Problem is that they lack
internet connectivity because traffic is diverted but natd is not yet
running (gets only initialized in pass 3).

The patch attached below fixes the problem for me, but it might not be the
right solution. I'd like someone to take this over and/or give some
feedback...

If you need an 'ungarbled' patch, please mail me...
>How-To-Repeat:
see above
>Fix:
*** rc.network Sun Oct 11 22:14:49 1998
--- rc.network.new Sun Oct 11 22:14:19 1998
***************
*** 87,98 ****
--- 87,104 ----
  echo "but firewall rules are not enabled."
  echo "         All ip services are disabled."
      fi
  fi
      fi

+
+     # Network Address Translation daemon
+     if [ "X${natd_enable}" = X"YES" -a "X${natd_interface}" != X"" -a
"X${firewall_enable}" = X"YES" ]; then
+             echo -n ' natd'; natd ${natd_flags} -n ${natd_interface}
+     fi
+
      # Configure routing

      if [ "x$defaultrouter" != "xNO" ] ; then
      static_routes="default ${static_routes}"
      route_default="default ${defaultrouter}"
      fi
***************
*** 252,267 ****
      unset stash_flag
      fi

      # IP multicast routing daemon
      if [ "X${mrouted_enable}" = X"YES" ]; then
      echo -n ' mrouted'; mrouted ${mrouted_flags}
-     fi
-
-     # Network Address Translation daemon
-     if [ "X${natd_enable}" = X"YES" -a "X${natd_interface}" != X"" -a
"X${firewall_enable}" = X"YES" ]; then
-             echo -n ' natd'; natd ${natd_flags} -n ${natd_interface}
      fi

      echo '.'
      network_pass3_done=YES
  }
--- 258,268 ----
>Audit-Trail:
>Unformatted:

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-bugs" in the body of the message



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199810131941.MAA08043>