Sunday

IP Addressing and Subnetting - Part II

computer & technologyFinding the Answers Without Using Binary

You actually can derive the subnet number and broadcast addresses without ever converting to and from binary, or performing Boolean math. Using the binary math required to find the subnet number and broadcast address really does help you understand subnetting to some degree. To get the correct answers faster on the exam, you might want to avoid all the conversions and binary math.
If you can find the subnet number and broadcast address, you easily can find the range of valid addresses in the subnet. So, the easy math described in this section focuses on helping you find the subnet number and broadcast address.

Easier Math with Easy Masks

Of all the possible subnet masks, three masks, 255.0.0.0, 255.255.0.0, and 255.255.255.0, use only 255s and 0s. I call these masks “easy” masks because you can find the subnet number and broadcast address easily, without any real math tricks. In fact, some of you might have realized already how to find the answers when an easy mask is used—if so, go ahead and skip to the section titled “Easier Math with Difficult Masks.”
In fact, of these three easy masks, 255.0.0.0 does not actually cause any subnetting. So, this section worries about only how to use the two easy masks that can be used for subnetting— 255.255.0.0 and 255.255.255.0.
The process is simple. To find the subnet number, when given an IP address and a mask of 255.255.0.0 or 255.255.255.0, do the following:
Step 1 Copy the first two (mask 255.255.0.0) or first three (mask 255.255.255.0) octets from the original IP address.
Step 2 Write down 0s in the last two octets (mask 255.255.0.0) or the last octet (mask 255.255.255.0).
Yep, it’s that easy! Finding the subnet broadcast address is just as easy:
Do the same thing that you did for finding the subnet, but instead of writing down 0s in the last octet or two, write down 255s.
When you know the subnet number and broadcast address, you easily can find the first and last IP addresses in the subnet, using the same simple logic covered earlier:
o To find the first valid IP address in the subnet, copy the subnet number, but add 1 to the fourth octet.
o To find the last valid IP address in the subnet, copy the broadcast address, but subtract 1 from the fourth octet.

Easier Math with Difficult Masks

When the subnet mask is not 255.255.0.0 or 255.255.255.0, I consider the mask to be a difficult mask. Why is it difficult? Most people cannot easily derive the subnet number and broadcast address without using binary math. You can use the same binary processes exactly the same way, whether the mask is easy or difficult. However, these binary processes take time to do when you cannot use a calculator. So, a quicker method for finding the same answers can help.
The following process helps you find the subnet number and broadcast address without binary math when using a difficult mask. You also can find 25 more problems with solutions on the CD chapter titled, “Subnetting Practice: 25 Subnetting Questions.” The process uses something I call a subnet chart, as shown in Table 12-25.



With the type of question this shortcut is helping you to answer, the question supplies the address and subnet mask. So, you would simply record the IP address and mask in the table, putting each octet in a different column.
The unusual part of this shortcut begins when you draw a box around the “interesting” octet in the table. I call a mask octet that’s not a 255 or a 0 the interesting octet because it is the octet that gives everyone heartburn when first learning subnetting. The box draws attention to the tricky part of the logic used in this shortcut.
For example, consider 130.4.102.1, with mask 255.255.252.0. Because the third octet of the mask is not a 0 or a 255, the third octet is where the interesting part of the shortcut takes place.

So, you would create a subnet chart, fill in the address and mask, and draw a box around the third octet, as shown in Table 12-26.



Next, you should complete the chart for everything to the left of the box. To complete the chart, look at the original IP address octets to the left of the box, and copy those into the subnet, first valid address, broadcast, and last valid address fields. Note that only octets fully to the left of the box should be copied—the interesting octet, which is inside the box, should not be copied. Table 12-27 shows the same example, after this step.



