228 lines
8.5 KiB
HTML
228 lines
8.5 KiB
HTML
<!--startcut ======================================================= -->
|
|
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
|
|
<html>
|
|
<head>
|
|
<META NAME="generator" CONTENT="lgazmail v1.2J.h">
|
|
<TITLE>The Answer Guy 42: New Kernel Loses Ether Driver; Dial on Demand and Masquerading</TITLE>
|
|
</HEAD><BODY BGCOLOR="#FFFFFF" TEXT="#000000"
|
|
LINK="#3366FF" VLINK="#A000A0">
|
|
<!-- ::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: -->
|
|
<H4>"The Linux Gazette...<I>making Linux just a little more fun!</I>"</H4>
|
|
<P> <hr> <P>
|
|
<!-- ::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: -->
|
|
<center>
|
|
<H1><A NAME="answer">
|
|
<img src="../../gx/dennis/qbubble.gif" alt="(?)"
|
|
border="0" align="middle">
|
|
<font color="#B03060">The Answer Guy</font>
|
|
<img src="../../gx/dennis/bbubble.gif" alt="(!)"
|
|
border="0" align="middle">
|
|
</A></H1>
|
|
<BR>
|
|
<H4>By James T. Dennis,
|
|
<a href="mailto:linux-questions-only@ssc.com">linux-questions-only@ssc.com</a><BR>
|
|
LinuxCare,
|
|
<A HREF="http://www.linuxcare.com/">http://www.linuxcare.com/</A>
|
|
</H4>
|
|
</center>
|
|
|
|
<p><hr><p>
|
|
<!-- endcut ======================================================= -->
|
|
<!-- begin 15 -->
|
|
<H3 align="left"><img src="../../gx/dennis/qbubble.gif"
|
|
height="50" width="60" alt="(?) " border="0"
|
|
>New Kernel Loses Ether Driver; Dial on Demand and Masquerading</H3>
|
|
<H4 ALIGN="center">
|
|
A grabbag of user questions.</H4>
|
|
|
|
|
|
<p><strong>From Adams, James on Sun, 02 May 1999
|
|
</strong></p>
|
|
<!-- ::
|
|
New Kernel Loses Ether Driver; Dial on Demand and Masquerading
|
|
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
|
A grabbag of user questions.
|
|
:: -->
|
|
<P><STRONG><IMG SRC="../../gx/dennis/qbub.gif" ALT="(?)"
|
|
HEIGHT="28" WIDTH="50" BORDER="0"
|
|
>
|
|
Answer Guy,
|
|
</STRONG></P>
|
|
<P><STRONG>
|
|
I know you are extrmely busy and such, I hope you can point me in
|
|
the right direction. I am trying to find the tell all instructions
|
|
for recompiling a new kernel for RH5.2 (Mandrake 5.3). I have
|
|
tried repeatedly to do this but still no luck.
|
|
</STRONG></P>
|
|
<P><STRONG>
|
|
The main problem I run into is that my ethernet no longer works
|
|
after booting into the "new" setup. Something about SCIOFLAGS (I
|
|
think), and the network is not working.
|
|
</STRONG></P>
|
|
<BLOCKQUOTE><IMG SRC="../../gx/dennis/bbub.gif" ALT="(!)"
|
|
HEIGHT="28" WIDTH="50" BORDER="0"
|
|
>
|
|
That means that you haven't successfully included the driver
|
|
for your ethernet adapter. You have to know what sort of
|
|
driver it takes. I realize that this is the problem. There
|
|
is no easy way to tell this from a running kernel --- none
|
|
the entries under <TT>/proc</TT> seem to say which ether driver is
|
|
active. You might find your ethernet card mentioned in
|
|
<TT>/proc/pci</TT> (a list of PCI devices recognized by your kernel).
|
|
Otherwise just open the case and look at the actual card
|
|
hardware.
|
|
</BLOCKQUOTE>
|
|
<BLOCKQUOTE>
|
|
One trick I've occasionally used during installfests is an
|
|
ugly hack. I cd to <TT>/lib/modules/preferred/net</TT> (or
|
|
thereabouts) and do something like:
|
|
</BLOCKQUOTE>
|
|
<BLOCKQUOTE><BlockQuote><Code>
|
|
for i in ./*; do insmod $i && echo $i; done
|
|
</Code></BlockQuote></BLOCKQUOTE>
|
|
<BLOCKQUOTE>
|
|
... which tries to load EVERY available module in that
|
|
directory. This could hang the system, but usually it just
|
|
spits out the name(s) of any modules that successfully
|
|
detect a card that they can drive.
|
|
</BLOCKQUOTE>
|
|
<P><STRONG><IMG SRC="../../gx/dennis/qbub.gif" ALT="(?)"
|
|
HEIGHT="28" WIDTH="50" BORDER="0"
|
|
>
|
|
If you could point me in the right direction I would forever be in
|
|
your debt (sort of). I also want to be able to have dial on
|
|
demand, I have a small home network and want to use it with
|
|
ipfwadm.
|
|
</STRONG></P>
|
|
<P><STRONG>
|
|
Thanks
|
|
<br>in Advance
|
|
<br>Jim Adams
|
|
</STRONG></P>
|
|
<BLOCKQUOTE><IMG SRC="../../gx/dennis/bbub.gif" ALT="(!)"
|
|
HEIGHT="28" WIDTH="50" BORDER="0"
|
|
>
|
|
There is a program called '<tt>diald</tt>' which used to be the main
|
|
"dial on demand" daemon (driver). However, I've read that
|
|
the latest versions of PPP have some built in "on demand"
|
|
features.
|
|
</BLOCKQUOTE>
|
|
<BLOCKQUOTE>
|
|
I must admit that I haven't been using modem PPP for the
|
|
last several months. I'm spoiled rotten by my DSL line
|
|
(which as only been down once since I got it). I'd only
|
|
been using POTS PPP occasionally in the last couple of years
|
|
since I was using ISDN (with its own dial-on-demand in my
|
|
Trancell/WebRamp ISDN router) --- so I was only using
|
|
diald/pppd when that was being flaky.
|
|
</BLOCKQUOTE>
|
|
<BLOCKQUOTE>
|
|
However, I've been meaning to play with the new pppd options
|
|
at some point. So I'll look into it.
|
|
</BLOCKQUOTE>
|
|
<BLOCKQUOTE>
|
|
I presume that you mean that you want to use your PPP link
|
|
through IP masquerading (when you say "with ipfwadm").
|
|
There are numerous HOWTOs and numerous back issues of my
|
|
column where I've discussed masquerading. The short form is
|
|
to use the following commands on your router (the Linux box
|
|
with the ethernet the PPP links on it):
|
|
</BLOCKQUOTE>
|
|
<BLOCKQUOTE><BlockQuote><code>
|
|
echo 1 > /proc/sys/net/ipv4/ip_forward
|
|
</code></BlockQuote></BLOCKQUOTE>
|
|
<BLOCKQUOTE>
|
|
(to enable routing)
|
|
</BLOCKQUOTE>
|
|
<BLOCKQUOTE>
|
|
and:
|
|
</BLOCKQUOTE>
|
|
<BLOCKQUOTE><BlockQuote><pre>
|
|
ipfwadm -F -a acc -m -D 0.0.0.0/0 -S 192.168.0.0/16
|
|
ipfwadm -F -a acc -m -D 0.0.0.0/0 -S 10.0.0.0/8
|
|
ipfwadm -F -a acc -m -D 0.0.0.0/0 -S 172.16.0.0/12
|
|
</pre></BlockQuote></BLOCKQUOTE>
|
|
<BLOCKQUOTE>
|
|
(you only need one of these, but all of them won't hurt).
|
|
</BLOCKQUOTE>
|
|
<BLOCKQUOTE>
|
|
This last set of commands adds a set of rules to the Linux
|
|
packet filtering tables to masquerade any source addresses
|
|
in the 192.168.*.*, the 10.*.*.* and the 172.16.*.* through
|
|
172.31.*.* ranges. Those are all of the addressed reserved
|
|
in RFC 1918 for "private" use.
|
|
</BLOCKQUOTE>
|
|
<BLOCKQUOTE>
|
|
As I've discussed before you should also put in some packet
|
|
filtering and anti-spoofing rules to protect your home
|
|
network from outside attack. Crackers and script-kiddies
|
|
are not a myth --- I see probes on my network all the time
|
|
and I've just recently let one of my system get cracked into
|
|
(I was being sloppy with that one --- it's part of why my
|
|
mail was down for a couple of weeks; though only a small
|
|
part).
|
|
</BLOCKQUOTE>
|
|
<!-- sig -->
|
|
|
|
<!-- end 15 -->
|
|
<!--startcut ======================================================= -->
|
|
<P> <hr> <P>
|
|
<H5 align="center"><a href="http://www.linuxgazette.com/copying.html"
|
|
>Copyright ©</a> 1999, James T. Dennis
|
|
<BR>Published in <I>The Linux Gazette</I> Issue 42 June 1999</H5>
|
|
<H6 ALIGN="center">HTML transformation by
|
|
<A HREF="mailto:star@starshine.org">Heather Stern</a> of
|
|
Starshine Techinical Services,
|
|
<A HREF="http://www.starshine.org/">http://www.starshine.org/</A>
|
|
</H6>
|
|
<P> <hr> <P>
|
|
<!-- begin tagnav ::::::::::::::::::::::::::::::::::::::::::::::::::-->
|
|
<TABLE WIDTH="97%"><TR VALIGN="center" ALIGN="center">
|
|
<TD ROWSPAN="4" COLSPAN="1" WIDTH="37%"><A
|
|
HREF="../lg_answer42.html"
|
|
><IMG SRC="../../gx/dennis/answernew.gif"
|
|
ALT="[ Answer Guy Index ]"></A></td>
|
|
<TD WIDTH="10%"><A HREF="1.html">1</A></TD>
|
|
<TD WIDTH="10%"><A HREF="2.html">2</A></TD>
|
|
<TD WIDTH="10%"><A HREF="3.html">3</A></TD>
|
|
<TD WIDTH="10%"><A HREF="4.html">4</A></TD>
|
|
<TD WIDTH="10%"><A HREF="5.html">5</A></TD>
|
|
<TD WIDTH="10%"><A HREF="6.html">6</A></TD>
|
|
</TR><TR VALIGN="center" ALIGN="center">
|
|
<TD><A HREF="7.html">7</A></TD>
|
|
<TD><A HREF="8.html">8</A></TD>
|
|
<TD><A HREF="9.html">9</A></TD>
|
|
<TD><A HREF="10.html">10</A></TD>
|
|
<TD><A HREF="11.html">11</A></TD>
|
|
<TD><A HREF="12.html">12</A></TD>
|
|
</TR><TR VALIGN="center" ALIGN="center">
|
|
<TD><A HREF="13.html">13</A></TD>
|
|
<TD><A HREF="14.html">14</A></TD>
|
|
<TD><A HREF="15.html">15</A></TD>
|
|
<TD><A HREF="16.html">16</A></TD>
|
|
<TD><A HREF="17.html">17</A></TD>
|
|
<TD><A HREF="18.html">18</A></TD>
|
|
</TR><TR VALIGN="center" ALIGN="center">
|
|
<TD><A HREF="19.html">19</A></TD>
|
|
<TD><A HREF="20.html">20</A></TD>
|
|
<TD><A HREF="21.html">21</A></TD>
|
|
<TD><A HREF="22.html">22</A></TD>
|
|
<TD><A HREF="23.html">23</A></TD>
|
|
<TD><A HREF="24.html">24</A></TD>
|
|
</TR></TABLE>
|
|
<!-- end tagnav ::::::::::::::::::::::::::::::::::::::::::::::::::::-->
|
|
<P> <hr> <P>
|
|
<!-- begin lgnav ::::::::::::::::::::::::::::::::::::::::::::::::::: -->
|
|
<A HREF="../../index.html"
|
|
><IMG SRC="../../gx/indexnew.gif" ALT="[ Table Of Contents ]"></A>
|
|
<A HREF="/index.html"
|
|
><IMG SRC="../../gx/homenew.gif" ALT="[ Front Page ]"></A>
|
|
<A HREF="../lg_bytes42.html"
|
|
><IMG SRC="../../gx/back2.gif" ALT="[ Previous Section ]"></A>
|
|
<A HREF="../lg_tips42.html"
|
|
><IMG SRC="../../gx/fwd.gif" ALT="[ Next Section ]"></A>
|
|
<!-- end lgnav ::::::::::::::::::::::::::::::::::::::::::::::::::::: -->
|
|
<!-- ::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: -->
|
|
</BODY></HTML>
|
|
<!--endcut ========================================================= -->
|