From owner-freebsd-questions@FreeBSD.ORG Wed Nov 11 20:23:02 2009 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 4DC1310656A6 for ; Wed, 11 Nov 2009 20:23:02 +0000 (UTC) (envelope-from freebsd-questions@m.gmane.org) Received: from lo.gmane.org (lo.gmane.org [80.91.229.12]) by mx1.freebsd.org (Postfix) with ESMTP id 06FE48FC19 for ; Wed, 11 Nov 2009 20:23:01 +0000 (UTC) Received: from list by lo.gmane.org with local (Exim 4.50) id 1N8JiU-00009f-Kx for freebsd-questions@freebsd.org; Wed, 11 Nov 2009 21:22:58 +0100 Received: from pool-71-166-134-75.washdc.east.verizon.net ([71.166.134.75]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Wed, 11 Nov 2009 21:22:58 +0100 Received: from nightrecon by pool-71-166-134-75.washdc.east.verizon.net with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Wed, 11 Nov 2009 21:22:58 +0100 X-Injected-Via-Gmane: http://gmane.org/ To: freebsd-questions@freebsd.org From: Michael Powell Followup-To: gmane.os.freebsd.questions Date: Wed, 11 Nov 2009 15:23:33 -0500 Lines: 53 Message-ID: References: <4AF57EB4.3070104@gmail.com> <20091107180710.GA1056@jason-helfmans-macbook-pro.local> <4AF5BB31.5090304@gmail.com> <4AF7620A.9010709@gmail.com> <4AFAE13F.1040703@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: 7Bit X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: pool-71-166-134-75.washdc.east.verizon.net Sender: news Subject: Re: networking won't come back up until reboot after ISP outage X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 11 Nov 2009 20:23:02 -0000 umage wrote: [snip] >> In my case the router does get the renewed ip, as I described earlier. >> However, even after waiting 8+ hours, the system will not recover from >> the outage properly (reason unknown). That's what this thread is all >> about. > When I started the system today, I found that again it had no > connectivity. I did some checks and then found that 'natd' was not > running. But this is not happening that frequently, and seems to only > have started after the last system update. Could be some sort of race > condition. Is there a logfile that natd writes to, so that I may > investigate the reason why it is exiting? My first gut instinct about your problem was to blame dhclient first. But no NATD would definitely be a problem. I am assuming we are talking about IPFW and NATD here, and it has been many years since I've used it. I migrated to IPFILTER and then on to PF quite some time ago. Most logging related to IPFW is already present, but IIRC to log NATD you need to turn it on, and possibly configure it in syslog.conf should you desire the output somewhere other than /var/log/alias.log. Keep in mind there are two ways to pass options. You can use something like natd_flags="-l" in /etc/rc.conf. Man natd will provide a list. The second method is to place the options in a file such as natd.conf and pull them in like natd_flags="-f /etc/natd.conf". I looked in my notes and here is a snippet from an old /etc/rc.conf: natd_enable="YES" natd_interface="ppp0" natd_flags="-f /etc/natd.conf" My /etc/natd.conf: interface ppp0 use_sockets yes same_ports yes dynamic yes You could add a 'log yes' line here; it does the same as the -l described above. Note that you might need the 'dynamic yes' switch for an interface that changes. In my case I was using it for a ppp dial-up connection, change interface as needed. Sounds like you are narrowing down the culprit(s). Also note that it could possibly be a timing issue related to the order things start up. If the NATD is attempting to start before the interface has come up it will die. Shouldn't happen, but... YMMV -Mike