To find the subnet number, you have a couple of steps. The first step is easy. In the subnet number, for any octets fully to the right of the box, write down a 0. That should leave you with one octet of the subnet number missing—the interesting octet.
Next comes the tricky part of this shortcut, which gives you the value of the subnet number in the interesting octet. First, you find what I will call the magic number —which is 256 minus the mask’s interesting octet . In this case, you have 256 – 252, or a magic number of 4. Then you find the multiple of the magic number that is the closest to the address’s interesting octet , but less than or equal to it. In this example, 100 is a multiple of the magic number (4 * 25), and this multiple is less than or equal to 102. The next-higher multiple of the magic number, which is 104, is, of course, more than 102, so that’s not the right number. The multiple of the
magic number closest to but not more than the address’s interesting octet is the subnet’s interesting octet value. The following items summarize this important step:
Step 1 Find the magic number, which is 256 minus the value of the mask’s interesting octet.
Step 2 Find the multiple of the magic number that is closest to, but not greater than, the address’s interesting octet.
Step 3 Write down that multiple of the magic number as the value of the subnet number’s interesting octet.
In this example, simply plug in 100 for the third octet of the subnet number in Table 12-27. When you know the subnet number, you easily can find the first valid IP address in the subnet:
To find the first valid IP address in the subnet, copy the subnet number, but add 1 to the fourth octet.
That’s all! Table 12-28 shows the same example, but with the subnet number and first valid IP address shown



To review, in Table 12-28, the first two octets of the subnet number and first valid address already were filled in because they are to the left of the box around the third octet—the interesting octet, in this case. In the subnet number, the last octet is 0 because it is to the right of the box. To find the interesting octet value, compare the IP address’s interesting octet to find the closest multiple of the magic number that’s not larger, which is 100 in this case. To get the first valid address, just add 1 to the last octet of the subnet number, giving you 130.4.100.1.
The final step in the shortcut finds the broadcast address, from which you easily can find the last valid address in the subnet. First, in the broadcast address, write down a decimal 255 for all octets to the right of the line or the box. Do not write down a 255 in the octet inside the box. Remember, the octets to the left of the box in the subnet chart already should have been filled in, leaving a single octet with no value—the interesting octet. To fill in the interesting octet of the broadcast address, you again use the magic number. The magic number is 256 minus the mask’s interesting octet. In this case, you have 256 – 252, or a magic number of 4. Then you add the magic number to the interesting octet value of the subnet number and subtract 1. The result is the broadcast address’s value in the interesting octet. In this case, the value is as follows:
100 + 4 (magic number) – 1 = 103 When you know the broadcast address, you easily can find the last valid IP address in the subnet:
To find the last valid IP address in the subnet, copy the broadcast address, but subtract 1 from the fourth octet.
To summarize the tricky part of this shortcut algorithm:
To find the broadcast address’s interesting octet value, take the subnet number’s interesting octet value, add the magic number, and subtract 1.
Table 12-29 shows the completed answers, with annotations.



The entire process for dissecting IP addresses that use difficult masks is now complete. The following list summarizes the tasks in each step:
Step 1 Create and complete the easy parts of a subnet chart.
■ Create a generic subnet chart.
■ Write down the IP address and subnet mask in the first two rows of the chart.
■ Draw a box around the column of the interesting octet.
■ Copy the address octets to the left of the line or the box into the final four rows of the chart.
Step 2 Derive the subnet number and the first valid IP address.
■ Write down 0s in the subnet number for the octets to the right of the box.
■ Find the magic number, which is 256 minus the value of the mask’s interesting octet.
■ Find the multiple of the magic number that is closest to but not greater than the address’s interesting octet.
■ Write down that multiple of the magic number as the value of the subnet number’s interesting octet.
■ To find the first valid IP address in the subnet, copy the subnet number, but add 1 to the fourth octet.
Becoming proficient at this shortcut will take some practice. To make sure you have the process down, review the examples in the CD chapter, “Subnetting Practice: 25 Subnetting Questions,” which has 25 different examples, including the Boolean AND and shortcut methods of finding the subnet number.

What Subnet Masks Meet the Stated Design Requirements?

