• cleveland gay chat

    Answered By:
    free gay chat nrooms
  • free gay twink dating

    Answered By:
    busted for using someone's photo in a gay dating website
  • free gay/bi-sex chat sites

    Answered By:
    gay sissie chat
  • 1collecting

    Answered By:
  • IP subnets exist to allow routers to choose appropriate destinations for packets. You can use IP subnets to break up larger networks for logical reasons (firewalling, etc), or physical need (smaller broadcast domains, etc).


    Simply put, though, IP routers use your IP subnets to make routing decisions. Understand how those decisions work, and you can understand how to plan IP subnets.


    Counting to 1


    If you are already fluent in binary (base 2) notation you can skip this section.


    For those of you who are left: Shame on you for not being fluent in binary notation!


    Yeah-- that may be a bit harsh. It's really, really easy to learn to count in binary, and to learn shortcuts to convert binary to decimal and back. You really should know how to do it.


    Counting in binary is so simple because you only have to know how to count to 1!


    Think of a car's "odometer", except that unlike a traditional odometer each digit can only count up to 1 from 0. When the car is fresh from the factory the odometer reads "00000000".


    When you've driven your first mile the odometer reads "00000001". So far, so good.


    When you've driven your second mile the first digit of the odometer rolls back over to "0" (since it's maximum value is "1") and the second digit of the odometer rolls over to "1", making the odometer read "00000010". This looks like the number 10 in decimal notation, but it's actually 2 (the number of miles you've driven the car so far) in binary notation.


    When you've driven the third mile the odometer reads "00000011", since the first digit of the odometer turns again. The number "11", in binary notation, is the same as the decimal number 3.


    Finally, when you've driven your fourth mile both digits (which were reading "1" at the end of the third mile) roll back over to zero position, and the 3rd digit rolls up to the "1" position, giving us "00000100". That's the binary representation of the decimal number 4.


    You can memorize all of that if you want, but you really only need to understand how the little odometer "rolls over" as the number it's counting gets bigger. It's exactly the same as a traditional decimal odometer's operation, except that each digit can only be "0" or "1" on our fictional "binary odometer".


    To convert a decimal number to binary you could roll the odometer forward, tick by tick, counting aloud until you've rolled it a number of times equal to the decimal number you want to convert to binary. Whatever is displayed on the odometer after all that couting and rolling would be the binary representation of the decimal number you counted up to.


    Since you understand how the odometer rolls forward you'll also understand how it rolls backward, too. To convert a binary number displayed on the odometer back to decimal you could roll the odometer back one tick at a time, counting aloud until the odometer reads "00000000". When all that counting and rolling is done, the last number you say aloud would be the decimal representation of the binary number the odometer started with.


    Converting values between binary and decimal this way would be very tedious. You could do it, but it wouldn't be very efficient. It's easier to learn a little algorithm to do it faster.


    A quick aside: Each digit in a binary number is known as a "bit". That's "b" from "binary" and "it" from "digit". A bit is a binary digit.


    Converting a binary number like, say, "1101011" to decimal is a simple process with a handy little algorithm.


    Start by counting the number of bits in the binary number. In this case, there are 7. Make 7 divisions on a sheet of paper (in your mind, in a text file, etc) and begin filling them in from right to left. In the rightmost slot, enter the number "1", because we'll always start with "1". In the next slot to the left enter double the value in the slot to the right (so, "2" in the next one, "4" in the next one) and continue until all the slots are full. (You'll end up memorizing these numbers, which are the powers of 2, as you do this more and more. I'm alright up to 131,072 in my head but I usually need a calculator or paper after that).


    So, you should have the following on your paper in your little slots.


     64    |    32    |    16    |    8    |    4    |    2    |    1    |


    Transcribe the bits from the binary number below the slots, like so:


     64    |    32    |    16    |    8    |    4    |    2    |    1    |
      1          1          0         1         0         1         1


    Now, add some symbols and compute the answer to the problem:


     64    |    32    |    16    |    8    |    4    |    2    |    1    |
    x 1        x 1        x 0       x 1       x 0       x 1       x 1
    ---        ---        ---       ---       ---       ---       ---
           +          +          +         +         +         +         =


    Doing all the math, you should come up with:


     64    |    32    |    16    |    8    |    4    |    2    |    1    |
    x 1        x 1        x 0       x 1       x 0       x 1       x 1
    ---        ---        ---       ---       ---       ---       ---
     64    +    32    +     0    +    8    +    0    +    2    +    1    =   107


    That's got it. "1101011" in decimal is 107. It's just simple steps and easy math.


    Converting decimal to binary is just as easy and is the same basic algorithm, run in reverse.


    Say that we want to convert the number 218 to binary. Starting on the right of a sheet of paper, write the number "1". To the left, double that value (so, "2") and continue moving toward the left of the paper doubling the last value. If the number you are about to write is greater than the number being converted stop writing. otherwise, continue doubling the prior number and writing. (Converting a big number, like 34,157,216,092, to binary using this algorithm can be a bit tedious but it's certainly possible.)


    So, you should have on your paper:


     128    |    64    |    32    |    16    |    8    |    4    |    2    |    1    |


    You stopped writing numbers at 128 because doubling 128, which would give you 256, would be large than the number being converted (218).


    Beginning from the leftmost number, write "218" above it (128) and ask yourself: "Is 218 larger than or equal to 128?" If the answer is yes, scratch a "1" below "128". Above "64", write the result of 218 minus 128 (90).


    Looking at "64", ask yourself: "Is 90 larger than or equal to 64?" It is, so you'd write a "1" below "64", then subtract 64 from 90 and write that above "32" (26).


    When you get to "32", though, you find that 32 is not greater than or equal to 26. In this case, write a "0" below "32", copy the number (26) from above 32" to above "16" and then continue asking yourself the same question with the rest of the numbers.


    When you're all done, you should have:


     218         90         26         26        10         2         2         0
     128    |    64    |    32    |    16    |    8    |    4    |    2    |    1    |
       1          1          0          1         1         0         1         0


    The numbers at the top are just notes used in computation and don't mean much to us. At the bottom, though, you see a binary number "11011010". Sure enough, 218, converted to binary, is "11011010".


    Following these very simple procedures you can convert binary to decimal and back again w/o a calculator. The math is all very simple and the rules can be memorized with just a bit of practice.


    Splitting Up Addresses


    Think of IP routing like pizza delivery.


    When you're asked to deliver a pizza to "123 Main Street" it's very clear to you, as a human, that you want to go to the building numbered "123" on the street named "Main Street". It's easy to know that you need to go to the 100-block of Main Street because the building number is between 100 and 199 and most city blocks are numbered in hundreds. You "just know" how to split the address up.


    Routers deliver packets, not pizza. Their job is the same as a pizza driver: To get the cargo (packets) as close to the destination as possible. A router is connected to two or more IP subnets (to be at all useful). A router must examine destination IP addresses of packets and break those destination addresses up into their "street name" and "building number" components, just like the pizza driver, to make decisions about delivery.


    Each computer (or "host") on an IP network is configured with a unique IP address and subnet mask. That IP address can be divided up into a "building number" component (like "123" in the example above) called the "host ID" and a "street name" component (like "Main Street" in the example above) called the "network ID". For our human eyes, it's easy to see where the building number and the street name are in "123 Main Street", but harder to see that division in " with a subnet mask of".


    IP routers "just know" how to split up IP addresses into these component parts to make routing decisions. Since understanding how IP packets are routed hinges on understanding this process we need to know how to break up IP addresses, too. Fortunately, extracting the host ID and the network ID out of an IP address and subnet mask is actually pretty easy.


    Start by writing out the IP address in binary (use a calculator if you haven't learned to do this in your head just yet, but make a note learn how to do it-- it's really, really easy and impresses the opposite sex at parties):


          10.      13.     216.      41


    Write out the subnet mask in binary, too:


         255.     255.     192.       0


    Written side-by-side, you can see that the point in the subnet mask where the "1's" stop "lines up" to a point in the IP address. That's the point that the network ID and the host ID split. So, in this case:


          10.      13.     216.      41
    00001010.00001101.11011000.00101001 - IP address
    11111111.11111111.11000000.00000000 - subnet mask
    00001010.00001101.11000000.00000000 - Portion of IP address covered by 1's in subnet mask, remaining bits set to 0
    00000000.00000000.00011000.00101001 - Portion of IP address covered by 0's in subnet mask, remaining bits set to 0


    Routers use the subnet mask to "mask out" the bits covered by 1's in the IP address (replacing the bits that are not "masked out" with 0's) to extract the network ID:


          10.      13.     192.       0
    00001010.00001101.11000000.00000000 - Network ID


    Likewise, by using the subnet mask to "mask out" the bits covered by 0's in the IP address (replacing the bits that are not "masked out" with 0's again) a router can extract the host ID:


           0.       0.      24.      41
    00000000.00000000.00011000.00101001 - Portion of IP address covered by 0's in subnet mask, remaining bits set to 0


    It's not as easy for our human eyes to see the "break" between the network ID and the host ID as it is between the "building number" and the "street name" in physical addresses during pizza delivery, but the ultimate effect is the same.


    Now that you can split up IP addresses and subnet masks into host ID's and network ID's you can route IP just like a router does.


    Answered By:



Ask Question