ecpe comp 177 fall 2014
play

ECPE / COMP 177 Fall 2014 Some slides from Kurose and - PowerPoint PPT Presentation

ECPE / COMP 177 Fall 2014 Some slides from Kurose and Ross, Computer Networking , 5 th Edition Quiz Next Tuesday (10-15 minutes) Sockets,


  1. ECPE ¡/ ¡COMP ¡177 ¡ Fall ¡2014 ¡ Some ¡slides ¡from ¡Kurose ¡and ¡Ross, ¡ Computer ¡Networking , ¡5 th ¡Edition ¡

  2. ¡ Quiz ¡Next ¡Tuesday ¡(10-­‑15 ¡minutes) ¡ § Sockets, ¡Application-­‑Layer ¡Protocol ¡(HTTP) ¡ ¡ Project ¡#1 ¡ § Starts ¡next ¡Tuesday ¡ § Is ¡your ¡Linux ¡environment ¡all ¡ready? ¡ § Bring ¡your ¡laptop ¡– ¡Work ¡time ¡after ¡quick ¡ discussion ¡of ¡project ¡goals ¡ § Two ¡weeks ¡– ¡Don’t ¡delay! ¡ 2 ¡

  3. Application ¡Layer ¡ Transport ¡Layer ¡ Network ¡Layer ¡ Link ¡Layer ¡ Physical ¡Layer ¡ 3 ¡

  4. Application ¡Layer ¡ HTTP ¡ DNS ¡ IMAP ¡ Skype ¡ BitTorrent ¡ RDP ¡ LDAP ¡ NFS ¡ SSH ¡ Sockets ¡ … ¡and ¡many ¡more! ¡ Transport ¡Layer ¡ Network ¡Layer ¡ Link ¡Layer ¡ Physical ¡Layer ¡ 4 ¡

  5. Application ¡Layer ¡ Transport ¡Layer ¡ Sockets ¡ Flow ¡Control ¡ Congestion ¡Control ¡ End-­‑to-­‑End ¡ message ¡ transfer ¡ TCP ¡ UDP ¡ Network ¡Layer ¡ Link ¡Layer ¡ Physical ¡Layer ¡ 5 ¡

  6. Application ¡Layer ¡ Transport ¡Layer ¡ Network ¡Layer ¡ End-­‑to-­‑End ¡ packet ¡ IP ¡– ¡Internet ¡Protocol! ¡ transfer ¡ Packet ¡Headers ¡ Routers ¡ ICMP ¡for ¡error ¡ reporting ¡and ¡ router ¡signaling ¡ IP ¡Addresses ¡ Routing ¡Protocols ¡ Link ¡Layer ¡ Physical ¡Layer ¡ 6 ¡

  7. Application ¡Layer ¡ Transport ¡Layer ¡ Network ¡Layer ¡ Link ¡Layer ¡ Transfer ¡ between ¡ Ethernet! ¡ neighbors ¡ Framing ¡ MAC ¡addresses ¡ Media ¡Access ¡ Control ¡ Error ¡Detection ¡ Hubs ¡& ¡Switches ¡ Physical ¡Layer ¡ 7 ¡

  8. Application ¡Layer ¡ Transport ¡Layer ¡ Network ¡Layer ¡ Link ¡Layer ¡ Physical ¡Layer ¡ “Bits ¡on ¡a ¡wire” ¡ Encoding ¡schemes ¡ fight: ¡ attenuation ¡ distortion ¡ clock ¡skew ¡ 8 ¡

  9. ¡ Course ¡Organization ¡– ¡Top-­‑Down! ¡ § Starting ¡with ¡Applications ¡/ ¡App ¡programming ¡ § Then ¡Transport ¡Layer ¡(TCP/UDP)… ¡ § Then ¡Network ¡Layer ¡(IP)… ¡ § Then ¡Link ¡Layer ¡(Ethernet)… ¡ ¡ Challenge ¡for ¡Lab: ¡ § You’re ¡going ¡to ¡start ¡using ¡Ethernet/IP ¡on ¡the ¡first ¡ day! ¡ ¡ Solution ¡– ¡1-­‑day ¡overview ¡of ¡the ¡ essentials ¡ 9 ¡

  10. ¡ My ¡computer ¡has ¡several ¡key ¡network ¡ settings: ¡ § My ¡Ethernet ¡/ ¡ MAC ¡address ¡ § My ¡ IP ¡address ¡ ¡ § Netmask ¡of ¡network ¡I’m ¡connected ¡to ¡ § Next-­‑hop ¡gateway ¡IP ¡address ¡of ¡network ¡I’m ¡ connected ¡to ¡ ¡ What ¡do ¡these ¡mean? ¡ 10 ¡

  11. The ¡Link ¡Layer ¡ 11 ¡

  12. ¡ Goal: ¡Connect ¡computers ¡across ¡a ¡ Local ¡Area ¡ Network ¡ § Room? ¡ § Floor? ¡ § Building? ¡ § Few ¡buildings? ¡ ¡ Natural ¡size ¡limit ¡to ¡Ethernet-­‑only ¡networks ¡ § Will ¡discuss ¡reasons ¡why ¡later ¡this ¡semester ¡ Hub ¡or ¡Switch ¡ 12 ¡

  13. ¡ Each ¡device ¡on ¡the ¡network ¡needs ¡a ¡ unique ¡address ¡ ¡ All ¡Ethernet ¡devices ¡have ¡globally ¡unique ¡48-­‑bit ¡ address ¡assigned ¡by ¡manufacturer ¡ ¡ § Upper ¡24 ¡bits ¡– ¡Manufacturer ¡ ¡ § Lower ¡24 ¡bits ¡– ¡Unique ¡device ¡by ¡manufacturer ¡ § The ¡ MAC ¡address ¡ ¡ Example: ¡ 0x 00-07-E9-CB-79-4F § 0x 00-07-E9 = ¡Intel ¡Corp ¡(assigned ¡by ¡IEEE) ¡ § 0x CB-79-4F = ¡Unique ¡address ¡per ¡NIC ¡(picked ¡by ¡ Intel) ¡ This ¡is ¡where ¡“my” ¡ MAC ¡address ¡comes ¡ from ¡ 13 ¡

  14. Bytes: ¡ ¡ 6 ¡ ¡ 6 ¡ ¡ 2 ¡ ¡ 0-­‑1500 ¡ ¡ Dest ¡ ¡ Source ¡ Type ¡ Data ¡ MAC ¡ MAC ¡ ¡ Two ¡MAC ¡addresses ¡saved ¡in ¡Ethernet ¡frame ¡ § Destination ¡MAC ¡ – ¡Where ¡is ¡this ¡frame ¡going ¡ to ? ¡ § Source ¡MAC ¡ – ¡Who ¡sent ¡this ¡frame? ¡ ¡ Type: ¡Indicates ¡data ¡type ¡or ¡length ¡in ¡bytes ¡ ¡ The ¡Data! ¡ ¡ Note: ¡The ¡above ¡view ¡is ¡simplified… ¡ 14 ¡

  15. ¡ So ¡how ¡do ¡I ¡connect ¡ dozens ¡of ¡computers ¡ together? ¡ § My ¡cable ¡only ¡has ¡two ¡ ends… ¡ 15 ¡

  16. ¡ Learns ¡location ¡of ¡computers ¡on ¡Ethernet ¡network ¡ § Examine ¡header ¡of ¡each ¡arriving ¡frame ¡ § What ¡is ¡its ¡source ¡MAC ¡address? ¡(i.e. ¡who ¡sent ¡it?) ¡ ▪ Note ¡the ¡port ¡it ¡came ¡in ¡on! ¡ ▪ Save ¡this ¡data ¡in ¡ forwarding ¡table ¡ ¡ Forwards ¡data ¡out ¡correct ¡port ¡ § Search ¡forwarding ¡table ¡for ¡ destination ¡MAC ¡address ¡ ¡ 16 ¡

  17. Ethernet ¡Hub ¡ Ethernet ¡Switch ¡ (assume ¡learning ¡already ¡occurred) ¡ B ¡ B ¡ C ¡ C ¡ A ¡ A ¡ Hub ¡ Switch ¡ D ¡ D ¡ E ¡ E ¡ A ¡transmits ¡to ¡D ¡ A ¡transmits ¡to ¡D ¡ D ¡replies ¡to ¡A ¡ D ¡replies ¡to ¡A ¡ E ¡transmits ¡to ¡B, ¡ and ¡A ¡to ¡C ¡ 17 ¡

  18. The ¡Network ¡Layer ¡ 18 ¡

  19. ¡ Ethernet ¡is ¡sufficient ¡for ¡a ¡local-­‑area ¡network ¡ ¡ IP ¡is ¡needed ¡for ¡a ¡global ¡network ¡(the ¡ Internet !) ¡ 19 ¡

  20. ¡ Datagram ¡ ¡ Unreliable ¡ § Each ¡packet ¡is ¡ § No ¡guarantee ¡of ¡delivery ¡ individually ¡routed ¡ § No ¡guarantee ¡of ¡ § Packets ¡may ¡be ¡ integrity ¡of ¡data ¡ fragmented ¡or ¡ duplicated ¡ ¡ ¡ Best ¡effort ¡ ▪ Due ¡to ¡underlying ¡ § Only ¡drop ¡packets ¡when ¡ networks ¡ necessary ¡ § No ¡time ¡guarantee ¡for ¡ ¡ Connectionless ¡ delivery ¡ § No ¡guarantee ¡of ¡delivery ¡ in ¡sequence ¡ This ¡is ¡no ¡different ¡from ¡standard ¡Ethernet ¡networks! ¡ 20 ¡

  21. ¡ IP ¡version ¡4 ¡addresses ¡are ¡32 ¡bits ¡long ¡ § Version ¡6 ¡address ¡are ¡128 ¡bits ¡ ¡ Every ¡network ¡interface ¡has ¡at ¡least ¡one ¡IP ¡ address ¡ § A ¡computer ¡might ¡have ¡2 ¡or ¡more ¡IP ¡addresses ¡ § A ¡router ¡has ¡many ¡IP ¡addresses ¡ § These ¡addresses ¡can ¡be ¡assigned ¡statically ¡or ¡ dynamically ¡ This ¡is ¡where ¡“my” ¡IP ¡ address ¡comes ¡from ¡ 21 ¡

  22. ¡ IPv4 ¡addresses ¡are ¡usually ¡displayed ¡in ¡dotted ¡ decimal ¡notation ¡ § Each ¡byte ¡represented ¡by ¡decimal ¡value ¡ § Bytes ¡are ¡separated ¡by ¡a ¡period ¡ § IP ¡address ¡ 0x8002C2F2 = 128.2.194.242 22 ¡

  23. ¡ Two ¡IP ¡addresses ¡saved ¡in ¡packet ¡ § Destination ¡IP ¡address ¡ ▪ Where ¡is ¡this ¡packet ¡going ¡to? ¡ § Source ¡IP ¡address ¡ ▪ Who ¡sent ¡this ¡packet? ¡ ¡ Checksum ¡ ¡ Length ¡ ¡ Other ¡fields ¡ ¡ The ¡Data! ¡ 23 ¡

  24. ¡ IP ¡datagrams ¡can ¡be ¡ encapsulated ¡in ¡Ethernet ¡ frames ¡ Bytes: ¡ ¡ 6 ¡ ¡ 6 ¡ ¡ 2 ¡ ¡ 20-­‑60 ¡ ¡ 0-­‑1480 ¡ ¡ Dst ¡MAC ¡ Src ¡MAC ¡ IP ¡Header ¡ Data ¡ 0x0800 ¡ Addr ¡ Addr ¡ IP ¡Datagram ¡ ¡ So ¡what ¡is ¡sent ¡on ¡the ¡ wire ¡is ¡an ¡ Ethernet ¡frame ¡ § Inside ¡of ¡which ¡is ¡an ¡ IP ¡packet … ¡ ▪ Inside ¡of ¡which ¡is ¡the ¡ transport ¡layer … ¡ ▪ Inside ¡of ¡which ¡is ¡the ¡ application ¡layer … ¡ 24 ¡

  25. ¡ My ¡computer ¡has ¡several ¡key ¡network ¡ settings: ¡ ✓ ¡ § My ¡Ethernet ¡/ ¡ MAC ¡address ¡ ✓ ¡ § My ¡ IP ¡address ¡ ¡ § Netmask ¡of ¡network ¡I’m ¡connected ¡to ¡ § Next-­‑hop ¡gateway ¡IP ¡address ¡of ¡network ¡I’m ¡ connected ¡to ¡ ¡ What ¡do ¡these ¡mean? ¡ 25 ¡

Download Presentation
Download Policy: The content available on the website is offered to you 'AS IS' for your personal information and use only. It cannot be commercialized, licensed, or distributed on other websites without prior consent from the author. To download a presentation, simply click this link. If you encounter any difficulties during the download process, it's possible that the publisher has removed the file from their server.

Recommend


More recommend