Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 3 Jun 1996 13:58:22 +1000 (EST)
From:      Paul Sondhu <paul@riker.comcirc.com.au>
To:        questions@freebsd.org
Cc:        freebsd-questions@freebsd.org
Subject:   Using FreeBSD as a gateway between a LAN and the internet
Message-ID:  <Pine.BSF.3.91.960603132515.23125A-100000@riker.comcirc.com.au>

next in thread | raw e-mail | index | archive | help

I am having some troubles in trying to set up FreeBSD as a gateway 
between the internet and a small LAN. 

My Configuration is this - I have a FreeBSD machine which uses PPP 
modem dialup to a xylogics annex terminal server which connects me
to the internet. My FreeBSD machine is on an ethernet LAN with 
Windows 95 client machines.

My FreeBSD machine is configured like this - I use ppp to dialup to the
terminal server, log in, and then I configure the tun0 interface and 
default route as follows.

	ifconfig tun0 203.17.165.101 203.17.165.101 netmask 255.255.255.128	
	route add default 203.17.165.101

	where 203.17.165.101 is the IP address assigned to me by the terminal
	server.

I then configure my ethernet interface in the following way -

	ifconfig ed0 203.17.165.129 netmask 255.255.255.128
	
	where 203.17.165.129 is the IP address I gave to the network card
	on the FreeBSD machine.

As you can see I am subnetting the Class C address's that are assigned to 
us. I am doing this since I am trying to route between two differnet 
physical networks ( my ethernet and dialup line ) and as far as I know in 
order to do this they must be on different subnets. Am I right here????

At this stage, I can connect to the internet OK from my FreeBSD machine 
and I can connect to my FreeBSD machine from my Windows 95 clients, but
I can't connect to the internet from the Windows 95 clients.  The FreeBSD
machine doesnt seem to be routing between my LAN and the internet ( I have
the GATEWAY option enabled in the /etc/sysconfig file ).

What I did next was see if I could ping our terminal server from my win95
client machines. I couldnt. I then connected into our terminal server and
added a route to one of the win95 client machines to see what happened.
( route add 203.17.165.130 255.255.255.255 203.17.165.101 on the annex, 
where 203.17.165.130 is the IP number I assigned to the win95 client ).
I could then ping the terminal server from the client machine and 
vice versa but I still could'nt go past the terminal server.

I was wondering if anyone could help me with this problem.

Regards,

Paul.

-------------------------------------------------------------------------
Paul Sondhu			Email: P.Sondhu@comcirc.com.au       
Computer Circuit Pty. Ltd.	Tel: +61 53 826 959
27 Darlot St.			Fax: +61 53 826 301
Horsham 3400			WWW: http://www.comcirc.com.au/staff/paul	
Victoria Australia
-------------------------------------------------------------------------




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.BSF.3.91.960603132515.23125A-100000>