So far in this chapter, the text has explained how to answer questions that provide the subnet number. However, some questions do not supply the subnet number, but instead ask you to choose the “correct” subnet mask, given a set of requirements. The most common of these questions reads something like this:
You are using Class B network X, and you need to have 200 subnets, with at most 200 hosts per subnet. Which of the following subnet masks can be used? (followed by some subnet masks that you can pick from for the answer)
The find the correct answers to these types of questions, you first need to decide how many subnet bits and host bits you need to meet the requirements. Basically, the number of hosts per subnet is 2 x – 2, where x is the number of host bits in the address. Likewise, the number of subnets of a network, assuming that the same subnet mask is used all over the network, is also 2 x – 2, but with x being the number of subnet bits. When you know how many subnet bits and host bits are required, you can figure out what mask, or masks, meet the stated design goals in the question.
Examples certainly help; the first example question reads like this:
Your network can use Class B network 130.1.0.0. What subnet masks meet the requirement that you plan to allow at most 200 subnets, with at most 200 hosts per subnet?
First, you need to figure out how many subnet bits allow for 200 subnets. You simply can use the formula 2 x – 2 and plug in values for x, until one of the numbers is at least 200. In this case, x turns out to be 8—in other words, you need at least 8 subnet bits to allow for 200 subnets.
If you do not want to keep plugging in values into the 2 x – 2 formula, you can instead memorize Table 12-30.



As you can see, if you already have the powers of 2 memorized, you really do not need to memorize the table—just remember the formula.
As for the first example question, 7 subnet bits are not enough because that allows for only 126 subnets. You need 8 subnet bits. Similarly, because you need up to 200 hosts per subnet, you need 8 host bits.
Finally, you need to decide somehow what mask(s) to use, knowing that you have a Class B network and that you must have at least 8 subnet bits and 8 host bits. Using the letter N to represent network bits, the letter S to represent subnet bits, and the letter H to represent host bits, the following text shows the sizes of the various fields:
NNNNNNNN NNNNNNNN SSSSSSSS HHHHHHHH
All that is left is to derive the actual subnet mask. Because you need 8 bits for the subnet field and 8 for the host field, and the network field takes up 16 bits, you already have allocated all 32 bits of the address structure. So, only one possible subnet mask works. To figure out the mask, you need to write down the 32-bit subnet mask, applying the following fact and subnet masks:
The network and subnet bits in a subnet mask are, by definition, all binary 1s. Similarly, the host bits in a subnet mask are, by definition, all binary 0s.
So, the only valid subnet mask, in binary, is this:
11111111 11111111 11111111 00000000
When converted to decimal, this is 255.255.255.0.
A second example shows how the requirements stated in the question might allow for multiple possible subnet masks. For instance:
Your network can use Class B network 130.1.0.0. What subnet masks meet the requirement that you plan to allow at most 50 subnets, with at most 200 hosts per subnet?
For this design, you still need at least 8 host bits, but now you need only at least 6 subnet bits. Six subnet bits would allow for 2 6 – 2, or 62, subnets. Following the same convention as before, but now using an x for bits that can be either subnet or host bits, the format of the address struture would be as follows:
NNNNNNNN NNNNNNNN SSSSSS XX HHHHHHHH
In other words, the addresses will have 16 network bits, at least 6 subnet bits, and at least 8 host bits. This example actually allows for three valid subnet masks, whose strcuture are as follows:
NNNNNNNN NNNNNNNN SSSSSS SS HHHHHHHH—8 subnet, 8 host NNNNNNNN NNNNNNNN SSSSSS SH HHHHHHHH—7 subnet, 9 host NNNNNNNN NNNNNNNN SSSSSS HH HHHHHHHH—6 subnet, 10 host
So, based on the requirements in the question, three different valid subnet masks meet the requirements. The three values are as follows:
11111111 11111111 111111 11 00000000 255.255.255.0 11111111 11111111 111111 10 00000000 255.255.254.0 11111111 11111111 111111 00 00000000 255.255.252.0
The 2 bits that could be subnet bits or host bits, based on the requirements, are shown in bold.

What Are the Other Subnet Numbers?

The final general type of IP addresing and subnetting question covered in this chapter asks you to list all the subnets of a particular network. You could use a long process, which requires you to count in binary and convert many numbers from binary to decimal. However, because most people would either learn the shortcut or use a subnet calculator in their normal jobs, I decided to just show you the shortcut method for this particular type of question.

