How to find IP addresses and subnet number in a few seconds

How to find IP addresses and subnet number in a few seconds

When you know IP address and mask number, you sometimes want to know subnet number, subnet broadcast address and range of valid IP addresses. In common ways, you can find these by convert the IP address with mask number to binary and perform boolean AND but that takes too much time. So let see how to find these answers in a short time.Before I start, let see the general table which will used to describe IP address. In each column will be the IP address that separate by octet, dot-notation (x.x.x.x). In each row is the IP address.

Generic Subnet Table

Octet

1

2

3

4

Address

Subnet number

First Address

Broadcast Address

Last Address

Let’s start

I divide into 2 categories which depend on subnet mask:

Do Maths with easy masks
For the masks that contain only 255s and 0s. There are three masks which are 255.0.0.0, 255.255.0.0 and 255.255.255.0.
I guess many people know this already, but l will explain a little bit to revise for someone.

Find the subnet number

Copy first octet (mask 255.0.0.0), first two octets (mask 255.255.0.0) or first three octets (mask 255.255.255.0) from IP address

Put 0s in the remaining octets

Find the broadcast the address

Copy first octet (mask 255.0.0.0), first two octets (mask 255.255.0.0) or first three octets (mask 255.255.255.0) from IP address. This is the same in ‘Find the subnet number’, step 1

Put 255s in the remaining octets

Find range of valid IP addresses

To find the first valid IP address, copy the subnet number and add 1 to the fourth octet

To find the last valid IP address, copy the broadcast address and subtract 1 to the fourth octet

Example

Mask 255.0.0.0

Octet

1

2

3

4

Address

10

110

140

1

Subnet number

10

0

0

0

First Address

10

0

0

1

Broadcast Address

10

255

255

255

Last Address

10

255

255

254

Mask 255.255.0.0

Octet

1

2

3

4

Address

10

110

140

1

Subnet number

10

110

0

0

First Address

10

110

0

1

Broadcast Address

10

110

255

255

Last Address

10

110

255

254

Mask 255.255.255.0

Octet

1

2

3

4

Address

10

110

140

1

Subnet number

10

110

140

0

First Address

10

110

140

1

Broadcast Address

10

110

140

255

Last Address

10

110

140

254

Do Maths with difficult masks
In this case, most people find it’s difficult to calculate and some has to do by binary math which is time consuming. Let see the way to figure out in few seconds.

Find the subnet number

I will define the column that contain the difficult number(not 255s and 0s) as the interesting column. For any octets fully to the left of the interesting column, copy value(s) from the original IP Address into all addresses(subnet number, first-last address and broadcast address).

Octet

1

2

3

4

Address

130

4

102

1

Mask

255

255

252

0

Subnet number

130

4

First Address

130

4

Broadcast Address

130

4

Last Address

130

4

For any octets fully to the right of the interesting column, put 0s in the subnet number.

Octet

1

2

3

4

Address

130

4

102

1

Mask

255

255

252

0

Subnet number

130

4

0

First Address

130

4

Broadcast Address

130

4

Last Address

130

4

Now the tricky part, find a ‘magic number’ which is 256 minus mask’s interesting octet. In this example, it is 256 – 252 = 4.

Find the multiple of the magic number that is closest to, but not greater than the the interesting octet of original IP address. For this case, it is 100 (4*25) which also not greater than 102.

Put the result from previous step in subnet number of the interesting column.

Octet

1

2

3

4

Address

130

4

102

1

Mask

255

255

252

0

Subnet number

130

4

100

0

First Address

130

4

Broadcast Address

130

4

Last Address

130

4

Find the broadcast address

For any octets fully to the right of the interesting column, put 255s in the broadcast address. The left part should be filled already in Find subnet number, the upper.

Again, use the magic number. By adding the magic number to the interesting octet of subnet number and subtract 1. In this example, the magic number is 256 – 252 = 4, 100 + 4 – 1 = 103.

Put the result from previous step in broadcast number of the interesting column.

Octet

1

2

3

4

Address

130

4

102

1

Mask

255

255

252

0

Subnet number

130

4

100

0

First Address

130

4

Broadcast Address

130

4

103

255

Last Address

130

4

Find range of valid IP addresses
The way used to find the first and last IP addresses are the same in easy mask.

To find the first valid IP address, copy the subnet number and add 1 to the fourth octet

