From owner-freebsd-questions@FreeBSD.ORG Tue Jun 17 22:36:00 2014 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id B4DF2A97 for ; Tue, 17 Jun 2014 22:36:00 +0000 (UTC) Received: from wp188.webpack.hosteurope.de (wp188.webpack.hosteurope.de [IPv6:2a01:488:42::50ed:84c3]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 773BA264E for ; Tue, 17 Jun 2014 22:36:00 +0000 (UTC) Received: from 178-25-216-40-dynip.superkabel.de ([178.25.216.40] helo=[192.168.1.25]); authenticated by wp188.webpack.hosteurope.de running ExIM with esmtpsa (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) id 1Wx1yu-00020a-LD; Wed, 18 Jun 2014 00:35:56 +0200 User-Agent: Kaiten Mail In-Reply-To: <53A089F8.4060409@gooch.io> References: <53A089F8.4060409@gooch.io> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset=UTF-8 Subject: AW: pppoe with ppp and pf nat - problems booting From: Paul Blockhaus Date: Wed, 18 Jun 2014 00:35:54 +0200 To: jesse@gooch.io,Jesse Gooch ,freebsd-questions@freebsd.org Message-ID: X-bounce-key: webpack.hosteurope.de; paul@mueller-blockhaus.de; 1403044560; f6ffbff1; X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 17 Jun 2014 22:36:00 -0000 -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA512 The Problrm could be, that the system doesn't wait long enough for setting up ppp, pls. let us have a look in your /var/log/messages. If it is like I think you should append the option netwait_if_timeout in the man /etc/rc.conf. It is possible, that ppp needs up to 3 minutes. PS: google is your friend and the man too :-) Greetings Paul On 17. Juni 2014 20:33:28 MESZ, Jesse Gooch wrote: >Hello all! > >I've just set up an i386 box as my router with FreeBSD 10-RELEASE >(updated with freebsd-update). I have two interfaces: sk0 and rl0. sk0 >is configured in ppp.conf for pppoe to my DSL modem. rl0 is configured >to a local IP, and I have pf set up for NAT and some port forwarding. >Unfortunately on boot pf does not get set up since tun0 (created by >ppp) >does not exist when pf loads, so my ruleset is not loaded! > >This requires me to reload the pf ruleset whenever I reboot. Another >problem with this approach is ntpdate fails to set time properly on >boot >as well (although this may be ppp taking a little while to get the >connection set up). > >How can I get my system to just work when I boot up? I've copypasta'd >the related conf files with names changed to protect the innocent >below. > >---ppp.conf--- >default: > set log Phase tun command > disable ipv6 > >name_of_isp: > disable ipv6 > set device PPPoE:sk0 > set authname isp_un > set authkey isp_pw > set dial > set login > add default HISADDR > add default HISADDR6 > enable dns >--- > >---rc.conf--- >hostname="my_hostname" >#this address is assigned to sk0 so I can access the administration >page >of my modem >ifconfig_sk0="inet 192.168.1.100 netmask 255.255.255.0" >ifconfig_rl0="inet 192.168.42.1 netmask 255.255.255.0" >gateway_enable="YES" >pf_enable="YES" >pflog_enable="YES" >ppp_enable="YES" >ppp_mode="ddial" >ppp_nat="NO" >ppp_profile="name_of_isp" >dhcpd_enable="YES" >dhcpd_ifaces="rl0" >named_enable="YES" >ddclient_enable="YES" >sshd_enable="YES" >#ntpdate_enable="YES" >#ntpdate_flags="-t 30 _timeservers_" >ntpd_enable="YES" >powerd_enable="YES" ># Set dumpdev to "AUTO" to enable crash dumps, "NO" to disable >dumpdev="AUTO" >--- > >---pf.conf--- ># Macros >ext_if = "tun0" >lan_if = "rl0" >lan_ip = "192.168.42.0/24" > ># Tables > ># Options > ># Traffic Normalization >scrub in on $ext_if all fragment reassemble > ># Queueing > ># Translation >nat pass on $ext_if from $lan_ip to any -> {$ext_if} >#some redirect rules removed for port forwarding here > ># Packet Filtering >block in on $ext_if all >pass out on $ext_if all keep state >pass in on $lan_if all >pass out on $lan_if all >--- >_______________________________________________ >freebsd-questions@freebsd.org mailing list >http://lists.freebsd.org/mailman/listinfo/freebsd-questions >To unsubscribe, send any mail to >"freebsd-questions-unsubscribe@freebsd.org" -----BEGIN PGP SIGNATURE----- Version: APG v1.1.1 iD8DBQFToMLKLyFhCfL04ssRCt19AKDL1kVeAROLhUiFQKYkTqkpvRElYQCeM7ta swEiE4yd7fhNdqfibK8nz/I= =S4JM -----END PGP SIGNATURE-----