A Single Network

If A wants to talk to B, well, they're on the same network, so A addresses the packet directly to B: Simple 192.168.1.0/24 network with two hosts A (192.168.1.1) and B (192.168.1.2)

So "A" can send a packet to "B" like this:

Source IP192.168.1.1(A)
Destination IP192.168.1.2(B)
DataHello B! This is the Data

Unfortunately, it's not as simple as that. The IP address identifies the machines at a software (logical) level, but the physical (MAC) layer isn't the same as the logical (IP) layer.
  • The IP layer needs to be able to route from Alaska to Zebediela. It works at a relatively high level.
  • The MAC layer only needs to talk to machines on the local network (LAN). It works at a low level.

Source IP192.168.1.1(A)
Source MAC01:C0:F2:69:31:21(A)
Destination IP192.168.1.2(B)
Destination MAC03:A0:B3:27:A2:2E(B)
DataHello B! This is the Data

So how does A find out what B's MAC address is?

Networking Tutorial
Share on Twitter Share on Facebook Share on LinkedIn Share on Identi.ca Share on StumbleUpon

Want to take the tutorial with you?

My Shell Scripting Book:
    Shell Scripting, Expert Recipes for Linux, Bash and more
is available online and from all good booksellers.

Buy my 564-page Shell Scripting Book...

From Amazon USA:

From Amazon UK:

For Kindle:

Or From other retailers

You can also find the book, and join a shell scripting community, on Facebook:


Option Two: Buy the 70-page PDF (£4.99/$9.99/€6.99)
(Free Sample)

And you can always Download my Free Shell Scripting Cheatsheet PDF