From owner-freebsd-isp Fri Sep 17 4:37:25 1999 Delivered-To: freebsd-isp@freebsd.org Received: from volodya.prime.net.ua (volodya.prime.net.ua [195.64.229.17]) by hub.freebsd.org (Postfix) with ESMTP id 80A0C1530B for ; Fri, 17 Sep 1999 04:37:17 -0700 (PDT) (envelope-from andyo@prime.net.ua) Received: from prime.net.ua (localhost [127.0.0.1]) by volodya.prime.net.ua (8.9.3/8.8.8) with ESMTP id OAA01589; Fri, 17 Sep 1999 14:37:50 +0300 (EEST) (envelope-from andyo@prime.net.ua) Message-ID: <37E2280A.E43F323@prime.net.ua> Date: Fri, 17 Sep 1999 14:37:47 +0300 From: "Andy V. Oleynik" Organization: M-Info X-Mailer: Mozilla 4.61 [en] (X11; I; FreeBSD 3.2-STABLE i386) X-Accept-Language: en, ru, uk MIME-Version: 1.0 To: Victor Meirans Cc: FreeBSD ISP mailing list Subject: Re: What am I doing wrong? References: <37E164BE.BAECADE0@rezekne.lv> Content-Type: text/plain; charset=koi8-r Content-Transfer-Encoding: 8bit Sender: owner-freebsd-isp@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org Just assign natd_flags "-n ed1 -u" value. My internal network runs pretty with this setup. Victor Meirans wrote: > Hello... > I need to set up a FreeBSD (3.2-RELEASE) router with NAT. 2 NICs. > The situation is: > > Internet > | > | > --------159.148.42.241 > |Router|------------------ > --------255.255.255.252 | > | > | > |159.148.42.242 > |255.255.255.252 > ------------- > | FreeBSD | > ------------- > |192.168.1.254 > |255.255.255.0 > | > | --------------- > |-----------------------|Local network| > |192.168.1.0 | > |255.255.255.0| > --------------- > > What I did: > > 1. Compiled kernel with > options IPFIREWALL > options IPDIVERT > > 2. My rc.conf is > moused_port="/dev/psm0" > moused_enable="YES" > saver="logo" > gateway_enable="YES" > firewall_enable="YES" > natd_enable="YES" > natd_interface="ed1" > natd_flags="-f /etc/natd.conf" > hostname="ufo.blezurs.lv" > ifconfig_ed2="inet 192.168.1.254 netmask 255.255.255.0" > ifconfig_ed1="inet 159.148.42.242 netmask 255.255.255.252" > defaultrouter="159.148.42.241" > network_interfaces="ed2 ed1 lo0" > linux_enable="YES" > ntpdate_enable="YES" > ntpdate_flags="Time1.Stupi.SE" > named_enable="YES" > > 3. My rc.firewall is > /sbin/ipfw -f flush > /sbin/ipfw add divert natd all from any to any via ed1 > /sbin/ipfw add pass all from any to any > > 4. My rc.local just runs natd > > natd -f /etc/natd.conf > > 5. My natd.conf is > interface ed1 > use_sockets yes > same_ports yes > dinamic yes > > That's all. Nothing works. I can't ping the router nor I can ping local > addresses. Am I missing something? Is something misconfigured? > Thanks in advance... > > -- > ---> ViC <--- > > --==> Rezekne Internet Service Center http://www.risc.lv > "PCT Latgale" Ltd. Phone: +371-4622972 > Baznicas 17, Rezekne, Fax: +371-4625931 > LV-4601, Latvia GSM: +371-9577569 > -==--==--==--==--==--==--==--==--==--==--==--==--==--==--==--==--==- > > To Unsubscribe: send mail to majordomo@FreeBSD.org > with "unsubscribe freebsd-isp" in the body of the message -- WBW Andy V. Oleynik (When U work in virtual office prime.net.ua's U have good chance to obtain system administrator virtual money ö%-) +380442448363 To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-isp" in the body of the message