To find the last valid IP address, copy the broadcast address and subtract 1 to the fourth octet

I am confused. What happens when the magic number is larger than the subnet number’s last octet? For example:
190.4.80.80/25 (255.255.255.128)
magic number here is 128 (greater than 80)

Subnet# is 190.4.80.0. How does the booklet get a broadcast address of 190.4.80.127????

linglomAugust 15, 2009

Hi, Luis

The magic number is 128 and the subnet number is 190.4.80.0. Therefore, the broadcast address is 190.4.80.127 where 127 is came from adding the magic number to the interesting octet of subnet number and subtract 1 (0 + 128 – 1 = 127).

kevinAugust 19, 2009

My question is why is the number 25 used when trying to find the mutiple?

linglomAugust 19, 2009

Hi, Kevin

Did you means the number 25 on Do Maths with difficult masks -> Find the subnet number -> step 4? If yes, the number is multiple of the magic number and must be closest to and not be greater than the the interesting octet of original IP address.

On the example, the magic number is 4 and the interesting octet is 102. If you try to find the number, (4*1=4, 4*2=8, 4*3=12, …., 4*25=100, 4*26=104, you will see that 25 is the number that is closest to and less than the interesting octet (26 is greater than the interesting octet).

RamDecember 18, 2009

what is subnet number and the host number for the ip 108.77.51.70 and the subnet mask 255.255.128.0..
plz explain..?
thanks..

linglomJanuary 6, 2010

Hi, Ram
I believe that I have shown many examples which you can apply to yours.

what i wanna find out is how you get the binary numbers?..
in order to find your subnet and host/subnet…

e.g.: 255.255.255.224
where did 11100000 came from?? 😀 thanks

linglomFebruary 3, 2010

Hi, Hannah
So the final question is that you want to know how to convert from 224 in decimal to 11100000 in binary?

You can find a binary number using short division by two with remainder. You keep do short division, write the remainder (0 or 1) at the right side of each division. Finally, the answer is read from the bottom to top on the remainder column.

First, you need to convert it to binary format. It must has 32 digits. Write down 1’s as equal as the number of Mask Bits. For example, 1111111111111.

Then, fill the rest with 0’s up until it has 32 digits: 11111111111110000000000000000000.

Split the binary number into four octets (each has 8 digits): 11111111.11111000.00000000.00000000

Convert each octet to decimal: 255.248.0.0

scottFebruary 18, 2010

How do you answer a question like:
How many subnets and hosts can be found with 10.0.0.0/20?
I understand from your teaching how to find the ranges but to get the number of subnets and hosts it seems i have to write it all out.
thank you

scottFebruary 19, 2010

I may have figured it out.
8 bits for the class A
12 subnet bits and 12 host bits
2^s, and 2^h-2.
4096 subnets and 4094 hosts
?? Does that look right?
thanks
Scott

linglomFebruary 23, 2010

Hi, Scott
Yes, that’s right.

jeffMarch 2, 2010

Very nice post, thank you so much for the simple method to determine IP ranges. I’m about to take Microsoft 70-291 and then the Cisco CCNA test and this helps out a ton!

LarryMarch 9, 2010

I tried your formula with 190.165.106.119/23 but was way off. Please work it out for me so I can see where I went wrong.

linglomMarch 12, 2010

Hi, Larry

Mask bits: 23 => 255.255.254.0

So weâ€™re interested in the third column.
Magic number: 256-254 = 2

So the subnet number = 190.165.106.0
(Multiple of magic number: 2,4,6,…,104,106)

16.0.0.0/8. An organization is granted the block the administrator wants to create 500 fixed-length subnets.

a) Find the subnet mask.
b) Find the number of address in each subnet.
c) Find the first and last addresses in subnet 1.
d) Find the first and last addresses in subnet 500.

How to Find the first and last addresses in subnet 500.
?
Any Solution on it?please provide me..Thank in advance…

scottMarch 22, 2010

Ahmed – in answering Kulas’s question about finding the subnet of 100.20.0.0/21, shouldn’t the mask be 255.255.248.0? I can get the broadcast of 100.20.7.255, last of 100.20.7.254, but I can’t get the 1st?

RaviMarch 28, 2010

Hi Everyone:

I am stuck with this question here… I am new to this so having a lot of trouble in finding out the way around. My question is, given an ip address 17.212.89.111 and that each subnet has been designed to accommodate 700 hosts:

a. What is the subnet mask in dotted decimal and slash notation?

b. How many usable hosts are there per subnet?

c. What is the network and the broadcast address of the subnet the specified host belongs to?

scottMarch 28, 2010

Ravi,
Hope I got this right.

Question B: The power of 2 shows at position 10 you have the number 1024. (2^h-2=hosts) or (2^10-2=1022) The next lowest is 512 which is lower than your required 700.

Question A: So 10 bits for the host part. Look at this,
Class A gives you 8 bits for the network
Using 10 bits for the host leaves a remaining 14 bits for the subnets (subnets available= 2^s=subnets or 2^14=16384)
nnnnnnnn.ssssssss.sssssshh.hhhhhhhh
For the slash notation just count from the left to right till you get to the hosts = 22 or 8+8+6=22 (255.255.252.0)
17.212.89.11/22 or 17.212.89.11 255.255.252.0

Question c: Now armed with the above solutions you can do the math Linglom shows us to get
subnet – 17.212.88.0
broadcast – 17.212.91.255

I checked it with the subnet calculator and it shows true.
Hope it helps,
Scott

RaviMarch 29, 2010

Hi Scott:

Thank you for your reply, your response is highly appreciated. However if you could show me a detailed calculation it would be greatly appreciated as I am new to this so I am not able to understand what you have shown in the answers above. For example, why we having a 10 bit host etc… if that could be shown here in this space then it would make my life much easy…

I look forward to your explanation…

Thank you so very much for your response.

Regards,

Ravi

scottMarch 29, 2010

Ravi,

to get the 10 bit host, use the powers of 2 like this:
1×2=2
2×2=4
2×4=8
2×8=16
2×16=32
2×32=64
2×64=128
2×128=256
2×256=512
2×512=1024 and so on…. (I referred to this as position 10 for my own convenience)
Now you have your 10 bit position for the hosts.
How else may I help?
Scott

(Linglom, please check these things. Don’t let me show Ravi wrong. I am just answering his questions because I need the challenge.)

RaviMarch 30, 2010

Hi Scott:

Thanks again for your response, however here are my few questions again:

1. As per your calculations is it 1024 valid IP’s available?

2. Can you show me a detailed calculation of my last question that is how to find the subnet and broadcast IP addresses?

I know I am asking too much here but I am really getting into it… and trying to figure out with some easy calculations/maths to figure out the answers to my questions… Hope you would understand… All I need is a step by step calculation of my aforesaid questions as I am new to networking and IP addressing, it will be a pleasure to know the in-depth way of calculating the IP addresses etc… I know Linglom has shown it with an easy math but since I am new to all this I am not able to get it…

Your response would be highly appreciated.

Regards,

Ravi

RaviMarch 30, 2010

Hey Scott:

Help Please…

Regards,

Ravi

scottMarch 30, 2010

Ravi,
hang in there friend. I am working right now.
force yourself to go line by line, step by step with what Linglom has shown us in the mean time. I will get time for this later. He has given us some good stuff.
Scott

RobinMay 9, 2010

Hi Frndz,

Any one pls help me to find the wild card mask range for the IP’s 172.21.188.120 to 172.21.188.140…….

AmitMay 15, 2010

Dear, I have a IP 12.200.50.0/17 where the magic number 128 is grather then 50 . so what is the solution for finding subnet number > please reply me

After researching on these topics for a long time now, I can now calculate these things in a snap… In your case the subnet with ip address 12.200.50.0/17 would be 255.255.128.0 since 12.200.50.0/17 means you have 8+8+1 of subnet ID and this being a class A ip address you have the rest of the part as host bits. Please revert if you need any further information.

Please note that IOS which is older than 12.x you will have to use “ip subnet zero” command to start subnet from “0” otherwise no. of subnet will be 2^n – 2. “ip subnet zero” command is enable by default on all IOS after 12.x.

ScottOctober 9, 2010

Ravi,
Did you ever get an understanding?

JerryOctober 14, 2010

Hi,
In reply 15, Meraj is incorrect
“So the subnet number = 172.16.2.128”

Wouldn’t the subnet number = 172.16.2.0

-Jerry

ScottOctober 14, 2010

thanks Linglom! I passed the ICND1 with a 887. This site was instrumental in my passing.