First, the question needs a better definition—or, at least, a more complete one. The question might be better stated like this:
If the same subnet mask is used for all subnets of this Class A, B, or C network, what are the valid subnets?
IP design conventions do not require the engineer to use the same mask for every subnet. Unless specifically stated, the question “What are all the subnets?” probably assumes that the same mask is used for all subnets, unless the question specifically states that different masks can be used on different subnets.
The following easy decimal process lists all the valid subnets, given the network number, and the only mask used on that network. This three-step process assumes that the size of the subnet part of the address is, at most, 8 bits in length. The same general process can be expanded to work when the size of the subnet part of the address is more than 8 bits, but that expanded process is not described here.
The three-step process uses a chart that I call the subnet list chart . I made up the name just for this book, simply as another tool to use. Table 12-31 presents a generic version of the subnet list chart.



You list the known network number and subnet mask as the first step in the process. If the question gives you an IP address and mask instead of the network number and mask, just write down the network number of which that IP address is a member. (Remember, this three-step process assumes that the subnet part of the addresses is 8 bits or less.)

For the second of the three steps, copy the network number into the row labeled “Subnet Zero.”
Subnet zero , or the zero subnet , is numerically the first subnet, and it is one of the two reserved subnet numbers in a network. (You can use the zero subnet on a Cisco router if you configure the global configuration command ip zero-subnet .) Interestingly, a network’s zero subnet has the exact same numeric value as the network itself—which is one of the reasons that it should not be used. For the purposes of answering questions on the exam about the number of valid subnets in a network, consider the zero subnet unusable unless the question tells you that using
it is ok. In real life, do not use the zero subnet if you do not have to.
The third step in the process will be covered after Tables 12-32 and 12-33, which list two familiar examples, with the first two steps completed.



The last step in this process, Step 3, is repeated many times. This last step uses the magic number, which is 256 minus the mask octet value in the interesting octet. With this process of finding all the subnet numbers, the interesting octet is the octet that contains all of the subnet part of the addresses. (Remember, the process assumes 8 or fewer subnet bits!) In both Tables 11-32 and 11-33, the interesting octet is the third octet.
The third and final step in the process to find all the subnet numbers goes like this: Starting with the last row that’s completed in the table, do the following:
• Because this process assumes 1 byte or less in the subnet part of the addresses, on the next row of the table, copy down the three octets that are not part of the subnet field. Call the octet that is not copied down the “subnet octet” or “interesting octet.”
• Add the magic number to the previous subnet octet, and write that down as the value of the subnet octet.
• Repeat the last two tasks until the next number that you would write down in the subnet octet is 256. (Don’t write that one down—it’s not valid.)
The idea behind the process of finding all the subnets becomes apparent by reviewing the same two examples used earlier. First, Table 12-34 lists the example with the easy mask. Note that the magic number is 256 – 255 = 1 in this case, and that the third octet is the interesting subnet octet.



The logic behind how the process works might be better understood by looking at the first few entries and then the last few entries. The zero subnet is found easily because it’s the same number as the network number. The magic number is 256 – 255 = 1, in this case. Essentially, you increment the third octet (in this case) by the magic number for each successive subnet number.
In the middle of the table, one row is labeled “Skipping a Bunch.” Instead of making the book even bigger, I left out several entries but included enough that you could see that the subnet number’s third octet just gets bigger by 1, in this case, for each successive subnet number.
Looking at the end of the table, the last entry lists 255 in the third octet. 256 decimal is never a valid value in any IP address, and the directions said to not write down a subnet with 256 in it, so the last number in the table is 130.4.255.0. The last subnet is the broadcast subnet, which is the other reserved subnet number. The subnet before the broadcast subnet is the highest, or last, valid subnet number.
With a simple subnet mask, the process of answering this type of question is very simple. In fact, many people might even refer to these subnets using just the third octet. If all subnets of a particular organization were in network 130.4.0.0, with mask 255.255.255.0, you might say simply “subnet five” when referring to subnet 130.4.5.0.
The process works the same with difficult subnet masks, even though the answers are not as intuitive. Table 12-35 lists the answers for the second example, using a mask of 255.255.252.0
The third octet is again the interesting subnet octet, but this time the magic number is 256 – 252 = 4.



