What is latency? What affects latency?

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
what affects latency online the speed of light plays a role so that's the limiting factor if you want to know the PO you know the fastest possible connection you could have from one place to another online the speed of light is your guide so uh as a sort of rough back of the envelope calculation it takes about 100 milliseconds for light to circle the Earth um so that you know so anywhere on Earth you know the farthest you could get away from light is about 50 millisecs so you could exchange 20 packets per second with a computer on the other side of the world um now the but the fact is if you look at latencies online the latencies don't reflect the speed of light at all so what's slowing things down well let's let's run some examples here we're going to use ping ping is a great way to test um as one way to test latency uh ping doesn't stress bandwidth it's sending very small amounts of information uh so a ping essentially looks in sends a message to a server and waits for a reply and then tells you uh what the what the latency is so I'm going to Ping a server called testified cs. buffalo.edu this is actually my personal machine it's located in the room just over there so I don't know I how long it would take light to get from here to there but it would be tiny tiny tiny tiny tiny so a tiny amount of time um so let's ping that machine and see how long it takes okay here we go um so now you know the first pack took a little while I think maybe my Wi-Fi fell asleep per a second but now I'm seeing I'm seeing latencies over here um that are in the range of you know 4 milliseconds 2 milliseconds and obviously you know again I mean there's no way that it takes if if light can Circle the globe in 100 milliseconds there's no way that it takes 2 milliseconds for it to go 10 ft so this latency is reflecting something else that's going on on the connection and most of the latency that we see online is not a function of the speed of light it's a function of handling time by computers in between so if I ran a trace route to my machine I would see that it takes a couple tops so this laptop's connected to a wireless router over there that wireless router actually can probably speak directly to my uh to my desktop and so what I'm seeing here when I see a couple milliseconds of latency is the time it takes for this wireless router to take a packet from the wireless connection and forward it on over the wired connection so computers despite the fact that they're quite fast typically add a lot of the latency that we see to uh the internet connections that that we can measure so latency is usually a function of router handling time and delays at routers along the way rather than the speed of light uh to make that more apparent let's run a different ping test uh so I'm going to Ping a machine called live labs. SM u.edu do SG so SG is Singapore's prefix uh or sorry uh I Singapore is DNS postfix so this is a machine located at Singapore management University which is in Singapore Singapore is almost on the other side of the world from us uh the longest flight uh that originates some of the longest flights that originate from the United States go to Singapore so Singapore is far away if you got on a plane it would take you better part of a whole day worth of travel to get to Singapore let's see how long it takes an internet packet to get back and forth to Singapore okay um and so I'm I'm I'm pinging this machine and I can see that you know at minimum you know I'm seeing about 250 milliseconds of latency and that you know that that makes a certain amount of sense right I mean light would take 50 milliseconds to get there this packet was probably touched by router after router after router after router after router after router so the the number of hops that this packet had to travel to get all the way across the world um is quite large and every time a router has to pick up and make a decision about this packet and pass it on that's adding latency to the connection so the latency that we see here 250 milliseconds is really largely driven by the router and the the router having to routers having to touch things along the way um so but you can you can imagine how this latency affects things so for example t CP requires this handshake at the beginning of initiating every Rec connection if it takes 250 milliseconds to send one packet one way then the latency that a TCP connection incurs is going to be quite large because it has to do that multiple times and so when you start to think about um loading websites and chatting with people and doing things where the person is really far away the latency of these internet connections can start to matter um but the latency is primarily the function of routers along on the path and their handling time required to deliver the packet to its destination
Info
Channel: internet-class
Views: 78,881
Rating: undefined out of 5
Keywords: internet, internet-class.org
Id: epAXDsq5SbE
Channel Id: undefined
Length: 5min 14sec (314 seconds)
Published: Tue Sep 20 2016
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.