YulOctober 18, 2010

How many subnets & host per subnet
172.23.0.0 255.255.255.192
I calulated 62 host.
How do I find how many subnets?

RubOctober 19, 2010

How does this help you it doesn’t even give enough details he shows no math or anything.
Show me with math please. How to find the bits borrowed and subnet number, with the subnet address of 202.22.22.160/27 Thanks.

RubOctober 19, 2010

nvm i believe i found it. Correct me if I’m wrong but i got 202.22.22.32 as the subnet number and .63 as the broadcast.
Now what if you do this

Given the subnet mask of 255.255.255.240/(28) and host address 220.20.20.97, how do you find subnetwork identifier and broadcast of the subnet the host belongs to.

RubOctober 19, 2010

oh and wtf is an easy and difficult mask? I’ve never heard that used before. And what is the difference. because he doesn’t clarify

JerryOctober 21, 2010

Rub,
For the 202.22.22.160/27 question, you said correct you if you are wrong, so…
The subnet would be 202.22.22.160 Reason being is 256-224=32 so 32 is the magic number. If you find the multiple of the magic number, in this case 32, closest to the last octet but not greater than it, you get 160
Multiples of 32 are …32,64,96,128 and 160, 160 happens to be equal, but not greater. Then, each subnet after will be increased by the magic number 32
202.22.22.160
202.22.22.192
202.22.22.224, etc…
So, you have 202.22.22.160 – subnet number
202.22.22.161 – first usable address
202.22.22.190 – last usable address
202.22.22.191 – broadcast address
Someone please let me know if I am wrong!!

ScottOctober 22, 2010

failed first attempt at ICND2.
:^(

JerryOctober 22, 2010

Scott, congrats on passing the first one. I thought the first one would be harder, but I guess not. Don’t sweat it, you’ll pass the second time. What did you use to study for the ICND1? And what about ICND2?

RubOctober 22, 2010

Jerry, You are 100% correct. I shoulda put more time into learning it instead of complaining it just frustrates me hardcore! I’m finally starting to understand it now. Thanks for help though

RubOctober 22, 2010

But what do you do if you don’t knwo how many bits are used.
like. 190.90.0.0
How you find all of them based on just that. I don’t think you can can you. The question also says I have 2046 useable subnets created. Not sure where to go from there

ScottOctober 22, 2010

Jerry,
For the ICND1 I used the cisco ICND1 book and the examcram ICND1 and this web site to get ready. This site was key at first and then you get where you don’t hardly have to think about it. You can look at many and just know.

For the ICND2 test I used the ICND2 questions selected from the ICND1 CD and the examcram CCNA book. Some from the Cisco ICND2 book. Felt very comfortable being able to quickly answer all questions for ICND2 study materials. I will now focus more on the Cisco ICND2 book.

Pain in the neck. I never renewed my Certs. I had three tests towards CCNP 10 years ago. Just a lot of stuff I don’t use much. How about you?
Scott

JerryOctober 23, 2010

Scott, thank you for the information! It’s not stuff I use much either, but I want to get my CCNA, so that’s why I ask.
There is so much study material out there and so many promises, I don’t know what to buy.
-Jerry

mikeOctober 24, 2010

how often in real life that require you to know what subnet number an IP belongs to?

yulNovember 13, 2010

I am stumped: Ip add: 172.24.145.128 subnet mask: 255.255.255.224.
The first and last IP address start with 172.24.145 because it is a class B? and the last oct for eachis confusing: 256-224=32 or do I take 256-128=128 ? perplexed??

SpawnNovember 22, 2010

Thank you so much. You have taught me in half an hour what my tutor’s haven’t been able to explain in 4 months. Now I might actually pass this exam and be able to start making games.

esonDecember 7, 2010

where did you get the magic number? or how do you get the magic number? and how to use it? im confused on the magic number… pls reply… ASAP

linglomDecember 18, 2010

Hi, Eson

I described it on the post with an example. The magic number can be calculated by 256 minus mask’s of the interesting octet.

ClydeFebruary 16, 2011

What if you know the Hostaddress but you want to know in what subnet it resides how do i make a easy quick calculation instead of remebering the whole Subnetrange?
For instance if if have host 192.168.0.203 /30 how can i quickly calculate the subnet adrress and subnetnr i need the formule.

UrgenMay 29, 2011

i little bit got some knowledge…heres my question
Given 172.150.40.118/22
find
1.network id
2.how many network id’s
3.how many host ids in one network
how to find these…any help is appreciated
REGARDs…

scott, when i entered this subnet 255.255.255.173 and IP ADD -> 172.150.40.0 the ip calulator said it was invalid subnet..ithink this type of mask will not occur ;P

UrgenMay 30, 2011

i think i can :D,,the subnet mask was invalid

ScottMay 30, 2011

correct – 172.150.40.0/22 the vlsm subnet MASK is:255.255.252.0
is host bits 10 ?? yes, because when you do your powers of 2 to get the required hosts, you end up with 10 bits which use 8 bits from the 4th octet and 2 from the 3rd octet. The remaining 6 bits in the 3rd octet are part of the subnet bits.
255.255.255.173 is an extinct mask, if you find one alive keep it and you will become a Billionaire. {:^)
Hope this helps.

ScottJune 3, 2011

Passed ICND2, CCNA
WooHoo!!

ScottJune 3, 2011

This site was a huge help to me.

TawsifAugust 17, 2011

Congrates Scott.

RamAugust 22, 2011

The Subnet mask for a particular network is 255.255.31.0 which of the following pairs of IP addresses could belong to this network ?
a) 172.57.88.62 and 172.56.87.23
b) 10.35.28.2 and 10.35.29.4
c) 191.203.31.87 and 191.234.31.88
d) 128.8.129.43 and 128.8.161.55