The first subnet number numerically, the zero subnet, starts the list. By adding the magic number in the interesting octet, you find the rest of the subnet numbers. Like the previous example, to save space in the book, many subnet numbers were skipped.
Most of us would not guess that 130.4.252.0 was the broadcast subnet for this latest example.

However, adding the magic number 4 to 252 would give you 256 as the next subnet number, which is not valid—so, 130.4.252.0 is indeed the broadcast subnet.
The three-step process to find all the subnet numbers of a network is shown here:
1. Write down the network number and subnet mask in the first two rows of the subnet list chart.
2. Write down the network number in the third row. This is the zero subnet, which is one of the two reserved subnets.
3. Do the following two tasks, stopping when the next number that you would write down in the interesting column is 256. (Don’t write that one down—it’s not valid.)
a. Copy all three noninteresting octets from the previous line.
b. Add the magic number to the previous interesting octet, and write that down as the value of the interesting octet.

Scaling the IP Address Space for the Internet

The original design for the Internet required every organization to ask for and receive one or more registered IP network numbers. The people administering the program ensured that none of the IP network numbers was used by multiple companies or organizations. As long as every organization used only IP addresses inside their own registered network numbers, then IP addresses would never be duplicated and IP routing could work well.
Connecting to the Internet using only a registered network number or several registered network numbers worked very well for a while. In the early and mid-1990s, it became apparent that the Internet was growing so fast that all IP network numbers would be assigned by the mid-1990s.

Concern arose that all the network numbers would be assigned, so some organizations would not be capable of connecting to the Internet. It would have been the equivalent of calling the local phone company to ask for a new phone line to be installed and being told that the company ran out of numbers; you would have to wait until someone didn’t want a phone number any more!
This last section covers several features that together have allowed the Internet to grow, without letting us run out of IP addresses. Network Address Translation (NAT), along with a feature called private addressing , allows organizations to use unregistered IP network numbers internally and still communicate well with the Internet. Classless Interdomain Routing (CIDR) allows Internet service providers (ISPs) to reduce the wasting of IP addresses, by assigning a company a subset of a network number instead of the entire network. CIDR also reduces the size of Internet routing tables, allowing the Internet to grow. Also, a new version of IP, IP Version 6, uses much larger addresses, 128-bit long addresses, which allow for (hopefully) enough IP addresses so that we will never possibly run out again.

CIDR

CIDR is a convention defined in RFC 1817 (www.ietf.org/rfc/rfc1817.txt) that calls for aggregating multiple network numbers into a single routing entity. CIDR actually was created to help the scalability of Internet routers—imagine a router in the Internet with a route to every Class A, B, and C network on the planet! There are actually a little more than two million Class C networks alone! By aggregating the routes, Internet routers have a significantly smaller number of routes in their routing tables.



