From owner-freebsd-questions Sat Jul 17 5:31:44 1999 Delivered-To: freebsd-questions@freebsd.org Received: from vulcan.addy.com (vulcan.addy.com [207.239.68.7]) by hub.freebsd.org (Postfix) with ESMTP id 1EF7114CE6 for ; Sat, 17 Jul 1999 05:31:38 -0700 (PDT) (envelope-from francisco@natserv.com) Received: from your-name (freyes.static.inch.com [207.240.212.43]) by vulcan.addy.com (8.8.5/8.6.12) with SMTP id IAA25076 for ; Sat, 17 Jul 1999 08:31:16 -0400 (EDT) Message-Id: <199907171231.IAA25076@vulcan.addy.com> From: "Francisco Reyes" To: "FreeBSD questions" Date: Sat, 17 Jul 1999 08:32:21 -0400 Reply-To: "Francisco Reyes" X-Mailer: PMMail 98 Professional (2.01.1600) For Windows 98 (4.10.1998) MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Subject: Routing with same subnet? Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG My first shot at routing. I saw many questions and responses in the archives, but there are still things I don't understand. What I am trying to do is to setup my FreeBSD box as a Firewall. The setup: Computers-->hub1 -->ed0 -->FBSD -->de0 -->DSL Router -->Internet IP Addresses: Computers 216.44.153.70 to 216.44.153.72 router 216.44.153.65 de0 216.44.153.66 ed0 216.44.153.67 netmask 255.255.255.240 The FreeBSD, 2.2.7, can see the internet through de0. The problem I am having is with the computers not seeing FreeBSD through ed0. The output of netstat is: Internet: Destination Gateway Flags Refs Use Netif Expire default 216.44.153.65 UGSc 11 108 de0 localhost localhost UH 11 469 lo0 216.44.153/28 localhost UGSc 0 0 de0 => 216.44.153 link#2 UCSc 0 0 216.44.153.64/28 link#1 UC 0 0 216.44.153.65 0:0:c5:71:cb:ac UHLW 12 0 de0 1182 75ml localhost UGHS 1 26 lo0 => 75ml/32 0:c0:f0:21:14:45 ULS2c 0 0 lo0 localhost localhost UGHS 1 0 lo0 => 216.44.153.67/32 0:e0:29:40:e8:ae ULS2c 0 0 de0 216.44.153.70 link#1 UHLW 1 396 216.44.153.79 ff:ff:ff:ff:ff:ff UHLSb 4 318 de0 I tried several route lines such as: route add net 216.44.153.0 216.44.153.67 route add net 216.44.153.0 216.44.153.67 -netmask 255.255.255.240 route add 216.44.153.70 216.44.153.67 Based on what I read on the archives it seemed as if it would not be possible to route between the two interfaces with the addresses I am using (216.44.153.67 and 216.44.153.66), but the man page for route has: "In a change or add command where the destination and gateway are not sufficient to specify the route (as in the ISO case where several interfaces may have the same address), the -ifp or -ifa modifiers may be used to de-termine the interface or interface address." From that it seems it may be possible, however I tried adding "-ifp 2" and that didn't help. Also tried "-ifa 216.44.153.67". Both did not give errors but didn't work either. Will I need to change to/add a different IP address to one of the cards? I don't mind if the internal card, ed0, has a non-routable IP such as 10.0.0.1. How about the internal computers? Will they need to be switched to the 10.0.0.0 subnet? Did I miss something in the syntax of the "ifp", "ifa" switches? To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message