(light music)
- Within the ICND1 blueprint under the general bullet point
of network fundamentals,
they include a section on IPv6, this is the place
where they first want to introduce you to IPv6.
So these next several videos are going to be little snippets
of me talking about various aspects of IPv6.
We're not actually gonna get into the configuration of IPv6.
First of all, I have to go through basic iOS command lines
before we even think about that.
But I just wanna introduce IPv6
from a theoretical perspective.
So this is the first video in that series introducing IPv6.
So let's first talk a little bit about the history of IPv6.
We know that IPv4 was actually first developed
back with RFC 791 in 1981,
I think it was 1981 or 1982
when IPv4 was just developed.
And initially, at the very, very beginning stages,
it was only developed for like institutions like colleges
and universities that were experimenting
with IPv4.
This idea of an internet was not even envisioned back then.
But as more and more people started connecting
to the IPv4 backbone and using it,
and it began expanding from just research
to communications, and gaming,
this idea of IPv4 addresses became more
and more and more popular.
So, by 1992 there was an impending shortage
of IPv4 address space the recogni--
like I should say that in 1992 they recognized that,
"Uh oh, the way things are going,
"with how quickly the IPv4 addresses are starting
"to be consumed, we recognize that at some point
"there's gonna be a shortage."
Now there was not a shortage back in 1992,
but that's when they first recognized
this is gonna be a problem.
At some point in the future,
if things keep going the way they're going,
we are going to run out of IPv4 subnets.
Now what does that actually mean?
Well, that means that whenever that point is,
if somebody develops a new company
and they want to connect to the internet,
we're not gonna have a subnet to give to them.
We're not gonna, if there's an existing company
that expands and they add a new campus,
we're not gonna have any addresses that we can give to them
'cause they will all be gone.
So they recognized back in 1992
that this was an inevitability.
So two years later,
the internet engineering task force launched their work
into a new version of IP, IPv6.
So IPv6, the initial motivator for it was,
"Let's restructure the address,
"let's make the address bigger."
you know, with 32-bits, there's billions of combinations
of addresses with 32-bits with an IPv4 address.
And you might think, "Wow, with that many combinations,
"how could we ever run out?"
Well, here we are in 2016, and we actually are starting
to run out in certain parts of the world,
even with billions of addresses.
So, the IETF decided,
"Let's redo the Internet Protocol, version six of it,
"and let's make the address space much bigger
"so that it'll hopefully never run out of addresses."
So that was the initial motivator of revising IP.
But then while they were at it,
they thought, "You know what?
"Since we're redoing IP, why don't we take this opportunity
"because who knows when we'll have this opportunity again,
"to change some other things
"about the Internet Protocol as well;
"not just making the address space bigger,
"but changing some other things as well."
And in another video coming up,
I'll show you the differences between the IPv4 header,
that we've looked at already, and the IPv6 header.
So in 1998, RFC 2460,
which was the first RFC document for IPv6, was written.
Now let's put things in perspective here a little bit.
Remember I told you that
when IP first came out in 1981 or 1982,
there was no such thing as subnet mask,
it was purely class A, class B, and class C.
So the idea of a subnet mask actually came out in 1985.
So that was RFC 950.
No one's ever gonna expect you to memorize this stuff,
none of these dates are gonna be on the ICND1 exam,
I just wanna sort of prep you and get your mind thinking
about why did they create this thing in the first place?
What problem was it designed to solve?
So, IP 1991: subnet masks added to IP in 1985,
and then seven years later they recognized,
"Uh oh, we can see a future
"where things are gonna start running out."
SO, in 1998, they wrote the actual first document for IPv6.
Then in 2006, so it took eight years,
you can see this from '98 to 2006,
it took eight years for IPv6 address spacing
to really stabilize.
In other words, there was a lot of back and forth about,
"Well, addresses should look like this."
"Well, these addresses should be used."
"No, these addresses should be kept private."
"No, we should keep these addresses in reserve."
"Oh no, we should look
"at the bits a little bit differently."
So it took eight years for them
to finally settle down and stabilize
on what the IPv6 address structure would actually look like
and how it would be used.
And that was RFC 4291.
Back in 2008, so now we're talking about eight years ago,
before this recording was made,
the United States Federal Government mandated
that all backbone devices running on Federal Agencies,
so for example, all the routers and devices that were owned
by the CIA, the FBI, the Social Security Administration,
all federal government agencies, their backbone routers,
and what do we mean by backbone router?
'Cause I know I haven't talked about that term yet.
So, in the structure of a network, we've talked about,
I did talk about earlier in a previous video,
about the Three Layer Design Model: the access layer,
which is what gives access to the network devices,
like your laptops and your tablets,
and then the distribution layer, and then the core layer.
So what we're really talking about here is routers
that would fit in that core layer
that would actually transmit traffic
back and forth between agencies.
So there would be a router owned by the FBI
that would be connected to a router owned by the CIA,
that'd be connected to a router owned
by the Social Security Administration,
and those would be considered backbone routers,
they form the backbone of the federal governments
and how they communicate to each other.
So back in 2008, the US Federal Government said
that all of those devices have to be IPv6 capable.
Now get that, they didn't say we have to configure IPv6
on those devices and run IPv6,
they just said whatever hardware and software
is on those devices has to support IPv6.
So back in 2008, there was a lot of purchasing going on
to get some new software, new equipment
to make sure that that requirement would be met.
Now, just last year, in September of 2015,
the American Registry of Internet Numbers,
the regional internet registry that supports North America,
ran out of IPv4 addresses.
So remember when I was first talking about IP addressing?
I was saying, "Well, sometimes you can just skip
your service provider and go directly
to your regional internet registry
and get provider independent addressing?"
can't do that with ARIN any more.
They actually have a few addresses they've held in reserve
for very special-use cases,
but it's next to impossible for you
to justify getting those.
So ARIN has basically run out of IPv4 addresses,
so here, in the United States and Canada,
at this point, all the service providers have gobbled up
whatever remaining IPv4 addresses are left.
And there's none at any tiers higher than them.
So that's where we are today
and I was just looking at some internet statistics
before I recorded this video,
and it's actually surprising me
because about, oh, 15 years ago or so,
so around 2000, so this is right around
when the first RFC for IPv6 was written,
everybody was pretty much laughing it off.
They said, "Ah, we're never gonna run out of IPv4 addresses,
"this thing's too much work, too hard to understand,
"we're not gonna deal with it."
So for the longest time, year after year after year,
people were pushing back on IPv6 saying,
"Oh, it's gonna be decades before it's used."
And they were saying, "Oh," I think as early as like 2012,
or 2013, not that long ago, IPv6 traffic on the internet,
so if you take a look at all the traffic
running across the internet globally,
at that point in time, like two, three years ago,
IPv6 traffic was like one percent.
Maybe not even one percent, it was so small.
Well I just looked at some statistics online
that now say that IPv6 running across the internet
is as high as 20 percent.
Think about that, one out of every five packets
that's going across the internet now globally
is an IPv6 packet.
It is ramping up really, really quickly.
So if you're gonna go into the networking fields
and engineer an admin, you can no longer afford
to ignore IPv6, it will be a part of your life.
It is here, it is now!
So, that being the case,
also I found this website right here
that I thought was kinda interesting
that I wanna share with you.
This is IPv6.com, you could go there
and if you scroll down a little bit,
this is under the history and timeline,
it shows you right here,
look at this chart right in the middle.
So this shows how the address depletion of IPv4 went.
So back in 1985, 1985!
So this is just like three or four years
after IP was invented.
Already one sixteenth of the total address space
of those billions of addresses were already consumed.
And then in 2000, fifteen, sixteen years ago,
half of the address space was used
and then in that same year 2000,
two thirds of the address space.
Actually, halfway through 2002.
And now here we are in 2016,
you can imagine it's, it's virtually gone at this point.
So I found that to be a pretty interesting document there.
So now we have an idea as to why IPv6 was needed,
it was because they were running out of addresses.
Okay, so, what does an IPv6 address look like?
The main change with IPv6 is
that the address is four times as big as an IPv4 address;
instead of 32-bits, it is now 128-bits in size, so.
That would be like an IPv6 address.
Now I didn't actually count those bits,
I'm not exactly sure if that's 128 or not,
but in binary, it's a massively large number.
As a matter of fact, I heard someone say a long time ago
that if you think of two to the power or 128,
that's how many combinations of addresses there are,
I don't think there's even a name for that.
Somebody said that there were so many
IPv6 addresses available
that every person could have a unique IPV6 address
for every single hair on their head,
and there would still be an infinite amount left over.
So, hopefully, unless we expand throughout the galaxy
like Star Trek and populate distant planets,
we'll be with IPv6 for a long, long time.
So, we know that in IPv4,
that binary number was divided into octets, into bites.
We have four bites, and then each bite was converted
into a decimal number, and then separated by a dot.
So that was dot a decimal.
They could have done that with this,
but they chose a different approach.
They chose to represent these as hexadecimal numbers.
Hexadecimal?
That's right, I know, we haven't talked
about hexadecimal yet.
So now, I need to do a quick primer on hexadecimal.
It's actually not that hard.
I hope it will not be that hard for you.
So remember, let's go back to our binary tutorial
and our decimal tutorial, 'member how we said that
you have a single placeholder,
and how many potential digits could go in there depends
on what numbering system you're using.
If you're using base 10 decimal,
that means you have 10 possible things
that could go in here, from a zero through a nine, base 10.
If you're using binary, it was base two.
Which means you had two possible combinations,
a zero or a one.
Well, hexadecimal
is a base 16 system, what?
I know, it's so weird, but actually, it's a base 16 system.
So in this one placeholder,
you have 16 possible things that could go in there.
What could those possibly be?
Well, let me make my font here a little bit smaller.
The first 10 digits in hexadecimal
are exactly the same as in decimal.
You have zero,
through nine, so that covers the first 10
out of my 16 possible characters, that's no different.
And then for the remaining characters, we use letters.
So A is the equivalent of 10 in decimal,
B is the equivalent of 11, C is the equivalent of 12,
D, I'm running out of space here.
All right, hold on a second.
Okay, so we have zero through nine,
and then we have our letters.
A equals 10, B equals 11,
C equals 12, D equals 13,
E equals 14, and lastly, F equals 15.
So that give us our 16 possible characters from zero to F,
that's 16 possible combinations.
And also, remember, when we were talking about decimal,
if I had a three-digit number,
the first position was always the ones position,
and then depending on what base system we were using
determined what he next one was.
So in decimal, we just kept multiplying by 10's.
So we had the 10's position next,
10 times 10 is 100, so on and so forth.
With binary, is multiplying by two.
So we had the ones and then we had the twos position,
two times two is four, four times two is eight,
well you can probably see where I'm going with this.
With hexadecimal, we multiply by 16's.
So we have the ones position,
and then the next one is the 16's position,
and 16 times 16 is the 256's,
and after that I can't do it from memory.
(lightly chuckles) I can only do three positions.
So with the way a hexadecimal number would look,
they're not always represented this way,
but if you ever see a number that says 0 x something,
that's representing a hexadecimal number.
So for example, 0x003,
well that's just the number three.
It's no different than in decimal.
But if I say 0x00a, that's the number 10 in hexadecimal.
Or I could say,
and usually the leading zeros are left off.
So if i was gonna give you the hexadecimal number of 10,
I would just say 0xa.
There's only one character,
so that one character has to be in the ones position,
so that's 10 times one, which is 10.
Or I could say 0x1b,
well that means I've got a b in the ones position
and a one in the 16's position,
so that's 16 plus 11, that's 27.
0x1b is 27 in decimal.
Or,
I could go
0x1a3,
that's gonna be a pretty big number.
So that means I have a three in the ones position,
I have a 'a' which is 10 in the 16's position,
and I have a one in the 256's.
So that would be 256
plus 160 because 10 times 16 is 160,
plus three.
Im not gonna add that up in my head,
but whatever number that is,
that would be the decimal equivalent of 0x1a3.
So how does this relate to an IPv6 address?
Alright, so let me actually write a real IPv6 address.
That's one,
two,
three,
four, I'm not gonna do the whole thing,
I'm just gonna do some of it.
Okay, so in reality,
an actual IPv6 address would have eight of these things,
I've drawn one, two, three, four, I've drawn five.
So, still a little bit left over but,
not gonna worry about that right now.
So, how do we actually convert this into a number
that we can read?
Well, what you would do is, starting from left to right,
you would take every four binary characters
and convert that into a hex character.
So that is, in decimal, that's the number two, right?
The ones is off, the two is on, the four is off,
and the eight is off, so that's the number two.
And then we do it again with the next one.
The next four, that's pretty easy,
that's just the number zero,
and then we do it again with the next four.
So we've got the ones position turned on,
and the eights position turn on, so that's nine.
And then we do it one more time.
Now, in decimal, we've got the eight and the four.
So that's the number 12.
But in hexadecimal, we don't say 12, we say C.
So, so far, I've represented 16-bits in binary
by using four hexadecimal characters.
And here's why that's important:
after every 16 binary bits,
or after every four hexadecimal characters, we put a colon,
and then we repeat.
So this'll be zero,
this'll be F,
I gotta put a box around here,
zero, so this one here is F 'cause that's the number 15,
this one right here, we're back to the number 12 again,
no, that's the number 10 actually, the eight and the two,
so that would be an 'a', and then this here is a two,
and then we put a colon.
So an IPv6 address,
because we clearly don't represent it in binary,
is represented as hexadecimal.
So this is what an IPv6 address would actually look like,
I can actually fit this one in here.
Two, I'm just gonna make up one.
2001:00a5:0000:55ea:bbbb:cccc:
now there's gonna be eight of these,
one, two, three, four, five, six,
1111, that's seven, 000c.
So that is an IPv6 address.
And if we actually did the math,
you'd see that this is 128-bits in binary.
Each one of these characters represents 4-bits.
Remember, here's the two, there's 4-bits for that,
here's a zero, that's 4-bits for that,
so if you count up all of these characters
multiplied times four,
that would give you 128-bits in binary.
So that's how an IPv6 address is represented.
You have four hexadecimal characters,
a colon, and then repeat.
And then you'll have a maximum of eight
of these groupings right here.
Actually, I've heard, you know how we say,
I'll write this on here,
you know how we say that 1-unit,
I'll just say, equals a bit.
And 8-bits equals a byte,
well, 16-bits equals what's called a word.
So this is a word.
So you have a colon after every word.
Alright, let's go back to here.
Expressed in hexadecimal instead of decimal.
4-bits equals one hexadecimal character.
And there's an example.
Now before I stop, there are ways,
if the IPv6 address takes a certain format,
there are ways to make it shorter, make it more manageable.
And I'm gonna teach you what those two tricks are
to do that.
And it all has to do with consecutive zeros.
What you're looking for in an IPv6 address
to make it shorter are consecutive zeros.
So let me give you a IPv6 address 2001,
and I'm gonna put some spaces in here.
One, two, three, four, five, six, seven.
Okay, so here is the format for making this shorter.
So the first thing you would look for
in a long address like this
is I would look for a long string of contiguous zeros.
And what I mean by that is look at the address
and ask yourself, "Is there any word,"
and remember, what do I mean by word,
this is a word, this is a word, that's a word, okay?
So you look at your IPv6 address, and you say,
"Is there any word that begins with a zero?"
I'll just put some arrows on the ones that do,
yup, that one does, that one does, that one does,
that one does, that one does, okay, next.
Is there any place in this IPv6 address
where we have a long contiguous string of zeros?
Where it starts at a word and keeps on going.
Well, actually we do.
We have a couple places in here like that.
Here's one that starts at a word
and keeps on going.
Here's one that start with a word
and keeps on going.
Now when you look at that,
each one of those things can be condensed down
by using a special character which is the double colon.
But here's the rule about the double colon.
It can only be used once in an IPv6 address.
Let me give you the logic behind why that's true.
Let's say theoretically that I could use it twice.
Let's say I could do this: 2001, and then colon, colon,
30 colon eaf0 colon
and then we'll just say
colon, colon, 2004.
Let's say theoretically,
that I could type in an IPv6 address like this on my laptop.
Alright, now remember,
when you're entering an IPv6 address into a system,
that system is expecting you to give it 128-bits.
Now it knows that you're typing it in in hexadecimal.
But for every letter or every character you type in,
it's saying, "Okay, there's 4-bits,
"there's another 4-bits."
it's converting it to binary.
So if I typed it in like this,
here's how my system would interpret this.
It would say, "Okay,
"What we've got here is we've got one, two, three, four,
"so this is very easy,
"the human being has provided us all 16-bits
"of that word, all right.
"And then we've got one, two, all right,
"so we've got 8-bits of that word,
"we're missing some stuff,
"and then here we've got another 16-bits of that,
"and then down here,
"we've got another 16-bits supplied to us."
Okay, now the system would say,
"Hmm, okay, let me add this up here.
"16 times three is 48, plus eight is 56."
so my laptop would say,
"This idiotic human
"has only given me
"56-bits of an address
"that requires 128-bits!"
and so the system would say,
"All right, I guess I can assume
"that the remaining bits that are left over are zeros."
But, so okay, how many bits are left over here?
I don't have my calculator in front of me,
so let's just do this real quick here
'cause I can't do that in my head quickly enough.
So 128 minus 56 is 72.
So there's 72-bits missing.
So what if the system said,
"Alright, I'm gonna put maybe 70 zeros here
"and two zeros here,
"or maybe I should split it up equally,
"36 zeros here, and 36 zeros here."
You can see that if it actually allowed you
to put in double colons, there's no way you could figure out
where these zeros were supposed to be.
It just could not figure that out.
That's why we can only put in the double colons once.
And so when selecting it,
it makes sense to only put the double colons to represent
the biggest string of contiguous zeros.
If I'm trying to shorten this thing down,
it makes more sense to represent this big long thing
with the double colon, than it does to represent this.
So let's shorten it down a little bit right now.
So 2001, 0000, 0030, eaf0,
and then I'm gonna do
a double colon to represent that, 2004.
So so far, I've been able to shorten it to this,
I'll put it all together.
So already, you can see that this is much shorter than this,
just by taking this long contiguous string of zeros
and condensing it down with a double colon.
Now I'm gonna emphasize this.
I had to start with a word that began with a zero,
because you might be wondering, why did I start right here?
Because that's not considered a leading zero,
that is a trailing zero,
it trails at the tail end of the word.
I need a zero that leads the word,
and then a string of zeros after that.
That's why I had to start right here.
So that's one thing, a long contiguous string of zeros
that starts with a word
can be replaced with a double colon.
There's one other thing.
After you have what's left,
look and ask yourself, "Do I have any remaining words
"that still start with a zero?"
Well, yeah, that one starts with a zero,
that one starts with a zero.
So in those words,
we can get rid of all of the leading zeros.
So I'm gonna out a line through them.
Those three zeros and that word we can get rid of.
Can't get rid of the zero at the end,
'cause that's a trailing zero,
and we can get rid of these two zeros
because these are leading zeros.
So in its final form,
in its shortest form I could possibly come up with,
so I've now taken it from this black
down all the way to this one here in green.
And that is the shortest way
I could condense an IPv6 address.
Let me give you a couple that you can pause the video on
and practice and see if you can get it right.
You might wanna pause right now
and take a screen shot of this
before I move on to the next one.
Okay.
Okay, go ahead and pause the video,
try to abbreviate or condense this as much as possible
using the rules I just talked about and then press play
when you think you've got your answer.
Okay, so doing the way I did, I would say, once again,
look for any word that begins with a zero,
that one does, that one does,
that one does, that one does.
At that point, look for a long contiguous string of zeros
beginning with a word,
and this is the longest string we have, right there.
So I can get rid of that with my double colon.
And then with what's left over,
draw a line through any of the leading zeros
of any of the remaining words.
So I can get rid of those three,
and that's it.
So the smallest I could make this address
would be 200e:0, gotta leave in the trailing zero,
4000, can't get rid of any of those zeros behind the four
because they're not leading, they're trailing,
600:eade:1100,
so that is the smallest that you could do that one.
Let's do one more.
Okay, go ahead and press pause
and try to condense this one down.
Okay, so once again, let's take a look at any words
that begin with a zero.
That one does, that one does,
actually, no, let me do the entire word.
That one does, that one leads with zeros,
that one leads with zeros,
and this one leads with zeros, okay.
So of this, where are my contiguous string of zeros?
Well, I've got one that starts right here, that ends there,
so that covers seven zeros,
here's one that has just two zeros,
another two, and then four.
So I would say the seven zeros
would be the best way to get rid of those.
And then I'm gonna put a line through the remaining ones,
so I'm gonna be able to cut out those,
'cause those are leading zeros, cut out those,
and I'll be able to cut out these three,
leaving the last one.
So in its final form, this address will look like
2560:1000:ea05::5:ea:3d:0
(light music)