routing confusion on home network
Kevin O'Connor
kevin at ziptek-technologies.co.uk
Tue Mar 15 20:39:54 GMT 2005
This is a multi-part message in MIME format.
------=_NextPart_000_0012_01C5299F.27808480
Content-Type: text/plain;
charset="us-ascii"
Content-Transfer-Encoding: 7bit
Nicely put Lee that is indeed the reason. Can I please have several glasses
of whatever type of beer you're drinking :-)
Kel
The Netgear will have a default route to the public IP connection, it cannot
build a routing table to different subnets( you can only get away with stuff
like that on layer3 or better switches which learn routes via RIP or OSPF)
Unless it's a typo the Gentoo Linux PC (eth0: 192.168.5.2, default route:
192.168.5.1) should read
Gentoo Linux PC (eth0: 192.168.5.2, default route: 192.168.5.3)
As the 192.168.5.3 interface on the FreeBSD box is the gateway not the ADSL
4-port modem/router.
You also wonder about the Network/sub-net setup. These terms date back to
the early days of TCP/IP when splitting a class A, B or C network up into
smaller sub-nets was impossible. hence terms like Class A network. However
with the introduction of more advanced network masking (CIDR) it became
possible to split up these standard networks into smaller (Sub Net)
segments. As a point of interest it also became possible to join several
Class C networks into a single Class B network (Super net) So the term
Network, subnet and supernet are, from a routing point of view, the same
thing.
I'd be curious to know why you have this particular setup.
Regards
Kevin
>-----Original Message-----
>From: freebsd-users-admin at uk.freebsd.org [mailto:freebsd-users-
>admin at uk.freebsd.org] On Behalf Of Lee Brotherston
>Sent: 15 March 2005 14:37
>To: kel at orawia.com
>Cc: freebsd-users at uk.freebsd.org
>Subject: Re: routing confusion on home network
>
>Kel Graham wrote:
>> ah.. solved it by judicious use of NAT. Why does FreeBSD say it routes
>> between interfaces with a simple "gateway_enable='YES'", when for me this
>> wasn't the case? Was it because I have two separate networks, and not
>just
>> different subnets?
>
>Hi Kel,
>
>I suspect that the FreeBSD box was infact routing the traffic fine,
>however the netgear router had no routes for 192.168.5.0/24 to enable
>the return traffic back (a tcpdump should confirm this). It would need
>a gateway of 192.168.0.26 setting for any 192.168.5.0/24 traffic in the
>router. Using NAT means that the traffic used the address of the
>interface on the FreeBSD machine which the router could route too by
>virtue of being on the same subnet.
>
>Wow, did I just type that after beer? :)
>
> Lee
>
>------ FreeBSD UK Users' Group - Mailing List ------
>http://listserver.uk.freebsd.org/mailman/listinfo/freebsd-users
------=_NextPart_000_0012_01C5299F.27808480
Content-Type: text/html;
charset="us-ascii"
Content-Transfer-Encoding: quoted-printable
<html xmlns:o=3D"urn:schemas-microsoft-com:office:office" xmlns:w=3D"urn:sc=
hemas-microsoft-com:office:word" xmlns:st1=3D"urn:schemas-microsoft-com:off=
ice:smarttags" xmlns=3D"http://www.w3.org/TR/REC-html40">
<head>
<META HTTP-EQUIV=3D"Content-Type" CONTENT=3D"text/html; charset=3Dus-ascii">
<meta name=3DProgId content=3DWord.Document>
<meta name=3DGenerator content=3D"Microsoft Word 11">
<meta name=3DOriginator content=3D"Microsoft Word 11">
<link rel=3DFile-List href=3D"cid:filelist.xml at 01C5299F.24C423A0">
<o:SmartTagType namespaceuri=3D"urn:schemas-microsoft-com:office:smarttags"
name=3D"country-region"/>
<o:SmartTagType namespaceuri=3D"urn:schemas-microsoft-com:office:smarttags"
name=3D"place"/>
<!--[if gte mso 9]><xml>
<o:OfficeDocumentSettings>
<o:DoNotRelyOnCSS/>
</o:OfficeDocumentSettings>
</xml><![endif]--><!--[if gte mso 9]><xml>
<w:WordDocument>
<w:Zoom>BestFit</w:Zoom>
<w:DisplayBackgroundShape/>
<w:SpellingState>Clean</w:SpellingState>
<w:GrammarState>Clean</w:GrammarState>
<w:DocumentKind>DocumentEmail</w:DocumentKind>
<w:EnvelopeVis/>
<w:ValidateAgainstSchemas/>
<w:SaveIfXMLInvalid>false</w:SaveIfXMLInvalid>
<w:IgnoreMixedContent>false</w:IgnoreMixedContent>
<w:AlwaysShowPlaceholderText>false</w:AlwaysShowPlaceholderText>
<w:Compatibility>
<w:BreakWrappedTables/>
<w:SnapToGridInCell/>
<w:WrapTextWithPunct/>
<w:UseAsianBreakRules/>
<w:UseWord2002TableStyleRules/>
</w:Compatibility>
<w:BrowserLevel>MicrosoftInternetExplorer4</w:BrowserLevel>
</w:WordDocument>
</xml><![endif]--><!--[if gte mso 9]><xml>
<w:LatentStyles DefLockedState=3D"false" LatentStyleCount=3D"156">
</w:LatentStyles>
</xml><![endif]--><!--[if !mso]>
<style>
st1\:*{behavior:url(#default#ieooui) }
</style>
<![endif]-->
<style>
<!--
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{mso-style-parent:"";
margin:0cm;
margin-bottom:.0001pt;
mso-pagination:widow-orphan;
font-size:12.0pt;
font-family:"Times New Roman";
mso-fareast-font-family:"Times New Roman";}
a:link, span.MsoHyperlink
{color:blue;
text-decoration:underline;
text-underline:single;}
a:visited, span.MsoHyperlinkFollowed
{color:purple;
text-decoration:underline;
text-underline:single;}
p.MsoPlainText, li.MsoPlainText, div.MsoPlainText
{margin:0cm;
margin-bottom:.0001pt;
mso-pagination:widow-orphan;
font-size:10.0pt;
font-family:"Courier New";
mso-fareast-font-family:"Times New Roman";}
span.SpellE
{mso-style-name:"";
mso-spl-e:yes;}
span.GramE
{mso-style-name:"";
mso-gram-e:yes;}
@page Section1
{size:612.0pt 792.0pt;
margin:72.0pt 77.95pt 72.0pt 77.95pt;
mso-header-margin:35.4pt;
mso-footer-margin:35.4pt;
mso-paper-source:0;}
div.Section1
{page:Section1;}
-->
</style>
<!--[if gte mso 10]>
<style>
/* Style Definitions */=20
table.MsoNormalTable
{mso-style-name:"Table Normal";
mso-tstyle-rowband-size:0;
mso-tstyle-colband-size:0;
mso-style-noshow:yes;
mso-style-parent:"";
mso-padding-alt:0cm 5.4pt 0cm 5.4pt;
mso-para-margin:0cm;
mso-para-margin-bottom:.0001pt;
mso-pagination:widow-orphan;
font-size:10.0pt;
font-family:"Times New Roman";
mso-ansi-language:#0400;
mso-fareast-language:#0400;
mso-bidi-language:#0400;}
</style>
<![endif]-->
</head>
<body lang=3DEN-US link=3Dblue vlink=3Dpurple style=3D'tab-interval:36.0pt'>
<div class=3DSection1>
<p class=3DMsoNormal><font size=3D3 face=3D"Times New Roman"><span style=3D=
'font-size:
12.0pt'><o:p> </o:p></span></font></p>
<p class=3DMsoNormal><font size=3D2 face=3D"Courier New"><span style=3D'fon=
t-size:10.0pt;
font-family:"Courier New"'>Nicely put Lee that is indeed the reason. Can I
please have several glasses of whatever type of beer you're drinking :<span
class=3DGramE>-)</span><o:p></o:p></span></font></p>
<p class=3DMsoNormal><font size=3D2 face=3D"Courier New"><span style=3D'fon=
t-size:10.0pt;
font-family:"Courier New"'><o:p> </o:p></span></font></p>
<p class=3DMsoNormal><span class=3DSpellE><font size=3D2 face=3D"Courier Ne=
w"><span
style=3D'font-size:10.0pt;font-family:"Courier New"'>Kel</span></font></spa=
n><font
size=3D2 face=3D"Courier New"><span style=3D'font-size:10.0pt;font-family:"=
Courier New"'><o:p></o:p></span></font></p>
<p class=3DMsoNormal><font size=3D2 face=3D"Courier New"><span style=3D'fon=
t-size:10.0pt;
font-family:"Courier New"'>The <span class=3DSpellE>Netgear</span> will hav=
e a
default route to the public IP connection, it cannot build a routing table =
to
different <span class=3DGramE>subnets(</span> you can only get away with st=
uff
like that on layer3 or better switches which learn routes via RIP or OSPF)<=
o:p></o:p></span></font></p>
<p class=3DMsoPlainText><font size=3D2 face=3D"Courier New"><span style=3D'=
font-size:
10.0pt'>Unless it's a typo the <span class=3DSpellE>Gentoo</span> Linux PC =
(eth0:
192.168.5.2, default route: 192.168.5.1) should read<o:p></o:p></span></fon=
t></p>
<p class=3DMsoPlainText><span class=3DSpellE><font size=3D2 face=3D"Courier=
New"><span
style=3D'font-size:10.0pt'>Gentoo</span></font></span> Linux PC (eth0:
192.168.5.2, default route: 192.168.5.3) <o:p></o:p></p>
<p class=3DMsoPlainText><font size=3D2 face=3D"Courier New"><span style=3D'=
font-size:
10.0pt'>As the 192.168.5.3 interface on the FreeBSD box is the gateway not =
the ADSL
4-port modem/router. <o:p></o:p></span></font></p>
<p class=3DMsoPlainText><font size=3D2 face=3D"Courier New"><span style=3D'=
font-size:
10.0pt'>You also wonder about the Network/sub-net setup. These terms date b=
ack
to the early days of TCP/IP when splitting a class A, B or C network up into
smaller sub-nets was impossible. <span class=3DGramE>hence</span> terms like
Class A network. However with the introduction of more advanced network mas=
king
(CIDR) it became possible to split up these standard networks into smaller =
(Sub
Net) segments. As a point of interest it also became possible to join sever=
al
Class C networks into a single Class B network (Super net) <span class=3DGr=
amE>So</span>
the term Network, subnet and <span class=3DSpellE>supernet</span> are, from=
a
routing point of view, the same thing.<o:p></o:p></span></font></p>
<p class=3DMsoPlainText><font size=3D2 face=3D"Courier New"><span style=3D'=
font-size:
10.0pt'><o:p> </o:p></span></font></p>
<p class=3DMsoPlainText><font size=3D2 face=3D"Courier New"><span style=3D'=
font-size:
10.0pt'>I'd be curious to know why you have this particular setup.<o:p></o:=
p></span></font></p>
<p class=3DMsoPlainText><font size=3D2 face=3D"Courier New"><span style=3D'=
font-size:
10.0pt'><o:p> </o:p></span></font></p>
<p class=3DMsoPlainText><font size=3D2 face=3D"Courier New"><span style=3D'=
font-size:
10.0pt'>Regards<o:p></o:p></span></font></p>
<p class=3DMsoPlainText><font size=3D2 face=3D"Courier New"><span style=3D'=
font-size:
10.0pt'>Kevin <o:p></o:p></span></font></p>
<p class=3DMsoPlainText><font size=3D2 face=3D"Courier New"><span style=3D'=
font-size:
10.0pt'><o:p> </o:p></span></font></p>
<p class=3DMsoPlainText><font size=3D2 face=3D"Courier New"><span style=3D'=
font-size:
10.0pt'>>-----Original Message-----</span></font></p>
<p class=3DMsoPlainText><font size=3D2 face=3D"Courier New"><span style=3D'=
font-size:
10.0pt'>>From: freebsd-users-admin at uk.freebsd.org [mailto:freebsd-users-=
</span></font></p>
<p class=3DMsoPlainText><font size=3D2 face=3D"Courier New"><span style=3D'=
font-size:
10.0pt'>>admin at uk.freebsd.org] On Behalf Of Lee Brotherston</span></font=
></p>
<p class=3DMsoPlainText><font size=3D2 face=3D"Courier New"><span style=3D'=
font-size:
10.0pt'>>Sent: 15 March 2005 14:37</span></font></p>
<p class=3DMsoPlainText><font size=3D2 face=3D"Courier New"><span style=3D'=
font-size:
10.0pt'>>To: kel at orawia.com</span></font></p>
<p class=3DMsoPlainText><font size=3D2 face=3D"Courier New"><span style=3D'=
font-size:
10.0pt'>>Cc: freebsd-users at uk.freebsd.org</span></font></p>
<p class=3DMsoPlainText><font size=3D2 face=3D"Courier New"><span style=3D'=
font-size:
10.0pt'>>Subject: Re: routing confusion on home network</span></font></p>
<p class=3DMsoPlainText><font size=3D2 face=3D"Courier New"><span style=3D'=
font-size:
10.0pt'>><o:p> </o:p></span></font></p>
<p class=3DMsoPlainText><font size=3D2 face=3D"Courier New"><span style=3D'=
font-size:
10.0pt'>>Kel Graham wrote:</span></font></p>
<p class=3DMsoPlainText><font size=3D2 face=3D"Courier New"><span style=3D'=
font-size:
10.0pt'>>> ah.. solved it by judicious use of NAT.<span
style=3D'mso-spacerun:yes'> </span>Why does FreeBSD say it routes</sp=
an></font></p>
<p class=3DMsoPlainText><font size=3D2 face=3D"Courier New"><span style=3D'=
font-size:
10.0pt'>>> between interfaces with a simple
"gateway_enable=3D'YES'", when for me this</span></font></p>
<p class=3DMsoPlainText><font size=3D2 face=3D"Courier New"><span style=3D'=
font-size:
10.0pt'>>> wasn't the case? Was it because I have two separate networ=
ks,
and not</span></font></p>
<p class=3DMsoPlainText><font size=3D2 face=3D"Courier New"><span style=3D'=
font-size:
10.0pt'>>just</span></font></p>
<p class=3DMsoPlainText><font size=3D2 face=3D"Courier New"><span style=3D'=
font-size:
10.0pt'>>> different subnets?</span></font></p>
<p class=3DMsoPlainText><font size=3D2 face=3D"Courier New"><span style=3D'=
font-size:
10.0pt'>><o:p> </o:p></span></font></p>
<p class=3DMsoPlainText><font size=3D2 face=3D"Courier New"><span style=3D'=
font-size:
10.0pt'>>Hi Kel,</span></font></p>
<p class=3DMsoPlainText><font size=3D2 face=3D"Courier New"><span style=3D'=
font-size:
10.0pt'>><o:p> </o:p></span></font></p>
<p class=3DMsoPlainText><font size=3D2 face=3D"Courier New"><span style=3D'=
font-size:
10.0pt'>>I suspect that the FreeBSD box was infact routing the traffic f=
ine,</span></font></p>
<p class=3DMsoPlainText><font size=3D2 face=3D"Courier New"><span style=3D'=
font-size:
10.0pt'>>however the netgear router had no routes for 192.168.5.0/24 to
enable</span></font></p>
<p class=3DMsoPlainText><font size=3D2 face=3D"Courier New"><span style=3D'=
font-size:
10.0pt'>>the return traffic back (a tcpdump should confirm this).<span
style=3D'mso-spacerun:yes'> </span>It would need</span></font></p>
<p class=3DMsoPlainText><font size=3D2 face=3D"Courier New"><span style=3D'=
font-size:
10.0pt'>>a gateway of 192.168.0.26 setting for any 192.168.5.0/24 traffi=
c in
the</span></font></p>
<p class=3DMsoPlainText><font size=3D2 face=3D"Courier New"><span style=3D'=
font-size:
10.0pt'>>router.<span style=3D'mso-spacerun:yes'> </span>Using NAT=
means
that the traffic used the address of the</span></font></p>
<p class=3DMsoPlainText><font size=3D2 face=3D"Courier New"><span style=3D'=
font-size:
10.0pt'>>interface on the FreeBSD machine which the router could route t=
oo
by</span></font></p>
<p class=3DMsoPlainText><font size=3D2 face=3D"Courier New"><span style=3D'=
font-size:
10.0pt'>>virtue of being on the same subnet.</span></font></p>
<p class=3DMsoPlainText><font size=3D2 face=3D"Courier New"><span style=3D'=
font-size:
10.0pt'>><o:p> </o:p></span></font></p>
<p class=3DMsoPlainText><font size=3D2 face=3D"Courier New"><span style=3D'=
font-size:
10.0pt'>>Wow, did I just type that after beer? :)</span></font></p>
<p class=3DMsoPlainText><font size=3D2 face=3D"Courier New"><span style=3D'=
font-size:
10.0pt'>><o:p> </o:p></span></font></p>
<p class=3DMsoPlainText><font size=3D2 face=3D"Courier New"><span style=3D'=
font-size:
10.0pt'>><span style=3D'mso-spacerun:yes'> </span>Lee</span>=
</font></p>
<p class=3DMsoPlainText><font size=3D2 face=3D"Courier New"><span style=3D'=
font-size:
10.0pt'>><o:p> </o:p></span></font></p>
<p class=3DMsoPlainText><font size=3D2 face=3D"Courier New"><span style=3D'=
font-size:
10.0pt'>>------ FreeBSD <st1:country-region w:st=3D"on"><st1:place w:st=
=3D"on">UK</st1:place></st1:country-region>
Users' Group<span style=3D'mso-spacerun:yes'> </span>-<span
style=3D'mso-spacerun:yes'> </span>Mailing List ------</span></font><=
/p>
<p class=3DMsoPlainText><font size=3D2 face=3D"Courier New"><span style=3D'=
font-size:
10.0pt'>>http://listserver.uk.freebsd.org/mailman/listinfo/freebsd-users=
</span></font></p>
</div>
</body>
</html>
------=_NextPart_000_0012_01C5299F.27808480--
More information about the Ukfreebsd
mailing list