LinuxSA Mailing list archives
Index:
[thread]
[date]
[subject]
[author]
From: Richard Sharpe <sharpe@ns.aus.com>
To : linuxsa@linuxsa.org.au
Date: Wed, 07 Apr 1999 16:39:39 +0900
Re: Duplicate MAC addresses
Hi,
I had asked about duplicate MAC addresses.
This was basically a case of engaging mouth before putting brain in to gear
and I can only cite tiredness ... :-(
As usually happens, the answer came to me in the shower, but we received
two good answers that I think would be very useful to many people out
there. One from Mark Newton and the other from Matthew Tippett.
Another interesting note came from Glen Turner, who pointed out (another
reason) that duplicate MAC addresses are a bad idea. In a DHCP evironment,
the DHCP server may not be able to distinguish between the two addresses,
and one may end up without an IP address. This of course only relates to
duplicate MAC addresses separated by one or more routers.
This would seem to depend on the DHCP server implementation. A DHCP server
has access to the giaddr field which is filled in by the DHCP/BOOTP relay,
so theoretically, the server could say:
Ah, here is a DISCOVER from 11:22:33:44:55:66 from subnet a.b.c.d
Ah, here is a DISCOVER from 11:22:33:44:55:66 from subnet e.f.g.h
I'm not confused, no way :-)
I guess I will have to check with Ted Lemon as to what the ISC DHCP server
does in the face of this. Of course, I could look at the code :-)
I have included Matthew's response because it bears a strong resemblance to
an explanation I give during the TCP/IP courses I give. The interesting
snippet about what Slow^H^H^H^HSolaris (I assume) does was a bonus.
It also illustrates a pedagogic method I think has strong value, which is
worked examples and detailed, step-by-step answers, which both Matthew and
Mark did.
And to think, neither of them expected to be paid for their expertise (I
hope :-).
At 02:09 AM 4/7/99 +0930, Matthew Tippett <mtippett@ticons.com.au> wrote:
>> 2. Duplicate MAC addresses on different segments separated by a router:
>>
>> 11:22:33:44:55:66 11:22:33:44:55:66
>> -----------------[Router]------------------
>>
>
>As it turns out, dual homed Sun systems do exactly this. Present the
>MAC address to be *precisely* the same on either network. This is
>irrespective of whether the machine is packet forwarding or not.
>
>Taken from 'arp -a' from a Sun box at work.
>
>hme0 gols 255.255.255.255 SP 08:00:20:95:e3:ed
>hme1 gols-dmz 255.255.255.255 SP 08:00:20:95:e3:ed
>hme0 10.55.32.2 255.255.255.255 00:e0:1e:34:b1:f1
>
>
>Two different interfaces on different networks, with the *same* MAC
>address.
>
>The interesting thing is how IP on Ethernet routes. The IP layer
>and above stays almost exactly the same no matter where on the network
>the two communicating hosts are.
>
>When the routing logic decides that the remote host is not local (and
>hence doesn't have a local MAC address) it uses the gateway machines MAC
>address in the packet, effectively presenting the gateway with a packet
>that contains the IP information for a remote host, but addressed MAC wise
>to the gateway.
>
>If the router finds that the host is on one of the joining networks, it will
>then place the hosts MAC address in the packet and send it to the recepient
>host.
>
>Using a worked example... I will use the following definitions for the hosts.
>
> Host A - hme0 - 10.0.0.2 - 08:00:20:95:e3:ed
> - hme1 - 10.0.1.2 - 08:00:20:95:e3:ed
> Host B - hme0 - 10.0.0.3 - 08:00:20:95:e3:ef
> - hme1 - 10.0.1.3 - 08:00:20:95:e3:ef
> Router - if0 - 10.0.0.1 - 08:00:20:95:e3:ee
> - if1 - 10.0.1.1 - 08:00:20:95:e3:ee
>
>A packet will be simplified as IP/MAC as 0.2/e3:ed. Shorthand for
>host/interface will be A0 = Host A, hme0
>
>The router is present on both networks. Both networks have the same
>interface names on them.
>
>a0 talking to b0
>
>1) a0 is on the same network as b0, so the packet becomes
>
> Source = 0.2/e3:ed Destination - 0.3/e3:ef
>
> One hop!
>
>a0 talking to b1
>
>1) a0 not on b1's network. hence a0 must use the router's if0.
>
> Source = 0.2/e3:ed Destination - 1.3/e3:ee
>
>2) router gets the packet and then forwards it to b1 through if1.
>
> Source = 0.2/e3:ee Destination - 1.3/e3:ef
>
>So as you can see the MAC address changes, while the IP address stays the
same,
>depending on the interface that the devices are talking to they are still
>distinct hosts and addresses.
>
>Probably clear as mud now :)
>
>Regards,
>
>Matt
>--
>Matthew Tippett - +61 416 006 047 - mtippett@ticons.com.au
>Linux Support Initiative - BETA Testers Wanted - http://lsi.ticons.com.au/
>Tippett Information Consulting Pty Ltd - - http://www.ticons.com.au/
>
Regards
-------
Richard Sharpe, sharpe@ns.aus.com, NIC-Handle:RJS96
NS Computer Software and Services P/L,
Ph: +61-8-8281-0063, FAX: +61-8-8250-2080,
Samba (Team member), Linux, Apache, Digital UNIX, AIX, C, ...
--
Check out the LinuxSA web pages at http://www.linuxsa.org.au/
To unsubscribe from the LinuxSA list:
mail linuxsa-request@linuxsa.org.au with "unsubscribe" as the subject
Index:
[thread]
[date]
[subject]
[author]
Return to the LinuxSA Mailing List Information Page