New User Special Price Expires in

Let's log you in.

Sign in with Facebook


Don't have a StudySoup account? Create one here!


Create a StudySoup account

Be part of our community, it's free to join!

Sign up with Facebook


Create your account
By creating an account you agree to StudySoup's terms and conditions and privacy policy

Already have a StudySoup account? Login here

Computer Networks and the Internet

by: Betty Kertzmann

Computer Networks and the Internet CS 457

Marketplace > Colorado State University > ComputerScienence > CS 457 > Computer Networks and the Internet
Betty Kertzmann
GPA 3.51

Daniel Massey

Almost Ready


These notes were just uploaded, and will be ready to view shortly.

Purchase these notes here, or revisit this page.

Either way, we'll remind you when they're ready :)

Preview These Notes for FREE

Get a free preview of these Notes, just enter your email below.

Unlock Preview
Unlock Preview

Preview these materials now for free

Why put in your email? Get access to more of this material and other relevant free materials for your school

View Preview

About this Document

Daniel Massey
Class Notes
25 ?




Popular in Course

Popular in ComputerScienence

This 40 page Class Notes was uploaded by Betty Kertzmann on Monday September 21, 2015. The Class Notes belongs to CS 457 at Colorado State University taught by Daniel Massey in Fall. Since its upload, it has received 24 views. For similar materials see /class/210174/cs-457-colorado-state-university in ComputerScienence at Colorado State University.

Similar to CS 457 at CSU

Popular in ComputerScienence


Reviews for Computer Networks and the Internet


Report this Material


What is Karma?


Karma is the currency of StudySoup.

You can buy or earn more Karma at anytime and redeem it for class notes, study guides, flashcards, and more!