sudhirAugust 22, 2011

pl z tel me any one .i,e..
the second subnetwork ID eor 10.0.0.0/8?

sudhirAugust 22, 2011

pl z tel me any one .i,e..
the second subnetwork ID for 10.0.0.0/8?

ramAugust 23, 2011

The Subnet mask for a particular network is 255.255.31.0 which of the following pairs of IP addresses could belong to this network ?
a) 172.57.88.62 and 172.56.87.23
b) 10.35.28.2 and 10.35.29.4
c) 191.203.31.87 and 191.234.31.88
d) 128.8.129.43 and 128.8.161.55

No Extra info is given…
pls try to figure it out

ramAugust 23, 2011

answer is
D
128.8.129.43 and 128.8.161.55

sudhirAugust 24, 2011

the second IP address for 10.0.0.0/18 is 10.0.62.0

JoyceSeptember 19, 2011

Ok, reading through directions, trying out the method and I get stuck relatively early. On comment #6, the IP address in the example given was 192.168.200.23/28 and it was answered by Linglom in comment #7. Seemed pretty straightforward. However, I have an IP address to use as an example of 192.168.3.219/28. When I use the method here’s what I get.

IP: 192.168.3.219/28
Mask: 255.255.255.240

My interesting octet is the 4th or 240..so 256-240 = 16, which is my magic number. The closest I can get to my original IP of 219 is 16 x 13 = 208, 16 x 14 = 224. So, by this method 192.168.3.13 should be my Subnet, my First address is 192.168.3.14.

And this is where I get tripped up. Should my broadcast be 192.168.3.255 with the last address being 192.168.3.254? That would then mean that I have 242 usable IP’s in this range. How can I only have 242 IP’s? So, obviously, I’m not doing something right. Can someone please show me the error of my ways? Thanks.

JoyceSeptember 19, 2011

As a follow-up to my own comment in #87, by using another calculation method I’ve been taught, I come up with a subnet for the IP of 192.168.3.219/28 as 192.168.3.218. The first usable IP is then 192.168.3.219, which is the IP in my example. The last IP should be 192.168.3.233 and my Broadcast should be 192.168.3.234. So, as you can see, I am not getting the same result by using the math steps described on this site.

linglomSeptember 19, 2011

Hi, Joyce

Let me try to explain again.
From your given example, the magic number is 256-240 = 16. And we interest in only fourth octet so the first three octets will be the same.

Now subnet number calculation, find the multiple of the magic number that is closest to, but not greater than the the interesting octet of original IP address. It is 16 x 13 = 208 so the subnet number is 192.168.3.208.

Next on broadcast address, adding the magic number to the interesting octet of subnet number and subtract 1. It is 16 + 208 – 1 = 223 so the broadcast address is 192.168.3.223.

