*BSD News Article 58326


Return to BSD News archive

Path: euryale.cc.adfa.oz.au!newshost.anu.edu.au!harbinger.cc.monash.edu.au!news.bhp.com.au!mel.dit.csiro.au!munnari.OZ.AU!spool.mu.edu!howland.reston.ans.net!newsfeed.internetmci.com!iglou!heathers.stdio.com!usenet
From: risner@stdio.com
Newsgroups: comp.unix.bsd.freebsd.misc
Subject: Re: FreeBsd as a router?
Date: 6 Jan 1996 16:52:15 GMT
Organization: Image Tech Computing
Lines: 113
Message-ID: <4cm9bv$8hn@heathers.stdio.com>
References: <4cccj1$epp@macs.mxim.com> <4cej27$lha@spock.dis.cccd.edu>
Reply-To: risner@stdio.com
NNTP-Posting-Host: os2
X-Newsreader: IBM NewsReader/2 v1.2

In <4cej27$lha@spock.dis.cccd.edu>, mpeer@cccd.edu (Michael S. Peer) writes:
>In article <4cccj1$epp@macs.mxim.com>, michaele@mxim.com says...
>
>This is about the same thing I am trying to do.  Please let me know if you 
>have any success, or response back via e-mail at mpeer@cccd.edu.
>
>I have had success with gateD from merit, its in the packages section of 
>2.0.5 version 3.5a10 and 2.1.0 version 3.5a11 with ethernet cards.

Question, are you running MORE THAN one line to a network?
Like TWO routers downstream from you that can get to a network?
If you are *NOT* you do not need or want routed or gated.
iijppp with the link up commands will do it all for you automactially.
It will respond FASTER than *d and it will be more reliable.

You need gated or routed when your doing:
net1    -------        net2        ------        net3
      \----------------------------------/

net1 can get to net3 via net2 or net3.
net2 can get to ... 
and so on.

>My host has 2 ethernet cards, and 4 modems.  I am trying to get iijppp to 
>route to my lan at home, no success so far.  Static routes don't seem to 
>help much, but I have never been very good at static routes.
>
>Hope this might help some, if I figure out anything I'll e-mail you back.
>

Below is a big description of how to start a FreeBSD router for 4 lines
on as little as a 386-40, 4 meg ram, 60 meg drive, ed0 ether, 4 serial cards.

If this does not help, email me your config files and a detail plan of desire
support.  DO NOT email me phone numbers or passwords (change to 555-9999
and password or whatever)
I will try to aid.

>Hope this might help some, if I figure out anything I'll e-mail you back.
>

Ok, I don't quite understand what your setup is like, but I do know that FreeBSD
works great as a router at least in my case.

Internet<->FreeBSD (386/40, 4 meg ram, 60 meg MFM drive, ed0, 4 serial modems)

4 dial up lines used for uucp and PPP.
3 dedicated PPP links, 1 uucp/PPP line.

Ok here goes:
Do a kernel with as little as possible.
I have GATEWAY, FFS, INET, MATH_EMU, PROCFS, COMPAT43
psuedos
loop, ether, log, tun 5, pty 8, bpf 8

do /etc/rc.serial for your ports.
do /etc/resolv.conf
do /etc/inetd.conf (I only have telnetd and the internals)

make modems work for login.
edit sysconfig for tun devices.
ifconfig="tun0 inet blah blah2"

Tun devices are not tied to any tty.
I have tested clients with rlogin from another machine when I had only 3 modems.

If your doing single IP PPP for someone, add a arp publish to /etc/netstart.

If your like me edit /etc/monthly to NOT DELETE wtmp.

set up ppp.* in /etc/ppp
MAKE SURE YOU ADD A ppp.secret if you use PPP in AUTO mode.
Otherwise anyone in the world can modify ppp settings.

You need .conf, .secret, .linkup.
you do not need to define which tun device it is using.
But you do need to define a set ifaddr which is the same as a configured tun
device, OR leave a few undefined tun devices for use here (If you have 10 lines
and 100 users; this works as long as the devices is not active.)

Server side done.

Your modems have to:
1) lock DTE speed at a specified speed.
2) hang up on DTR lose and reset.
3) drop CD on DTR lose or hang up.
4) if 14.4 lock port speed at 19200.
5) if 28.8 lock port speed at 38400.

iijppp by DEFAULT uses both vj header and pred1 compression.
So you don't need your port lock at 115.2K to get speed as long as the other
machine supports PRED1.

Once your up telnet to localhost 3000 (or 3001 or what ever 3000+tunvalue is)
give the password.
do "show ccp" and it will say if PRED1 is enable.
You need it on both my proto and his proto.
Otherwise lock ports to 115.2K and be done.

To set up a client.
Have in their /etc/rc.local:
ppp -auto world
define /etc/ppp/ppp.conf with world to call you and log in.
You either:
1) create a PPP shell in C or perl that "exec /usr/sbin/ppp -direct $loginid"
2) give then shell access and make then do in their scripts the above exec.

Your done.
Good luck.

The only UN*X which NEEDS special documentation is LINUX!
Long live V7; Skip Solaris 2.x; FreeBSD IS the PC UN*X