Date Created: 09/21/15
CS 457 Lecture 9 Switching and Forwarding 2 Fall 2009 no call setup at network layer Datag ram networks routers no state about endtoend connections no networklevel concept of connection packets fonNarded using destination host address packets between same sourcedest pair may take different paths guppl icat ion data link physical 391 Send data 392 Receive data data link physical FilteringForwarding When switch receives a frame index switch table using MAC dest address if entry found for destination then if dest on segment from which frame arrived then drop the frame else fonNard the frame on interface indicated else flood forward on all but the interface mmbicbibeimmeamived Switch Example Suppose C sends frame to D oswnch addr39es inter face Switch receives frame from from C notes in bridge table that C is on interface 1 because D is not in table switch forwards frame into interfaces 2 and 3 Frame received by D Switch Example Suppose D replies back with frame to C interface switch Switch receives frame from from D notes in bridge table that D is on interface 2 because C is in table switch forwards frame only to interface 1 Frame received by C Steps in Spanning Tree Algorithm Initially each switch thinks it is the root Switch sends a message out every interface identifying itself as the root with distance 0 Example switch X announces X 0 X Switches update their view of the root Upon receiving a message check the root ID Ifthe new id is smaller start viewing that switch as root Switches compute their distance from the root Add 1 to the distance received from a neighbor Identify interfaces not on a shortest path to the root and exclude them from the spanning tree Example From Switch 4 s Viewpoint Switch 4 thinks it is the root Sends 4 0 4 message to 2 and 7 Then switch 4 hears from 2 1 Receives 2 0 2 message from 2 and thinks that 2 is the root And realizes it is just one hop away 5 Then switch 4 hears from 7 2 6 Receives 2 1 7 from 7 4 And realizes this is a longer path So prefers its own onehop path And removes 47 link from the tree Example From Switch 4 s View oint Switch 2 hears about switc 1 Switch 2 hears 1 1 3 from 3 Switch 2 starts treating 1 as root 1 And sends 1 2 2 to neighbors Switch 4 hears from switch 2 Switch 4 starts treating 1 as root 393 395 And sends 1 3 4 to neighbors 2 Switch 4 hears from switch 7 4 Switch 4 receives 1 3 7 from 7 7 6 And realizes this is a longer path So prefers its own threehop path And removes 47 link from the tree Robust Spanning Tree Algorithm Algorithm must react to failures Failure of the root node Need to elect a new root with the next lowest identifier Failure of other switches and links Need to recompute the spanning tree Root switch continues sending messages Periodically reannouncing itself as the root 1 0 1 Other switches continue fonvarding messages Detecting failures through timeout soft state Switch waits to hear from others Eventually times out and claims to be the root See Section 322 in the textbook for details and another example Evolution Toward Virtual LANs In the olden days Thick cables snaked through cable ducts in buildings Every computer they passed was plugged in All people in adjacent offices were put on the same LAN Independent of whether they belonged together or not More recently Hubs and switches changed all that Every office connected to central wiring closets Often multiple LANs k hubs connected by switches Flexibility in mapping offices to different LANs Group users based on organizational structure rather than the physical layout of the building Why Group by Organizational Security Structure Ethernet is a shared media Any interface card can be put into promiscuous mode and get a copy of all of the traffic eg midterm exam So isolating traffic on separate LANs improves security Load Some LAN segments are more heavily used than others Eg researchers running experiments get out of hand can saturate their own segment and not the others Plus there may be natural locality of communication Eg traffic between people in the same research group People Move and Roles Change Organizational changes are frequent Eg faculty office becomes a gradstudent office Eg graduate student becomes a faculty member Physical rewiring is a major pain Requires unplugging the cable from one port and plugging it into another and hoping the cable is long enough to reach and hoping you don t make a mistake Would like to rewire the building in software The resulting concept is a Virtual LAN VLAN Example Two Virtual LANs 1 ETTT Red VLAN and Orange VLAN Bridges forward traffic as needed Example Two Virtual LANs Red VLAN and Orange VLAN Switches forward traffic as needed Making VLANs Work Bridgesswitches need configuration tables Saying which VLANs are accessible via which interfaces Approaches to mapping to VLANs Each interface has a VLAN color Only works if all hosts on same segment belong to same VLAN Each MAC address has a VLAN color Useful when hosts on same segment belong to different VLANs Useful when hosts move from one physical location to another Changing the Ethernet header Adding a field for a VLAN tag Implemented on the bridgesswitches but can still interoperate with old Ethernet cards Virtual circuits sourcetodest path behaves much like telephone circuit performancewise network actions along sourcetodest path call setup teardown for each call before data can flow each packet carries VC identifier not destination host address evey router on sourcedest path maintains state for each passing connection link router resources bandwidth buffers may be allocated to V0 VC implementation A VC consists of 1 Path from source to destination 2 VC numbers one number for each link along path 3 Entries in fonNarding tables in routers along path Packet belonging to V0 carries a VG number VC number must be changed on each link New VC number comes from fonNarding table Forwarding table VC number For39war39dinq Table in interface norquotrhwes r r ou rer39 number39 Incoming inTer face Incoming VC I OuTgoing inTer facel OuTgoing VC 1 12 2 22 2 63 1 18 3 7 2 17 1 97 3 87 Rou rer39s main rain connec rion s ra re informationll Virtual circuits Signaling Protocols used to setup maintain teardown VC used in ATM framerelay X25 not used in today s Internet appication r daTa ii 39 p39nySIcai 395 Data flow begins 396 Receive data 394 Call connected 1 Initiate call 393 Accept ca incoming call a plication r daTa iink p39ny3Icai CS 457 Lecture 12 Internetworking and IP Pa 2 FaH2009 Avoiding Manual Configuration Dynamic Host Configuration Protocol DHCP End host learns IP address DNS servers and gateway Address Resolution Protocol ARP Learn mapping between IP address and MAC address 1237 123156 m 123024 12319 router I host I I host I I DNS I routerl router 567024 Key Ideas in ARP and DHCP Broadcasting when in doubt shout Broadcast query to all hosts in the localareanetwork when you don t know how to identify the right one Caching remember the past for a while Store the information you learn to reduce overhead Remember your own address amp other host s addresses Soft state eventually forget the past Associate a timetolive field with the information and either refresh or discard the information Key for robustness in the face of unpredictable change Sending Packets Over a Link 12353 123156 IP packet 12353 123156 w Adaptors only understand MAC addresses Translate the destination IP address to MAC address Encapsulate the IP packet inside a linklevel frame Why Do We Need ARP MAC addresses Hardcoded in readonly memory when adaptor is built Like a social security number Flat name space of 48 bits eg OOOE986E4976 Portable and can stay the same as the host moves Used to get packet between interfaces on same network IP addresses Configured or learned dynamically Like a postal mailing address Hierarchical name space of 32 bits eg 12178669 Not portable and depends on where the host is attached Used to get a packet to destination IP subnet Address Resolution Protocol ARP Table Every node maintains an ARP table ltP address MAC addressgt pair Consult the table when sending a packet Map destination IP address to destination MAC address Encapsulate and transmit the data packet But what if the IP address is not in the table Sender broadcasts Who has IP address 123156 Receiver responds MAC addr 5823D7FA 20BO Sender caches the result in its ARP table No need for network administrator to get involved Finding Ether Address Address Resolution ARP Broadcast who knows the Ethernet address for 128 82 1 3 8 2 gateway address 839 839 N I n I I I Ethernet Broadcast I do it is 08002019dc45 I I Ethernet Dynamic Host Configuration Protocol DHCP Host doesn t have an IP address yet So host doesn t know what source address to use Host doesn t know who to ask for an IP address So host doesn t know what destination address to use Solution shout to discover a server who can help Broadcast a serverdiscovery message Server sends a reply offering an address I host I I host I I host I I DHCP server DHCP at an End Host What IP address the host should use What local Domain Name System server to use How to send packets to remote destinations How to ensure incoming packets arrive 1237 123156 m 23024 I host I host I I DNS l 2 3 l 9 Irouterl router router 567024 Dynamic Host Configuration P rotocol Lr cover broadcast oarriving DHCP 0 e DHCP server client 233125 39br P request oadcasv oHCquot Ac Response from the DHCP Server DHCP offer message from the server Configuration parameters proposed IP address mask gateway router DNS server Lease time the time the information remains valid Multiple servers may respond Multiple servers on the same broadcast media Each may respond with an offer The client can decide which offer to accept Accepting one of the offers Client sends a DHCP request echoing the parameters The DHCP server responds with an ACK to confirm and the other servers see they were not chosen Deciding What IP Address to Offer Server as centralized configuration database All parameters are statically configured in the server Eg a dedicated IP address for each MAC address Avoids complexity of configuring hosts directly while still having a permanent IP address per host Or dynamic assignment of IP addresses Server maintains a pool of available addresses and assigns them to hosts on demand Leads to less configuration complexity and more efficient use of the pool of addresses Though it is harder to track the same host over time Soft State Refresh or Forget Why is a lease time necessary Client can release the IP address DHCP RELEASE Eg ipconfig release at the DOS prompt Eg clean shutdown of the computer But the host might not release the address Eg the host crashes blue screen of death Eg buggy client software And you don t want the address to be allocated forever Performance tradeoffs Short lease time returns inactive addresses quickly Long lease time avoids overhead of frequent renewals Example A Sending Packet to B How does host A send an IP packet to host B 2 742QQCE8FF55 33 5 2 F 5413 OF A 1111111111 EEiEQUO17BB4B I 1A 23F9CD069 222222222221 222222222222 139 B 4QElDD2CT 5Ei2A 2392 1111111111 R 22 22 z 22 111111111110 CC4QDEDOABT D A sends packet to R and R sends packet to B Host A Sends Through R Host A constructs an IP packet to send to B Source 111111111111 destination 222222222222 Host A has a gateway router R Used to reach destinations outside of 111111111024 Address 111111111110 for R learned via DHCP 88S22F54 Aan 742QQCE8FF55 1 A EEEQ IJCl 1EIB4B xx r I 39 39 119 F7 111111 1111 1A23FQCDUE 42 z 4zzrzh1 222222222222 x B 4Q BDDECT 56Z A R 1111111111 2 3224 2 111111111110 3 C 4 9 D E D CI AEi T D Host A Sends Packet Through R Host A learns the MAC address of R s interface ARP request broadcast requestfor 111111111110 ARP response R responds with E6E90017BB4B Host A encapsulates the packet and sends to R 88922F54 Aan 74 29 Qc Ea FF 55 1 A EEEQ IJO 1EIB4B KK I 3939 maxiHp 7 11141151111 1923 F9 CD 05 42bz 4 2421 222222222222 a B 4QEIDDECT562A R 2222222222 111111111110 3 C 4 Q D E D IZI AB T D R Forwards a Packet Router R s adaptor receives the packet R extracts the IP packet from the Ethernet frame R sees the IP packet is destined to 222222222222 Router R consults its forwarding table Packet matches 222222222024 via other adaptor 2 2 5 7429QCE8FF55 b B F 41 LF A EBEooo1 738848 2 Xx 111111 111I1 1AL3FQ39VDUB 42 Z 4zzrz1 222222222222 B 4Q BDDESTEBZ39A R 1111111111 1 2224 2 111111111110 C C 4 9 D E D III REL T D R Sends Packet to B Router R s learns the MAC address of host B ARP request broadcast request for 222222222222 ARP response B responds with 49BDD2C756 2A Router R encapsulates the packet and sends to B 88922F541A EIF 7429QCEBFF55 A EEEQIJCI 1EIB4B 1 xx r I 1A23FQCDUE 222222222221 111111111139 222222222222 x B 4Q BDDECT EIB2A R 22222222221 1111111111 111111111110 3 C 4 9 D E D CI AEi T D Error Reporting Examples of errors a router may see Router doesn t know where to forward a packet Packet s timetolive field expires Router doesn t really need to respond Best effort means never having to say you re sorry 80 IP could conceivablyjust silently drop packets But silent failures are really hard to diagnose lP includes basic feedback about network problems Internet Control Message Protocol ICMP Internet Control Message Protocol ICMP ICMP runs on top of IP Though still viewed as an integral part of IP Diagnostics Triggered when an IP packet encounters a problem Eg time exceeded or destination unreachable ICMP packet sent back to the source IP address Includes the error information eg type and code and an excerpt of the original data packet for identification Source host receives the ICMP packet And inspects the excerpt of the packet eg protocol and ports to identify which socket should receive the error Example Time Exceeded Host sends an IP packet Each router decrements the timeto live field If timetolive field reaches 0 Router generates an ICMP message Sends a time exceeded message back to the source 1237 567156 host host IDNsl host host IDNsl Al I I I I TIme exceeded router w m 891011