The valid IP address range is 192.168.3.209 – 192.168.3.222 (by adding 1 on the subnet number for first IP and subtract 1 on the broadcast number for last IP).

JoyceSeptember 19, 2011

Thanks….I should have checked my math in my other method. I miscalculated. After seeing you work through my example, I see where I goofed. After recalculating, I get the same thing as your method. Your method is by far easier than the one I’ve been using, and more accurate. Thanks again.

CHANDSANDHUSeptember 20, 2011

HI IS DIS VERY HELPFUL PLZ DON’T IGNORE DIS

AshrafOctober 1, 2011

Best thing I have used to work out subnets. I knew how to work out number of hosts and subnets, for a given IP address and subnet mask, but never could work out the range of IPs. This article is brilliant. Thanks!

AlanOctober 5, 2011

This article is great!!! Simplified everything for me. I will be taking ICND1 test next week and now I am confident I can pass

JeromeOctober 6, 2011

10.155.64.110/28

/28 mask is 255.255.255.240

the magic number is 16 (256-240).

We’re interested in the fourth octet

subnet number calculation; find the multiple of the magic number that is closest to, but not greater than the interesting octet of original IP address. It is 16 x 6 = 96 so the subnet number is 10.155.64.96.

broadcast address; add the magic number to the interesting octet of subnet number and subtract 1. It is 16 + 96 â€“ 1 = 111 so the broadcast address is 10.55.64.111.

The valid IP address range is;
10.155.64.97 â€“ 10.155.64.110
(by adding 1 on the subnet number for first IP and subtract 1 on the broadcast number for last IP).

IS THIS CORRECT? I sure hope so….only took me 3 hours to figure this out.

sandyOctober 22, 2011

I tried your formula but failed can you help me find out this what is valid ip address range and subnet id and broadcast address for 198.24.35.128/27 and i want to also know about the multiplier and magic number fundamental.

RobertNovember 6, 2011

Hey guys, I’m having a bit of trouble with this one: 66.128.0.0 /11.

I can get the broadcast address by a different method but I can’t seem to grasp this one but it looks easier and faster so I’d love to know it properly.

I can do the other examples at the top but not ones such as the 10.0.0.0 / 13 example and the one I’m having trouble with.

If someone could show me how to get the subnet IP, first IP, last IP, broadcast (66.143.255.255) but in they way Linglom does it I’d very much appreciate it.

linglomNovember 10, 2011

Hi, Jerome

That’s correct.

linglomNovember 10, 2011

Sandy,

For your case, 192.24.35.128/27. Subnet mask is 255.255.255.224 so we are interested in the fourth octet.

The magic number is 256 – 224 = 32.

Now subnet number calculation, find the multiple of the magic number that is closest to, but not greater than the the interesting octet of original IP address. It is 32 x 4 = 128 so the subnet number is 198.24.35.128.

Next on broadcast address, adding the magic number to the interesting octet of subnet number and subtract 1. It is 32 + 128 â€“ 1 = 159 so the broadcast address is 198.24.35.159.

The valid IP address range is 198.24.35.129 â€“ 198.24.35.158 (by adding 1 on the subnet number for first IP and subtract 1 on the broadcast number for last IP).

linglomNovember 10, 2011

Robert,

For your case, 66.128.0.0/11. Subnet mask is 255.224.0.0 so we are interested in the second octet.

The magic number is 256 â€“ 224 = 32.

Now subnet number calculation, find the multiple of the magic number that is closest to, but not greater than the the interesting octet of original IP address. It is 32 x 4 = 128 so the subnet number is 66.128.0.0.

Next on broadcast address, adding the magic number to the interesting octet of subnet number and subtract 1. It is 32 + 128 â€“ 1 = 159 so the broadcast address is 66.159.255.255.

The valid IP address range is 66.128.0.1 – 66.159.255.254 (by adding 1 on the subnet number for first IP and subtract 1 on the broadcast number for last IP).

MayankNovember 25, 2011

Thanks

kamalDecember 4, 2011