Imagine that ISP 1 owns Class C networks 198.0.0.0 through 198.255.255.0 (they might look funny, but they are valid Class C network numbers). Without CIDR, all other ISPs’ routing tables would have a separate route to each of the 2 16 Class C networks that begin with 198. With CIDR, as the illustration shows, the other ISPs’ routers will have a single route to 198.0.0.0/8—in other words, a route to all hosts whose IP address begins with 198. More than two million Class C networks alone exist, but CIDR has helped Internet routers reduce their routing tables to a more
manageable size, in the range of 120,000 routes by mid-2003.
By using a routing protocol that exchanges the mask as well as the subnet/network number, a classless view of the number can be attained. In other words, routers treat the grouping as a math problem, ignoring the Class A, B, and C rules. For instance, 198.0.0.0/8 (198.0.0.0, mask 255.0.0.0) defines a set of addresses whose first 8 bits are equal to decimal 198. This route is advertised by ISP 1 to the other ISPs, which need a route only to 198.0.0.0/8. In its routers, ISP 1 knows which Class C networks are at which customer sites. This is how CIDR gives Internet
routers a much more scalable routing table, by reducing the number of entries in the tables.
For CIDR to work as shown in Figure 12-5, ISPs need to be in control of consecutive network numbers. Today IP networks are allocated by administrative authorities for various regions of the world, which, in turn, allocate consecutive ranges of network numbers to particular ISPs in those regions. This allows summarization of multiple networks into a single route, as shown in Figure 12-5.
CIDR also helps to reduce the chance that we will run out of IP addresses for new companies connecting to the Internet. CIDR also allows an ISP to allocate a subset of a Class A, B, or C network to a single customer. For instance, imagine that ISP 1’s Customer 1 needs only 10 IP addresses and that Customer 3 needs 25 IP addresses. So, ISP 1 does something like this:
It assigns IP subnet 198.8.3.16/28, with assignable addresses 198.8.17 to 198.8.30, to Customer 1. For Customer 3, ISP 1 suggests 198.8.3.32/27, with 30 assignable addresses (198.8.3.33 to 198.8.3.62). (Feel free to check the math with the IP addressing algorithms listed earlier.)
CIDR helps prevent the wasting of IP addresses, thereby reducing the need for registered IP network numbers. Instead of the two customers consuming two whole Class C networks, each consumes a small portion of a single Class C network. At the same time, CIDR, along with the intelligent administration of consecutive network numbers to each ISP, allows the Internet routing table to support a much smaller routing table in Internet routers than otherwise would be required.

Private Addressing

Some computers will never be connected to the Internet. These computers’ IP addresses could be duplicates of registered IP addresses in the Internet. So, when designing the IP addressing convention for such a network, an organization could pick and use any network number(s) that it wanted, and all would be well. For instance, you can buy a few routers, connect them together in your office, and configure IP addresses in network 1.0.0.0 and make it work. The IP addresses
that you use might be duplicates of real IP addresses in the Internet, but if all you want to do is learn on the lab in your office, all is well.
When building a private network that will have no Internet connectivity, you also can use IP network numbers called private internets , as defined in RFC 1918, “Address Allocation for Private Internets” (www.ietf.org/rfc/rfc1918.txt). This RFC defines a set of networks that never will be assigned to any organization as a registered network number. Instead of using someone else’s registered network numbers, you can use numbers in a range that are not used by anyone in the public Internet. Table 12-36 shows the private address space defined by RFC 1918.



In other words, any organization can use these network numbers. However, no organization is allowed to advertise these networks using a routing protocol on the Internet.
Many of you might be wondering, “Why bother reseverving special private network
numbers when it doesn’t matter whether the addresses are duplicates?” Well, as it turns out, you can use private addressing in a network and use the Internet at the same time, as long as you use the next feature covered in this chapter—Network Address Translation (NAT).

Network Address Translation

NAT, defined in RFC 1631, allows a host that does not have a valid registered IP address to communicate with other hosts through the Internet. Of course, if you do not have to use a registered IP address, you can help avoid the day when we run out of available IP addresses! NAT allows these addresses that are not Internet-ready to continue to be used but still allows communication with hosts across the Internet. The ICND exam covers NAT in more detail, including configuration.
To conserve addresses, NAT uses an additional feature called Port Address Translation (PAT). PAT takes advantage of the fact that a server really does not care whether it has one connection each to three different hosts, or three connections to a single host IP address. So, to support lots of private IP addresses with only one or a few publicly registered IP addresses, NAT/PAT translates the private IP address into a valid public address as the packet exits the private IP
network. However, instead of just translating the IP address, it also translates the port number.

Figure 12-6 outlines the logic.



The NAT router keeps a NAT table entry for every unique combination of private IP address and port, with translation to the public IP address and a unique port number associated with the public IP address. Because the port number field has 16 bits, NAT/PAT can support more than 64,000 connections using one public IP address, which helps the IP address space scale.

IP Version 6 Addressing