Buy Material

Are you sure you want to buy this material for

25 Karma

Buy Material

BOOM! Enjoy Your Free Notes!

We've added these Notes to your profile, click here to view them now.


You're already Subscribed!

Looks like you've already subscribed to StudySoup, you won't need to purchase another subscription to get this material. To access this material simply click 'View Full Document'

Why people love StudySoup

Jim McGreen Ohio University

"Knowing I can count on the Elite Notetaker in my class allows me to focus on what the professor is saying instead of just scribbling notes the whole time and falling behind."

Kyle Maynard Purdue

"When you're taking detailed notes and trying to help everyone else out in the class, it really helps you learn and understand the I made $280 on my first study guide!"

Bentley McCaw University of Florida

"I was shooting for a perfect 4.0 GPA this semester. Having StudySoup as a study aid was critical to helping me achieve my goal...and I nailed it!"


"Their 'Elite Notetakers' are making over $1,200/month in sales by creating high quality content that helps their classmates in a time of need."

Become an Elite Notetaker and start selling your notes online!

Refund Policy


All subscriptions to StudySoup are paid in full at the time of subscribing. To change your credit card information or to cancel your subscription, go to "Edit Settings". All credit card information will be available there. If you should decide to cancel your subscription, it will continue to be valid until the next payment period, as all payments for the current period were made in advance. For special circumstances, please email


StudySoup has more than 1 million course-specific study resources to help students study smarter. If you’re having trouble finding what you’re looking for, our customer support team can help you find what you need! Feel free to contact them here:

Recurring Subscriptions: If you have canceled your recurring subscription on the day of renewal and have not downloaded any documents, you may request a refund by submitting an email to

Satisfaction Guarantee: If you’re not satisfied with your subscription, you can contact us for further help. Contact must be made within 3 business days of your subscription purchase and your refund request will be subject for review.

Please Note: Refunds can never be provided more than 30 days after the initial purchase date regardless of your activity on the site.