From owner-freebsd-questions Wed Nov 8 8:58:25 2000 Delivered-To: freebsd-questions@freebsd.org Received: from mail9.wlv.netzero.net (mail9.wlv.netzero.net [209.247.163.66]) by hub.freebsd.org (Postfix) with SMTP id E445637B4C5 for ; Wed, 8 Nov 2000 08:58:19 -0800 (PST) Received: (qmail 15278 invoked from network); 8 Nov 2000 16:58:13 -0000 Received: from dialup-209.245.197.52.houston1.level3.net (HELO surface.ee.uh.edu) (209.245.197.52) by mail9.wlv.netzero.net with SMTP; 8 Nov 2000 16:58:13 -0000 Message-ID: <3A0947A5.61DFFFBF@surface.ee.uh.edu> Date: Wed, 08 Nov 2000 12:31:33 +0000 From: Qiang Xu X-Mailer: Mozilla 4.72 [en] (Win98; U) X-Accept-Language: en,pdf MIME-Version: 1.0 To: freebsd-questions@FreeBSD.ORG Subject: make a PC work as a router Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Dear Sir/Madam: I have a question about how to make a PC work as a router. I want to setup a lab to observe TCP. The lab figure is as following. Here is a private network. box1.lab<======> router.lab <======> box2.lab box1,2 has a NIC each ; router.lab has 2 NICs, router.lab will work as a router. I do something at the rc.conf. I add lab.conf at the end. following the lab.conf file #!/bin/sh #--------------------------------------------- # This file initialize the network in the lab #--------------------------------------------- case ${hostname} in box1.lab) network_interfaces="ep0 lo0 vr0" ifconfig_vr0="inet 192.168.10.2 netmask 255.255.255.0" static_routes="r0" route_r0="net 192.168.20.0 192.168.10.1 netmask 255.255.255.0" ;; router.lab) network_interfaces="ep0 lo0 vr0 vr1" ifconfig_vr0="inet 192.168.10.1 netmask 255.255.255.0" ifconfig_vr1="inet 192.168.20.1 netmask 255.255.255.0" ;; box2.lab) network_interfaces="ep0 lo0 vr0" ifconfig_vr0="inet 192.168.20.2 netmask 255.255.255.0" static_routes="r0" route_r0="net 192.168.10.0 192.168.20.1 netmask 255.255.255.0" ;; esac I can ping itself in each PC now. but I can not ping the router from box1 and box2, neither ping from router to box1,2. When I ping from box1 to router, there is always a message "host is down". The networkline and NICs are OK. Could you give me some advice? Xu, Qiang Subject: how to make a PC act as a router? Date: Wed, 08 Nov 2000 01:46:06 +0000 From: Qiang Xu To: freebsd-questions@FreeBSD.ORG Dear Sir/Madam: I have a question about how to make a PC work as a router. I want to setup a lab to observe TCP. The lab figure is as following. Here is a private network. --------- --------- --------- # | | | | | | # | a |<======>| r |<======> | b | # | | 1 | | 2 | | # --------- --------- --------- box1.lab router.lab box2.lab a,b has a NIC; r has 2 NICs, r will work as a router. I do something at the rc.conf. I add lab.conf at the end. following the lab.conf file #!/bin/sh #--------------------------------------------- # This file initialize the network in the lab #--------------------------------------------- case ${hostname} in box1.lab) network_interfaces="ep0 lo0 vr0" ifconfig_vr0="inet 192.168.10.2 netmask 255.255.255.0" static_routes="r0" route_r0="net 192.168.20.0 192.168.10.1 netmask 255.255.255.0" ;; router.lab) network_interfaces="ep0 lo0 vr0 vr1" ifconfig_vr0="inet 192.168.10.1 netmask 255.255.255.0" ifconfig_vr1="inet 192.168.20.1 netmask 255.255.255.0" ;; box2.lab) network_interfaces="ep0 lo0 vr0" ifconfig_vr0="inet 192.168.20.2 netmask 255.255.255.0" static_routes="r0" route_r0="net 192.168.10.0 192.168.20.1 netmask 255.255.255.0" ;; esac I can ping itself in each PC now. but I can not ping the router from box1 and box2, neither ping from router to box1,2. The networkline and NICs are OK. Could you give me some advice? Xu, Qiang _____NetZero Free Internet Access and Email______ http://www.netzero.net/download/index.html To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message