an organization is granted the block 21.34.24.0/14…find the first and last adress of block????i tried bt still confused:(

JohnDecember 7, 2011

If I borrow 4 bits from a default mask. What is the subnet incrementation value, or delta?

JeanineDecember 15, 2011

What is the magic number is greater than the number in the 4th octet? Example:

IP address 192.168.10.11
Mask 255.255.255.192

The interesting octet is the 4th at 192. Figure 256-192=64, the magic number. 64 is greater than 11. What then?

Thank you, Jeanine

giobitJanuary 7, 2012

Meraj Says:
June 5th, 2009 at 4:11 am

:DDD So the subnet number = 172.16.2.128

172.16.2.0 /25 masc bit never change the subnet when last is .0

giobitJanuary 7, 2012

The interesting octet is the 4th at 192. Figure 256-192=64, the magic number. 64 is greater than 11. What then?

remember the subnet mask controls only network portion and host portions. when mask increasing the host was reduction.

desarJanuary 10, 2012

Great work! Thank you very much indeed. The best article about sub netting calculations.

chetsJanuary 30, 2012

so interesting method

gilbert samuelFebruary 29, 2012

what if only d IP is given without any subnet number or mask bit or broadcast number ,how do we get them???. For example; 82.145.209.112. What is d subnet mask and broadcast number.?

AdamMarch 29, 2012

Broadcast address of network 192.168.162.128/28?
Mask would therefore be 255.255.255.240
so I worked out the subnet number as 192.168.162.8

Therefore the broadcast address must be 192.168.162.23

I got this wrong though! Seemingly it is 192.168.162.143

Can you show me where I went wrong?

linglomMarch 30, 2012

Hi, Adam

The answer would be like this:

First, find subnet number. Mask /28 = 255.255.255.240 so we are interested in the last octet (the first three octets are the same as network IP). The magic number is 256 – 240 = 16. The fourth octet of subnet number is calculated from multiple of the magic number that is closest to, but not greater than the the interesting octet. So 16, 32, 48, 64, … , 128, hence, we get 128. The subnet number is 192.168.162.128.

Next, find broadcast address by adding the magic number to the interesting octet of subnet number and subtract 1. So 16 + 128 – 1 = 143. The broadcast address is 192.168.162.143

The valid IP range is 192.168.162.129 – 192.168.162.142.

DarkknightApril 5, 2012

can anyone help me out with this… how to find the ip address from this 192.168.10.subnet mask=255.255.255.240

Can you please tell me what I should do to be able to ping my guest from host.??

linglomJuly 5, 2012

Hi, newbie

If you want VM be able to access resource on host’s network, you should change network mode of a VM to brideged and make sure that the vitual network of the VM is enabled.

Next, change IP address of VM to be the same network as host (for example, 192.168.100.175,176,…) in your case.

Lastly, your VM is Linux. You have to make sure that the network is configured and enabled properly.

eunanJuly 31, 2012

i have been given 220.168.1.0/24 to subnet and provide ip addressing, the network has the following addressing requirements
branch 1 lan 1 will require 14 host ip addresses
branch 1 lan 2 will require 14 host ip addresses
branch 2 lan 1 will require 14 host ip addresses
branch 2 lan 2 will require 14 host ip addresses
the hq lan will require 25 hosts ip address
the link from hq to branch 1 will require an ip address for each end of the link
the link from hq to branch 2 will require an ip address for each end of the link
the link from hq to branch 1 to branch 2 will require an ip address for each of the link
can you help regards eunan

kevinOctober 24, 2012

how to find the ip addressess of subnet of 192.168.1.4 ?

kevinOctober 24, 2012

help me please?

pema TenzinOctober 31, 2012

How to find the First and last IP of 172.17.16.30.0/23 which have 174 hosts

Aboud92November 9, 2012

Please i need help

my question is : What you mean by this

” Now subnet number calculation, find the multiple of the magic number that is closest to, but not greater than the the interesting octet of original IP address. It is 32 x 4 = 128 so the subnet number is 66.128.0.0.”

what’s the not greater than the interesting octet

JimmyDecember 18, 2012

Thanks a lot …this website help me a lot to understand the sub netting and hosts..

JPDecember 31, 2012

how to solve this problem

from this ip add 172.21.0.0 . i want 700 subnet & 50 host on

each subnet

ZetteJanuary 14, 2013

Thank you kind Sir.

AthaMarch 6, 2013

Hey
ISP is giving you the block 45.4.10.0/26
What is the subnet mask for this block?

JacobMarch 9, 2013

I am trying to study for my final and one of the study questions is…Given an IP address of 172.16.3.5 with a subnet mask of 255.255.255.192 what is the last assignable ip address available on the 10th network? the answer that I came up with is 172.16.3.159… would this be correct

KayMay 10, 2013

If I have 1 IP address 82.31.64.0 /20 and I need to subnet it to accomodate for 3 sites:

Building 1
Student – 600 Host
Staff – 62 Hosts
Admin – 13 hosts

Building 2
Student – 700 Host
Staff – 80 Hosts
Admin – 18 hosts

Building 3
42 Hosts

Do I order them from largest to smallest host, or do I group them by buildings and subnet based on largest to smallest host in each group?

I did Building 1 700 hosts but don’t know how to continue from there or if its even right?

The subnet address is 10.16.3.0 255.255.254.0.
The lowest host address in the subnet is 10.16.2.1 255.255.254.0.
The last valid host address in the subnet is 10.16.2.254 255.255.254.0.
The broadcast address of the subnet is 10.16.3.255 255.255.254.0.

please tell the soluton according to your method

Walter MozolMay 26, 2014

Briliant Incredibly simple, much better than method in CCNA official CCENT/CCNA book !

newbe no cibieJune 3, 2014

hyyyy,,,,master…what function is this ? can explane ..! for me..please..thaks a lots

nagalakshmaiahJune 14, 2014

haii
what is the subnet for 172.16.209.10/22

sajjad sabriMay 17, 2015

how to find firsr address and given address of these ip
first group
first customer ip add is this
1)190.100.0.0/24
find 1 to 64th customer ist and last address?

