we know that an ipv4 address is written in dotted decimal format so it is easier for humans to perceive it... 32 bits of 4 8 bit octets... but that is not the router's perception of the address; the router interprets the ipv4 address, not as four one byte octets, but as a single binary string...
so 10.1.1.1 is actually 167837953 in decimal and binary
00001010 00000001 00000001 00000001
the router doesn't see the dots, or the spaces, nor does it care about the decimal equivalent...
the router sees this:
00001010000000010000000100000001
bit count format v decimal (default)
dls1#term ip netmask-format decimal
dls1#sh ip route 172.16.100.0
Routing entry for 172.16.100.0 255.255.255.0
Known via "connected", distance 0, metric 0 (connected, via interface)
Routing Descriptor Blocks:
* directly connected, via Vlan100
Route metric is 0, traffic share count is 1
dls1#term ip netmask-format bit-count
dls1#sh ip route 172.16.100.0
Routing entry for 172.16.100.0/24
Known via "connected", distance 0, metric 0 (connected, via interface)
Routing Descriptor Blocks:
* directly connected, via Vlan100
Route metric is 0, traffic share count is 1
Search insearchofthecert
Showing posts with label binary. Show all posts
Showing posts with label binary. Show all posts
Monday, May 7, 2012
Sunday, November 27, 2011
summarization redux...
are you sick of writing down all the bits then counting from left to right... me too...
look at the examples below and answer the multiple choice...
summarize 10.1.32.0 to 10.1.35.255?
a)10.1.32.0/23
b)10.1.32.0/22
c)10.1.32.0/21
d)10.1.32.0/20
summarize 172.168.12.0/24 to 172.168.13.0/24?
a)172.168.12.0/23
b)172.168.12.0/22
c)172.168.12.0/21
d)172.168.12.0/20
example 1
step 1: identify the octet where the action is. the action is where the numbers change
in the first example the numbers change in the third octet, and like wise in the second example
.32 to .35 (you don't have to write down all the numbers, just the beginning and end of the range)
and .12 to .13
step 2: the first 2 octets are the same 10.1 and 172.168. together they comprise 16 bits so 16 is our working number
step 3: write down the first number .32 in example 1 and the last number where the change occurred, .35
.32
0010 0000
.35
0010 0011
count up to, but not including where the bits change and add 16 + 6 = /22
16 is the working number, determined by the address where there are no changes and 6 is the last position in the octet before a change
example 2
summarize 172.168.12.0/24 to 172.168.13.0/24?
the change happens in the third octet
.12
0000 1100
.13
0000 1101
16 plus 7 = /23
Class of address does not matter... the working number is always determined by the octet where the change occurs...
not sure about you, but there are a lot less 1's and zero's to count with my method... go ahead and prove this wrong...
Labels:
binary,
bits,
ccna,
ip address,
octet,
route,
summarization
Wednesday, November 2, 2011
quiz...
1) what is the root bridge default priority?
2) what is the DOD equivalent of the OSI transport layer?
3) what is 90.37.200.31 in binary?
4) /17. how many subnets and hosts?
5) what is the hop count for OSPF?
6) what kind of traffic does IGMP service?
7) IP is connection oriented? true or false
8) what is 2 to the 15th?
9) what does CHAP stand for?
10) how do you turn off CDP on an interface?
bonus: what is the theme of this quiz?
answers after the trip
2) what is the DOD equivalent of the OSI transport layer?
3) what is 90.37.200.31 in binary?
4) /17. how many subnets and hosts?
5) what is the hop count for OSPF?
6) what kind of traffic does IGMP service?
7) IP is connection oriented? true or false
8) what is 2 to the 15th?
9) what does CHAP stand for?
10) how do you turn off CDP on an interface?
bonus: what is the theme of this quiz?
answers after the trip
Labels:
binary,
ccna,
CDP,
CHAP,
default priority,
DOD,
hop count,
host,
IGMP,
IP,
OSI,
root bridge,
subnet
Monday, October 31, 2011
nibbles and bits
nibbles and bits...
the configuration register of a router is represented by a hex number, or 0x... it is a sixteen
bit number read from left to right starting from 15, and ending with 0, sixteen numbers total...
cisco loves the number sixteen because it is difficult to add sixteens... quick what is 16 plus
forty eight? 128 plus 16? how many 16's in 192? 16 x 4 is 64 which goes into 192 3 times... 3 x
four is 12... what is 12 hex?
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
16 32 48 64 80 96 112 128 144 160 176 192 208 224 240 256
0x2102 means load start from nvram if found
15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
8 4 2 1 8 4 2 1 8 4 2 1 8 4 2 1
15 to 0 are place positions
each group of 4 bits is a nibble
count the nibbles and bits
don't look at me... i didn't make this shit up
0010 0001 0000 0010 = 0x2102
try to think of all three number systems at once.. here is a great site that groups all three...
http://easycalculation.com/decimal-converter.php
decimal 20
is 14 in hex because 16 goes into 20 once with a remainder of 4
the binary value is 0001 0100 because 16 + 4 is twenty:
128 64 32 16 8 4 2 1
0 0 0 1 0 1 0 0
back to 192, the beginning of the class C range of private adresses
16 goes into 192 12 times
12 = C in hex so 192 = C0 hex
192 = 11000000 because 128 + 64 + 0 + 0 + 0 + 0 + 0 + 0 = one hundred and 92
remember 128 64 32 16 8 4 2 1
8 4 2 1 binary = 15 decimal = F hex
what is decimal 42 in hex? 2A
binary? 00101010
10 = A = 1010
sixteen goes into 42 twice remainder 10
the configuration register of a router is represented by a hex number, or 0x... it is a sixteen
bit number read from left to right starting from 15, and ending with 0, sixteen numbers total...
cisco loves the number sixteen because it is difficult to add sixteens... quick what is 16 plus
forty eight? 128 plus 16? how many 16's in 192? 16 x 4 is 64 which goes into 192 3 times... 3 x
four is 12... what is 12 hex?
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
16 32 48 64 80 96 112 128 144 160 176 192 208 224 240 256
0x2102 means load start from nvram if found
15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
8 4 2 1 8 4 2 1 8 4 2 1 8 4 2 1
15 to 0 are place positions
each group of 4 bits is a nibble
count the nibbles and bits
don't look at me... i didn't make this shit up
0010 0001 0000 0010 = 0x2102
try to think of all three number systems at once.. here is a great site that groups all three...
http://easycalculation.com/decimal-converter.php
decimal 20
is 14 in hex because 16 goes into 20 once with a remainder of 4
the binary value is 0001 0100 because 16 + 4 is twenty:
128 64 32 16 8 4 2 1
0 0 0 1 0 1 0 0
back to 192, the beginning of the class C range of private adresses
16 goes into 192 12 times
12 = C in hex so 192 = C0 hex
192 = 11000000 because 128 + 64 + 0 + 0 + 0 + 0 + 0 + 0 = one hundred and 92
remember 128 64 32 16 8 4 2 1
8 4 2 1 binary = 15 decimal = F hex
what is decimal 42 in hex? 2A
binary? 00101010
10 = A = 1010
sixteen goes into 42 twice remainder 10
Subscribe to:
Posts (Atom)