Sub Netting - Apjohns0 Ch01-Where We'Ve Been

Embed Size (px)

Citation preview

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    1/50

    Application

    Presentation

    Session

    Transport

    Network

    Data-Link

    Physical

    THE OSI MODEL

    Where Weve Been

    Chapter 1Review

    By: Allan Johnson

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    2/50

    Table of Contents

    Enterprise

    Review the OSI Model

    Encapsulation

    LAN Devices & Technologies

    Transport Layer

    IP Addressing

    Go There!Go There!

    Go There!Go There!

    Go There!Go There!

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    3/50

    A New Word!Enterprise

    A corporation, agency,

    school, or other

    organization that worksto tie together its data,

    communication,

    computing, and file

    servers.

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    4/50

    Your Job as a Network Guru

    Help Enterprises meet their needs by: Interconnecting their LANs so that

    geographically remote services can beaccessed

    Ensuring users get high bandwidth accessover their LANs (i.e. Replacing hubs withswitches; 10Mbps NICs with 10/100 MbpsNICs or Gigabit per second NICs)

    Implementing new technologies as theyemerge like e-commerce, videoconferencing, voice over IP, and distancelearning.

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    5/50

    Application

    Presentation

    Session

    Transport

    Network

    Data-Link

    Physical

    THE OSI MODEL

    Review The Model

    Open SystemsInterconnected Reference

    Model

    Table of Contents

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    6/50

    Why A Layered Model?

    Reduces complexity Standardizes interfaces

    Facilitates modular

    engineering Ensures interoperable

    technology

    Accelerates evolution

    Simplifies teaching &learning

    Application

    Presentation

    Session

    Transport

    Network

    Data-Link

    Physical

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    7/50

    Host Layers vs. Media Layers

    Application

    Presentation

    Session

    Transport

    Network

    Data-Link

    Physical

    Host LayersProvides accuratedata deliverybetween computers

    Application

    Presentation

    Session

    Transport

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    8/50

    Host Layers vs. Media Layers

    Application

    Presentation

    Session

    Transport

    Network

    Data-Link

    Physical

    Media LayersControls physicaldelivery of the messageover the network

    Network

    Data-Link

    Physical

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    9/50

    Application Layer

    Provides network services(processes) to applications.

    For example, a computer ona LAN can save files to aserver using a networkredirector supplied by NOSslike Novell.

    Network redirectors allowapplications like Word andExcel to see the network.

    Application

    Presentation

    Session

    Transport

    Network

    Data-Link

    Physical

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    10/50

    Presentation Layer

    Provides data representationand code formatting.

    Code formatting includescompression and encryption

    Basically, the presentationlayer is responsible forrepresenting data so that the

    source and destination cancommunicate at theapplication layer.

    Application

    Presentation

    Session

    Transport

    Network

    Data-Link

    Physical

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    11/50

    Session Layer

    Provides inter-host communicationby establishing, maintaining, andterminating sessions.

    Session uses dialog control anddialog separation to manage the

    session Some Session protocols:

    NFS (Network File System)

    SQL (Structured Query Language)

    RCP (Remote Call Procedure)

    ASP (AppleTalk Session Protocol)

    SCP (Session Control Protocol)

    X-window

    Application

    Presentation

    Session

    Transport

    Network

    Data-Link

    Physical

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    12/50

    Transport Layer

    Provides reliability, flow control,and error correction through theuse of TCP.

    TCP segments the data, adding aheader with control information

    for sequencing andacknowledging packets received.

    The segment header also includessource and destination ports forupper-layer applications

    TCP is connection-oriented anduses windowing.

    UDP is connectionless. UDP doesnot acknowledge the receipt of

    packets.

    Application

    Presentation

    Session

    Transport

    Network

    Data-Link

    Physical

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    13/50

    Network Layer

    Responsible for logicallyaddressing the packet andpath determination.

    Addressing is done through

    routed protocols such as IP,IPX, AppleTalk, and DECnet.

    Path Selection is done byusing routing protocols such

    as RIP, IGRP, EIGRP, OSPF,and BGP.

    Routers operate at theNetwork Layer

    Application

    Presentation

    Session

    Transport

    Network

    Data-Link

    Physical

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    14/50

    Data-Link Layer

    Provides access to the media

    Handles error notification,network topology issues, andphysically addressing the

    frame.

    Media Access Control througheither...

    Deterministictoken passing Non-deterministicbroadcast

    topology (collision domains)

    Important concept: CSMA/CD

    Application

    Presentation

    Session

    Transport

    Network

    Data-Link

    Physical

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    15/50

    Physical Layer

    Provides electrical,mechanical, procedural andfunctional means foractivating and maintaining

    links between systems. Includes the medium throughwhich bits flow. Media canbe...

    CAT 5 cable Coaxial cable

    Fiber Optics cable The atmosphere

    Application

    Presentation

    Session

    Transport

    Network

    Data-Link

    Physical

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    16/50

    Application

    Presentation

    Session

    Transport

    Network

    Data-Link

    Physical

    THE OSI MODEL

    Encapsulation

    Peer-to-PeerCommunications

    Table of Contents

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    17/50

    Peer-to-Peer Communications

    Peers communicate using the PDU of theirlayer. For example, the network layers of thesource and destination are peers and usepackets to communicate with each other.

    Application Application

    Presentation Presentation

    Session Session

    Transport TransportNetwork Network

    Data-Link Data-Link

    Physical Physical

    Data

    SegmentsPacketsFrames

    Bits

    DataData

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    18/50

    Encapsulation Example

    You type an emailmessage. SMTP takes thedata and passes it to thePresentation Layer.

    Presentation codes thedata as ASCII.

    Session establishes a

    connection with thedestination for the purposeof transporting the data.

    Application

    Presentation

    Session

    Transport

    Network

    Data-LinkPhysical

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    19/50

    Encapsulation Example

    Transport segments thedata using TCP and hands itto the Network Layer foraddressing

    Network addresses thepacket using IP.

    Data-Link then encaps. thepacket in a frame and

    addresses it for localdelivery (MACs)

    The Physical layer sends thebits down the wire.

    Application

    Presentation

    Session

    Transport

    Network

    Data-LinkPhysical

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    20/50

    Application

    Presentation

    Session

    Transport

    Network

    Data-LinkPhysical

    THE OSI MODEL

    LAN Devices &

    TechnologiesThe Data-Link &Physical Layers

    Table of Contents

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    21/50

    Devices

    What does it do? Connects LAN

    segments;

    Filters traffic based

    on MAC addresses;and

    Separates collisiondomains based upon

    MAC addresses.

    What layer device?

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    22/50

    Devices

    What does it do? Since it is a multi-port

    bridge, it can also Connect LAN

    segments;

    Filter traffic based onMAC addresses; and

    Separate collisiondomains

    However, switches

    also offer full-duplex,dedicated bandwidthto segments ordesktops.

    What layer device?

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    23/50

    Devices

    What does it do? Concentrates LAN

    connections frommultiple devices into

    one location Repeats the signal (a

    hub is a multi-portrepeater)

    What layer device?

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    24/50

    Devices

    What does it do? Interconnects networks

    and provides broadcastcontrol

    Determines the path

    using a routing protocolor static route

    Re-encapsulates thepacket in the appropriateframe format and

    switches it out theinterface

    Uses logical addressing(i.e. IP addresses) todetermine the path

    What layer device?

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    25/50

    Media Types

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    26/50

    LAN Technologies

    Three MostCommon UsedToday inNetworking

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    27/50

    Ethernet/802.3

    Cable Specifications: 10Base2

    Called Thinnet; uses coax

    Max. distance = 185 meters (almost 200)

    10Base5 Called Thicknet; uses coax

    Max. distance = 500 meters

    10BaseT Uses Twisted-pair

    Max. distance = 100 meters

    10 means 10 Mbps

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    28/50

    Ethernet/802.3

    Ethernet is broadcast topology. What does that mean?

    Every devices on the Ethernet segment seesevery frame.

    Frames are addressed with source anddestination ______ addresses.

    When a source does not know the destination orwants to communicate with every device, it

    encapsulates the frame with a broadcast MACaddress: FFFF.FFFF.FFFF

    What is the main network traffic problemcaused by Ethernet broadcast topologies?

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    29/50

    Ethernet/802.3

    Ethernet topologies are also sharedmedia.

    That means media access is controlled

    on a first come, first serve basis. This results in collisions between the

    data of two simultaneously transmitting

    devices. Collisions are resolved using what

    method?

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    30/50

    Ethernet/802.3

    CSMA/CD (Carrier Sense Multiple Access withCollision Detection)

    Describe how CSMA/CD works: A node needing to transmit listens for activity on

    the media. If there is none, it transmits. The node continue to listen. A collision is detected

    by a spike in voltage (a bit can only be a 0 or a 1--itcannot be a 2)

    The node generates a jam signal to tell all devices

    to stop transmitting for a random amount of time(back-off algorithm).

    When media is clear of any transmissions, the nodecan attempt to retransmit.

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    31/50

    Address Resolution Protocol

    In broadcast topologies, we need a way toresolve unknown destination MAC addresses.

    ARP is protocol where the sending devicesends out a broadcast ARP request which

    says, Whats you MAC address? If the destination exists on the same LAN

    segment as the source, then the destinationreplies with its MAC address.

    However, if the destination and source areseparated by a router, the router will notforward the broadcast (an important functionof routers). Instead the router replies with its

    own MAC address.

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    32/50

    Application

    Presentation

    Session

    Transport

    Network

    Data-LinkPhysical

    THE OSI MODEL

    Transport Layer

    A Quick Review

    Table of Contents

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    33/50

    Transport Layer Functions

    Synchronization of the connection Three-way handshake

    Flow Control

    Slow down, youre overloading my memorybuffer!!

    Reliability & Error Recovery

    Windowing: How much data can I sendbefore getting an acknowledgement?

    Retransmission of lost or unacknowledgedsegments

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    34/50

    Transports Two Protocols

    TCP Transmission Control

    Protocol

    Connection-oriented

    Acknowledgment &Retransmission ofsegments

    Windowing

    Applications: Email

    File Transfer

    E-Commerce

    UDP User Datagram

    Protocol

    Connectionless

    NoAcknowledgements

    Applications: Routing Protocols

    Streaming Audio Gaming

    Video Conferencing

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    35/50

    Application

    Presentation

    Session

    Transport

    Network

    Data-LinkPhysical

    THE OSI MODEL

    IP Addressing

    Subnetting Review

    Table of Contents

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    36/50

    Logical Addressing

    At the network layer, we use logical,hierarchical addressing.

    With Internet Protocol (IP), this address is a32-bit addressing scheme divided into four

    octets. Do you remember the classes 1st octets

    value? Class A: 1 - 127

    Class B: 128 - 191 Class C: 192 - 223

    Class D: 224 - 239 (multicasting)

    Class E: 240 - 255 (experimental)

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    37/50

    Network vs. Host

    N H H HClass A:27 = 126 networks; 224 > 16 mill ionhosts

    N N H HClass B : 214 = 16,384 networks; 216 > 65,534 hosts

    N N N HClass C : 221 > 2 million networks; 28 = 254hosts

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    38/50

    Why Subnet?

    Remember: we are usually dealing witha broadcast topology.

    Can you imagine what the network

    traffic overhead would be like on anetwork with 254 hosts trying todiscover each others MAC addresses?

    Subnetting allows us to segment LANsinto logical broadcast domains calledsubnets, thereby improving networkperformance.

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    39/50

    Stealing /Borrowing Host Bits

    In order to subnet, we must steal or borrowbits from the host portion on the IP address.

    First, we must to determine how manysubnets we need and how many hosts per

    subnet. We do this through the power of 2

    For example, I need 8 subnets from a Class C: 24 = 16 - 2 = 14 subnets

    Remember: we subtract 2 because these subnets are notused

    How many host do we have? Its a Class C, so 4 bits are left: 24 = 16 - 2 = 14 hosts

    Remember: we subtract 2 because one address is the

    subnet address and one is the broadcast address

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    40/50

    Subnet Mask

    We determine the subnet mask by adding upthe decimal value of the bits we borrowed.

    In the previous Class C example, we borrowed4 bits. Below is the host octet showing the bits

    we borrowed and their decimal values.

    128 64 32 16 8 4 21

    1 1 1 1

    We add up the decimal value of these bits and get 240.Thats the last non-zero octet of our subnet mask.

    So our subnet mask is 255.255.255.240

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    41/50

    Last Non-Zero Octet

    Memorize this table. You should be able to: Quickly calculate the last non-zero octet when giventhe number of bits borrowed.

    Determine the number of bits borrowed given thelast non-zero octet.

    Determine the amount of bits left over for hosts andthe number of host addresses available.

    Bits

    Borrowed

    Non-Zero

    Octet Hosts

    2 192 623 224 30

    4 240 14

    5 248 6

    6 252 2

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    42/50

    CIDR Notation

    Classless Interdomain Routing is a method ofrepresenting an IP address and its subnetmask with a prefix.

    For example: 192.168.50.0/27

    What do you think the 27 tells you? 27 is the number of 1 bits in the subnet mask.

    Therefore, 255.255.255.224

    Also, you know 192 is a Class C, so we borrowed 3

    bits!! Finally, you know the magic number is 256 - 224 =32, so the first useable subnet address is197.168.50.32!!

    Lets see the power of CIDR notation.

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    43/50

    202.151.37.0/26

    Subnet mask? 255.255.255.192

    Bits borrowed? Class C so 2 bits borrowed

    Magic Number? 256 - 192 = 64

    First useable subnet address? 202.151.37.64

    Third useable subnet address? 64 + 64 + 64 = 192, so 202.151.37.192

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    44/50

    198.53.67.0/30

    Subnet mask? 255.255.255.252

    Bits borrowed? Class C so 6 bits borrowed

    Magic Number? 256 - 252 = 4

    Third useable subnet address? 4 + 4 + 4 = 12, so 198.53.67.12

    Second subnets broadcast address? 4 + 4 + 4 - 1 = 11, so 198.53.67.11

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    45/50

    200.39.89.0/28

    What kind of address is 200.39.89.32? Class C, so 4 bits borrowed

    Last non-zero octet is 240

    Magic number is 256 - 240 = 16

    32 is a multiple of 16 so 200.39.89.32 is asubnet address--the second subnetaddress!!

    Whats the broadcast address of200.39.89.32? 32 + 16 -1 = 47, so 200.39.89.47

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    46/50

    194.53.45.0/29

    What kind of address is 194.53.45.26? Class C, so 5 bits borrowed Last non-zero octet is 248 Magic number is 256 - 248 = 8

    Subnets are .8, .16, .24, .32, ect.

    So 194.53.45.26 belongs to the third subnetaddress (194.53.45.24) and is a host address.

    What broadcast address would this host use

    to communicate with other devices on thesame subnet? It belongs to .24 and the next is .32, so 1 less is .31

    (194.53.45.31)

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    47/50

    No Worksheet Needed!

    After some practice, you should never need asubnetting worksheet again.

    The only information you need is the IPaddress and the CIDR notation.

    For example, the address 221.39.50/26

    You can quickly determine that the firstsubnet address is 221.39.50.64. How?

    Class C, 2 bits borrowed 256 - 192 = 64, so 221.39.50.64

    For the rest of the addresses, just do multiplesof 64 (.64, .128, .192).

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    48/50

    The Key!!

    MEMORIZE THIS TABLE!!! Or Know howto recreate/derive it!!!!

    Bits

    Borrowed

    Non-Zero

    Octet Hosts

    2 192 62

    3 224 30

    4 240 14

    5 248 66 252 2

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    49/50

    Practice On Your Own

    Below are some practice problems. Take outa sheet of paper and calculate... Bits borrowed

    Last non-zero octet

    Second subnet address and broadcast address1. 192.168.15.0/26

    2. 220.75.32.0/30

    3. 200.39.79.0/29

    4. 195.50.120.0/275. 202.139.67.0/28

    1. Challenge: 132.59.0.0/19

    2. Challenge: 64.0.0.0/16

    Answers

  • 8/2/2019 Sub Netting - Apjohns0 Ch01-Where We'Ve Been

    50/50

    Answers

    Address ClassBits

    BorrowedLast Non-Zero Octet

    SubnetJump

    2nd Subnet'sAddress

    2nd Subnet'sBroadcast

    192.168.15.0/26 C 2 192 64 192.168.15.128 192.168.15.191

    220.75.32.0/30 C 6 252 4 220.75.32.8 220.75.32.15

    200.39.79.0/29 C 5 248 8 200.39.79.16 220.39.79.23195.50.120.0/27 C 3 224 32 195.50.120.64 195.50.120.95

    202.139.67.0/28 C 4 240 16 202.139.67.32 202.139.67.47

    132.59.0.0/19 B 3 224 32 132.59.64.0 132.59.95.255

    64.0.0.0/16 A 8 255 1 64.2.0.0 64.2.255.255

    Challenge:

    Dont Cheat Yourself!! Work them out before you check your answers. Clickthe back button if youre not done. Otherwise, clickanywhere else in the screen to see the answers.

    Back