TCP/IP, Connecting LANs

Tom Kelliher, CS 318

Feb. 23, 2000



Collect project 1.

Why perl and sockets?


Remember reading: Chs. 1--10, 14--16.

From Last Time

OSI Layers.


  1. Introduction to TCP/IP.

  2. LANs, connecting LANs.

Coming Up

Socket programming.

Introduction to TCP/IP

Message transmission example:



  1. Minimize cost.

  2. Have high reliability.


  1. Point-To-Point networks.
    1. connections --- expensive.

    2. Does not scale well.

    3. Used for long-haul networks.

  2. LANs: a shared communication medium.

  3. Principle of locality: temporal, physical/spatial.

LAN Topologies

  1. Star: what you have with a hub.

    Hub broadcasts everything.

  2. Ring.

    Nodes on a ring retransmit data.

  3. Bus.

    How can a star be a bus?


  1. Shared bus.

  2. Speeds: 10 Mbps, 100 Mbps, gigabit.

  3. CSMA --- ``carrier'' sense multiple access. Listen before transmitting. Idle.

  4. CD --- collision detection. Listen to what you've transmitted.

  5. Binary exponential backoff. Upon collision, wait for up to d time units, randomly chosen, before retransmitting.

    The exponential part.

IBM Token Ring

  1. What is a token?

  2. How do I transmit on the token ring?

  3. ``Pass'' nodes.

  4. How do I receive? How do I know it's for me?

    Why is this efficient: Layering. The NIC is responsible for determining which host a message is for, etc., not the CPU.

  5. Transmitter can do error detection.

``Gluing'' LANs Together

Two connected segments:


  1. Physical layer devices. Amplify, retime (?) the signal.

  2. Connected segments in same collision domain: length restrictions.

  3. Forwards everything: noise, damaged frames, frames not destined for the other segment, etc.


  1. Data link layer.

  2. Connected segments in unique collision domains.

  3. Completely reads a frame from one segment, then transmits it to other segment.

  4. Bridged hosts don't know they're bridged. Buffering?

  5. ``Learning'' bridges forward frames only when necessary, after learning the hosts on each segment.

  6. A switch is like a hub, but each host is on its own segment:

  7. One topology: switch --- hubs --- hosts.


  1. Network layer.

  2. Connected segments may differ in: media, physical addressing, frame format.

Host Addressing: IP Addresses



  1. Data
  2. Application layer
  3. TCP/UDP layer --- TCP frame
  4. IP layer --- IP datagram
  5. Ethernet layer --- ethernet frame: 46--1500 bytes (MTU)


Process Communication

How do processes on separate machines communicate?

Thomas P. Kelliher
Tue Feb 22 19:04:44 EST 2000
Tom Kelliher