In this chapter we're going to learn all about protocols, the rules of networking. We'll also learn how to work with binary numbers.
We're used to the idea of a protocol. A protocol is a set of rules or standards that everyone agrees to. When we go to the store and purchase a lamp we know the plug will work with your outlets at home. The outlets at home all follow the same rules, so any electronic device will work.
In the networking world we have the same idea. We have a series of rules that we've all agreed to follow. These rules are called protocols. If both sides of the connection use the same rules then we have communication. This is the equivalent of a common language when we refer back to our elements of communication from Lesson 01.
If you have wireless at home all your wireless devices connect to the network easily. You may have to type in a complicated password, but once that's done the device is on the network. Guests are able to connect to your network easily. This is because we have those standards, or protocols, that everyone agreed to. If we didn't have these protocols we would have the following situation:
Without the standards, or protocols, each vendor would have to create their own solution for connecting devices together. This would cause things to be incompatible with each other. Without these protocols the Internet as we know it wouldn't be possible.
Sending the Data
Splitting the Data
Sadly computers and network equipment/cabling are not perfect. We can't assume all the data we send will arrive correctly. There's a chance some 1's will change to 0's or visa versa. There is also the chance some 1's and 0's will get lost or dropped along the way. If we send a very long stream of data and it fails along the way we would have to send the entire stream again. Instead of sending the entire stream of data in one burst we split the data into smaller chunks and send them separately. We will generically refer to this chunk of data as a packet for now.
With the data split into packets we can now easily do error recovery. Error recovery is when you're expecting a certain number of packets, but some in the middle are either missing or damaged and steps are taken to request the missing packets. For example if you're sending data that needs to be split into 5 packets they'll be labeled (1 of 5), (2 of 5), (3 of 5), (4 of 5), and (5 of 5). If the receiving computer is missing (2 of 5) it will ask for packet 2 to be retransmitted.
In later lessons you'll need to know how to work with binary numbers. We're used to a base 10 system, or decimal, where we have 10 digits to work with. (0-9) In the decimal system each digit represents how many of each place value are present. In the decimal number 42 we have 4 10's and 2 ones. 40 + 2 = 42. Each place value is a multiple of 10, as you move to the left each place value 10 times the previous value.
Binary is a base 2 numbering system where we only have two digits to work with. (0-1) We have place values just like a decimal number, but they represent different values. In binary as you move left each place value is 2 times the previous value starting with 1.
Since we only have two digits in the binary system each place value can only be a 0 or 1, or turned on, or off. If you want to convert a binary number to decimal you take the bits that are turned on, or 1's, and add them together. The binary number 101 is 5 in decimal because the 4 place and 1 place are both turned on, or 1. We add 4 + 1 to get 5.
Here are a few more examples of binary numbers converted to decimal. In each example the place values with 1's are added together giving use the decimal value.
For example if you're given the number 42 and you want to convert it to binary you would find the biggest binary place value that fits. In this case 64 is too big so we use 32. Turn off 128, and 64 by placing 0's then turn on 32 by placing a 1 in the 32 place value. Then subtract 32 from 42.
Now we repeat the process with the result. Find the largest place value we can subtract from 10. 16 is too large, but 8 will work. Let's turn off 16 and turn on 8 and subtract 8 from 10.
Now we're left with 2. We know we can't use 4 so turn it off and turn on 2. Then subtract 2 from 2.
The result is 0, this is how you know you're done. Place 0's for all the remaining value and you'll have the binary value that represents the decimal number 42. 00101010
Protocols go through a process before they become standards. The IETF or Internet Engineering Task Force represents the group of individuals responsible for maintaining the specifications of these protocols. Before a protocol is adopted as a standard a proposal is written up and published for review. The published proposal is called an RFC or Request For Comment. Others will make suggestions and identify problem areas and the RFC will be updated. Once the members of the IETF agree on all the specifications the standard will become official.
The ISO (International Standards Organization) was working on their own layered approach to networking around the same time TCP/IP was being developed. TCP/IP became the dominant standard and is what's used by all our devices, but there is a lot of crossover between the two models. The OSI Model (Open System Interconnect) is a 7 layer networking model used primarily as an educational tool and discussion point when referring to the layers. Anyone in the networking world need to know about the OSI model.
As you work in the different layers of the TCP/IP and OSI models there will be some terms that change depending on the layer on which you're working. The name of the addresses, and the chunks of data created are different at each layer. So far we have been referring to the chunks of data as packets, but you will find that is not an entirely accurate term at each layer. As we progress through the course make sure you're able to identify the data names and address types at each layer. The image below will be filled out with more information as the course progresses. It will be important to know this information.
The next 5 lessons cover each of the 5 layers of the TCP/IP model. We will look at the Physical Layer then the Data Link Layer. After that we'll jump to the top and look at the Application Layer and work our way down, hitting the Transport Layer, and finally the Internetwork Layer.