inaJune 13, 2015

Hello. Can anybody please help me with this exercice.Network id is 20.1.1.128 and subnet mask is 255.255.255.128.We have 3 LAN contain a number of hosts.LAN 1 has 58 hosts,LAN 2 has 25 hosts and LAN 3 has 4 hosts.a) I have to find subnet address for every LAN. b) I have to find broadcast address, maximum number of hosts, first and last address for LAN 2.Thank you.

annJune 24, 2015

how we can find brodcast address of mask /27……if ip address not given

linglomJune 24, 2015

Hi Ann,

You need IP address or network address with subnet mask to calculate broadcast address, only the mask /27 is not enough information.

The broadcast address for an IPv4 host can be obtained by performing a bitwise OR operation between the bit complement of the subnet mask and the host’s IP address. In other words, take the host’s IP address, and set to ‘1’ any bit positions which hold a ‘0’ in the subnet mask.
Reference: https://en.wikipedia.org/wiki/Broadcast_address

dineshSeptember 26, 2015

I wanted to extract (ip address)of after third dot

eg: 192.168.1.100 here i wanted (after third (.)dot) 100 for further calculation
12.1.1.3 Here i wanted 3 for further calculation …please tell a solution

linglomSeptember 29, 2015

Hi, Dinesh

Did you mean by programming or coding? But you didn’t mention what language you use. You could use split function on a given IP (if it is string data type) with dot (.) as parameter. And get the last member of result array should be value that you want.

KutiOctober 16, 2015

I have this problem, i am tasked to decode this IP address 120.15.179.255/18 and determine the subnet mask, multiplier, network number, subnetwork addresses, and broadcast addresses.
please help me.

AmbasJanuary 1, 2016

I got this challenge for you 🙂 . A company has 6 VLANs. They have min 300 and max 1300 users. They all have to be in network 192.168.0.0/16. Give Network ID, Subnet Mask, IP adress for each group.

JobertJuly 22, 2016

Complete the following table for all of the subnets in this network. Give the subnet number (starting from 0), subnet address, host address range, subnet broadcast address, and identify which subnets are assignable (usable) and which subnets are not assignable. thanks

JayOctober 4, 2016

Guys….. 16.0.0.0/8. An organization is granted the block the administrator wants to create 500 fixed-length subnets.

a) Find the subnet mask.
b) Find the number of address in each subnet.
c) Find the first and last addresses in subnet 1.
d) Find the first and last addresses in subnet 500.

How to Find the first and last addresses in subnet 500.
?
Any Solution on it?please provide me..Thank in advanceâ€¦ plizzz gat a test 2morrow…. Guys help…

JayOctober 4, 2016

Anyone there to help me out

sanDecember 9, 2016

If i required 50 host ip addresses then what is exact subnet for this?

lubnaDecember 9, 2016

You need 500 subnets, each with about 100 usable host addresses per subnet. What mask will you assign using a class B network address?