Course: IP Version 4 Addressing And Subnetting Deep Dive (Part 2)
I am currently working on a video course, and I've decided to post my slides and scripts here on STEEM as I go along. I appreciate any feedback or suggestions, or if you are new to the world of computer networking, I hope you enjoy them! Here is part 2 of a multi-part series.
If you missed part 1, click one of the links below for your favorite front end:
An IP address is 32 bits long. A bit within a computer or network device can be represented by a binary number and is how they interpret information. A binary number is simply represented by either a one or a zero. A byte consists of 8 bits.
An IP address is 4 bytes long, which is a total of 32 bits, In decimal form each address is separated in to sections called octets. Each octet is 8 bits or one byte long.
An IP address uses decimal or base 10 numbering when it’s assigned to an interface. At the hardware level these base 10 numbers are converted to binary or base 2. Here is an example of a decimal or base 10 number, 192, converted to binary or base 2.
An IP address is actually a decimal representation of a binary number. This decimal representation is for making the address more human friendly. Which one of these two addresses would be easier to remember? The first one consisting of 12 digits, or the last one consisting of 32 digits.
When a device on the network is processing an IP address, it does so in binary. There are certain operations that we perform on IP addresses that require a basic understanding of binary. This includes subnetting, summarization, verification, determining bit boundaries. and creating wildcard masks.
In this example we break down an IP address into binary, let’s take a look at the technique for accomplishing this.
Each it within a binary number represents a value that starts at one and keeps doubling.
When converting from decimal to binary for an 8 bit number, you can simply choose the largest bit that can fit within the decimal number, and work your way down while adding the values together.
Here are some examples:
For the decimal number zero, all corresponding binary bits are also zero.
For the decimal number 3, the two right most bits (1 & 2)
For the decimal number 47, we set 5 bits (32, 8, 4, 2, & 1)
For the decimal number 48, we set bit 32 and bit 16 to 1, because 32 + 16 = 48
See if you can work out the next two examples yourself
For the decimal number 255, all 8 bits are set to 1, because all 8 values add up to 255. Including zero, this represents a possible 256 binary values.
Here an example of an entire IP address conversion from decimal to binary. Each octet is listed in decimal in the first column, and then converted into binary in each corresponding row.
The subnet mask is a 32-bit number that can accompany an IP address. It is combined with the IP address to determine the point at which the network address ends and the host address begins. This is often referred to as the bit boundary.
It is called a subnet mask, because when you line it up with a corresponding IP address, the ones mask network part of the address, and the zeros mask the host part of the address. It’s easy to tell when the bit boundary falls at the 8, 16, or 24th bit prior to the decimal point. It becomes harder to identify from the subnet mask when the bit boundary falls anywhere else. The act of moving the bit boundary around to manipulate the network size is called variable length subnet masks, which we will address later. In subsequent slides you will see more applications of basic binary math, and learn why it is essential for mastery of IP.
Thanks for reading! If you have any questions about this material or additional remarks or corrections, feel free to drop them in the comments.