The short-term solution to the problem of depleting the entire IPv4 address space included NAT and private addressing. CIDR provider a short-term solution to the growing size of IP routing tables. The long-term solution to both problems, at least according to some, is to use a new version of the IP protocol—Version 6 (IPv6). (The version discussed in this book is Version 4.

Version 5 was defined for experimental reasons and never was deployed.)
IPv6 calls for a much larger address structure so that the convention of all organizations using unique groupings (networks) of IP addresses still would be reasonable—the numbers of IPv6-style networks would reach into the trillions and beyond. That solution is still technically viable and possibly one day will be used. However, many people believe that the short-term solutions have made IPv4 viable for a long time, and they see no reason to upgrade. Others think that IPv6 is inevitable. Cisco simply supports both options, so whatever happens, it will still be able to sell products.
IPv6 uses a 128-bit IP address written in hexadecimal notation, with colons between each quartet of symbols. How many addresses can you possibly have with a 128-bit number? The only answer that matters in real life is “more than you can possibly ever need.” The number is around 3.4 × 10 38 —yes, that’s a 39-digit decimal number. It’s huge! You could have a million IP addresses per every person who ever has lived and still not have run out. So, a migration to IPv6 certainly looks like it solves the IP address scalability problem—the only question is whether the other short-term solutions, such as NAT and CIDR, have solved IPv4’s problems so well that no one wants to migrate to IPv6.
Table 12-37 summarizes some of the pertinent information comparing IPv4 addresses with IPv6



Foundation Summary

The “Foundation Summary” section of each chapter lists the most important facts from the chapter.
Although this section does not list every fact from the chapter that will be on your CCNA exam(s), a well-prepared CCNA candidate should know, at a minimum, all the details in each “Foundation Summary” section before going to take the exam.
The thought process used to answer questions about the number of hosts and subnets in a network, based on a network number and a subnet mask, is summarized in the following list:
A formal definition of the “algorithm” to find the first and last IP addresses in a subnet when the subnet number and broadcast addresses are known is as follows:
■ For the first valid IP address: Copy the subnet number, but add 1 to the fourth octet.
■ For the last valid IP address: Copy the broadcast address, but subtract 1 from the fourth octet.
■ The range of valid IP addresses starts with the first number and ends with the last. To find the subnet number, perform a Boolean AND between the address and the subnet mask. For example, see Table 12-38.



To find the subnet broadcast address, take the subnet number in binary and change all the host bits to binary 1s.
The following three-step process lists all the subnet numbers of a network. The process refers to the chart that follows the three-step list:
Step 1 Write down the network number and subnet mask in the first two rows of the subnet list chart.
Step 2 Write down the network number in the third row. This is the zero subnet, which is one of the two reserved subnets.
Step 3 Do the following two tasks, stopping when the next number that you would write down in the interesting column is 256. (Don’t write that one down—it’s not valid.)
a. Copy all three noninteresting octets from the previous line.
b. Add the magic number to the previous interesting octet, and write that down as the value of the interesting octet. (See Table 12-39).



=================================================


Quiz7: IP Adressing & Subnetting

1) (1 marks)
PC1 is using TCP, has a window of 4, and sends four segments numbered 2, 3, 4, and 5 to PC2. PC2 replies with an acknowledgment number 5. What should PC1 do next?
Increase its window to five segments
Increase its window by five more segments, for a total of nine
Send segment 6
Resend segment 5
Resend segments 2 through 5
Leave blank

2) (1 marks)
Which of the TCP connection-establishment flows sets both the SYN and ACK flags in the TCP header?
First segment
Second segment
Third segment
Fourth segment
Fifth segment
Leave blank

3) (1 marks)
Which of the following functions is performed by TCP and UDP?
Windowing
Error recovery
Multiplexing
Routing
Encryption
Ordered data transfer
Leave blank

4) (1 marks)
Which of the following header fields identifies which TCP/IP application gets data received by the computer?
Ethernet Type
802.3 DSAP
SNAP Protocol Type
IP Protocol Field
TCP Port Number
UDP Port Number
Application ID
Congestion Avoidance
Leave blank

5) (1 marks)
Data that includes the Layer 4 protocol header, and data given to Layer 4 by the upper layers, not including any headers and trailers from Layers 1 to 3, is called what?
Bits
Chunk
Segment
Packet
Frame
L5PDU
L4PDU
L3PDU
L2PDU
Leave blank


Share/Bookmark

0 comments:

Post a Comment

Link To Your Site