











|  |
General_Maximus
Member
Registered: Nov 2000 Location: Country: United States State: Certifications: CCNA Working on: CCNP, CCDA
Total Posts: 78
|
|
this is from net acad. (2nd pargraph)website. they are talking about a class b address that borrows 7 bits. my question is, how do they come up with the final 8 bits in the last sentence? there wasn't any place on the website, or pictures that went along with it where I could make sense out of it.
"Again, someone outside the network sends data to an IP address, 172.16.2.160. In order to determine where to send the data, the router "ands" this address with the subnet mask. Again, when the two numbers are "anded" by the router," the host portion of the address falls through. What is left is the network number including the subnetwork. Thus, in this example, the data is being addressed to the device that is identified by the binary number 10100000".
Report this post to a moderator
|
|
01-09-01 04:57 AM
|
|
lennon57
Certified Geek
Registered: Oct 2000 Location: San Diego, CA Country: United States State: Certifications: A+, Network+, CCNA Working on: Putting my brain back together
Total Posts: 575
|
|
General-
I can see where they come up with the host IP being 160 (binary 10100000 = 160)
If they are "anding it" to the subnet 255.255.255.0 then I could see that.
When something is 'anded' digitaly, then both inputs must be true for the output to be true.
i.e. a=1 AND b=1 then c=1
a=0 AND b=1 then c=0
a=1 AND b=0 then c=0
Applying that to the IP, then the Network would be 172.16.2 and the host would be 160 since that would fall through as 'not a network address'.
Hope that helps. My best guess on the question.
Report this post to a moderator
|
|
01-09-01 05:59 AM
|
|
The Reamer
Moderator M
Registered: Apr 2000 Location: Atlanta, GA Country: USA State: Certifications: MCP, MCSE, MCT, CCNA, CCDA, CCNP Working on: CCDP, CCIE
Total Posts: 513
|
|
When you look at the binary translation of both the address and mask for anding purposes, concentrate on the octet where the subnetting is taking place (the octet without all 1's). In this example, they tell you that 7 bits are borrowed in this class b address. This equates to 254, or in binary 11111110. And of course in the third octet of the address is 2 or 00000010. Putting them together for anding gives you:
00000010=2
11111110=254
--------
00000010=2
This to me is a classic example of how you could get confused by the information given. The seven bits borrowed is just so you can do the binary for "anding," not for calculating the number of subnets or hosts. Just remember any portion of the address that comes down after anding is the network.
HTH!
Reamer
Report this post to a moderator
|
|
01-09-01 07:38 AM
|
|
dmaftei
Senior Member M
Registered: Nov 2000 Location: Country: USA State: Certifications: none Working on: none
Total Posts: 2156
|
|
quote: Originally posted by General_Maximus:
my question is, how do they come up with the final 8 bits in the last sentence?
This is your real question, right? Although lennon57 and The Reamer explaind it already, let's do the "anding" again (for reference ).
10101100.00010000.00000010.10100000 (172.16.2.160)
11111111.11111111.11111110.00000000 (255.255.254.0)
What corresponds to the "1"s in the mask gives you the net (pad with "0"s to the right):
10101100.00010000.00000010.00000000 (172.16.2.0)
What corresponds to the "0"s in the mask gives you the host (pad with "0"s to the left):
00000000.00000000.00000000.10100000 (0.0.0.160)
You know that you subnetted with 7 bits, so the host should be 9 bits (the rightmost 9 bits, corresponding to the 9 "0"s in the mask). That's 010100000, which is 160 . I guess the net acad guys dropped the initial zero (by mistake, of course). If you look again at that paragraph, they never talk about "8 bits"; they say "binary number".
So, I would say a small typo...
Cheers!
[This message has been edited by dmaftei (edited 01-08-2001).]
Report this post to a moderator
|
|
01-09-01 08:05 AM
|
|
General_Maximus
Member
Registered: Nov 2000 Location: Country: United States State: Certifications: CCNA Working on: CCNP, CCDA
Total Posts: 78
|
|
|
01-09-01 11:30 AM
|
|
|
Forum Rules: Who Can Read The Forum? Any registered user or guest.
Who Can Post New Topics? Any registered user.
Who Can Post Replies? Any registered user.
Changes: Messages can be edited by their author.
Posts: HTML code is OFF. Smilies are ON. vB code is ON. [IMG] code is ON. |
|
ExamNotes forum archive
|