Date: Sat, 11 Apr 1998 08:37:20 +0200 From: "D. Rock" <rock@cs.uni-sb.de> To: Arve Ronning <arve.ronning@ah.telia.no> Cc: freebsd-isdn@FreeBSD.ORG Subject: Re: I4B & NAT Message-ID: <352F0FA0.97AB9019@cs.uni-sb.de> References: <352C2290.6FD4@ah.telia.no>
next in thread | previous in thread | raw e-mail | index | archive | help
Arve Ronning wrote: > > Trying to build a router/gateway between my privat Ethernet and > the Internet (via my ISP), I have problems with I4B or NAT (I think:). > > The 2.2.5-R kernel with options IPFIREWALL and IPDIVERT works fine > with ISDN4BSD 0.50-alpha and firewall rule 'pass all from any to any'. > However, when I add 'divert natd all from any to any via isppp0' > and start natd, name server lookups to the ISP's NS don't work. > > Also, ping and nslookup fails from any other internal host. I had exactly the same problems. natd doesn't seem to get a message if the IP address of the interface changes (after successful dialout). I have to manually send a HUP signal to natd. I do this via the following (ugly?!) hack: I added the following two lines to the system section of isdnd.rc: regexpr = "call active" # look for matches in log messages regprog = hup_natd # execute program whan match is found The small script "hup_natd", located in /etc/isdn, looks like: #!/bin/sh pid=`cat /var/run/natd.pid` kill -HUP $pid sleep 3 kill -HUP $pid sleep 5 kill -HUP $pid It looks ugly, but at least for me it works. The two sleeps are necessary since I have to wait for ppp negotiation to complete (I don't get a message from isdnd for that). If I'm lucky I have my connection after 3 seconds, but 8 seconds should suffice for worst case (the first HUP without a sleep sometimes even succeeded on an slow 486/33 with 8MB RAM, more HUPs don't hurt). I'm really interested in some more elegant method. Daniel To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-isdn" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?352F0FA0.97AB9019>