# the simplest and fastest way to subnet

raaki_88
Member Posts:

**13**■□□□□□□□□□
i found these techniques in subnetting secrets and found them very effective hoping that these will help you too

firstly you need to have remember two tables ...

1.basic table of first host , last host table

2.the crucial one to all calculation table ...

here are the two

subnet

firsthost

lasthost

broadcast

hence in this way this can be determined

the crucial one

bits

128

64

32

16

8

4

2

1

subnets

128

192

224

240

248

252

254

255

powers of 2

subnets

hosts (-2)

2

4

8

16

32

64

128

256

512

1024

********************************************************************************

*********************************************

let me check with the formatter , if it comes correctly i will go ahead explaining the concept if not i will host it to image shack and explain it

regards

raaki

firstly you need to have remember two tables ...

1.basic table of first host , last host table

2.the crucial one to all calculation table ...

here are the two

subnet

firsthost

lasthost

broadcast

hence in this way this can be determined

the crucial one

bits

128

64

32

16

8

4

2

1

subnets

128

192

224

240

248

252

254

255

powers of 2

subnets

hosts (-2)

2

4

8

16

32

64

128

256

512

1024

********************************************************************************

*********************************************

let me check with the formatter , if it comes correctly i will go ahead explaining the concept if not i will host it to image shack and explain it

regards

raaki

#When You Aim For Perfection You Discover It As a Moving Target#

#### Categories

- All Categories
- 389 Welcome Center
- 83 Announcements
- 10 Forum Rules of Engagement
- 218 Introduce Yourself
- 59 TechExams Support
- 88.7K Certification Preparation
- 131 Check Point: CCSA & CCSE
- 33K Cisco
- 21.6K CCNA & CCENT
- 370 CCDA & CCDP
- 9K CCNP
- 7 Cisco CyberOps
- 1.7K CCIE
- 541 Cloud Certifications
- 199 Amazon Web Services (AWS)
- 40 Azure
- 120 CCSP
- 79 Cloud+ & Cloud Essentials
- 15.5K CompTIA
- 5K A+
- 245 CASP+
- 114 CySA+
- 974 Linux+
- 4.4K Network+
- 35 PenTest+
- 266 Project+
- 3.9K Security+
- 335 Server+
- 252 Other CompTIA Certifications
- 1.2K EC-Council
- 586 CHFI
- 627 CEH
- 1.4K GIAC
- 47 IAPP
- 1K ISACA
- 29 CRISC
- 284 CISA
- 707 CISM
- 4.3K (ISC)²
- 666 CISSP
- 35 CSSLP
- 3.6K SSCP
- 926 Juniper
- 737 LPI, Red Hat & Linux Foundation
- 18.6K Microsoft
- 150 MCSA 2016 / MCSE 2016
- 161 Windows 10 exams
- 139 Windows 8 exams
- 1.4K Windows 7 exams
- 1.6K MCSA / MCSE on Windows 2012 General
- 2.3K MCTS / MCITP on Windows 2008 General
- 828 Exchange Server & Office Communications Server Exams
- 537 Other Microsoft Electives
- 349 MCSA/MCSE: Security
- 300 Microsoft Developers Certifications
- 485 SQL Server exams
- 161 Offensive Security: OSCP & OSCE
- 2K Other Security Certifications
- 345 Virtualization Certifications
- 231 Citrix Certifications
- 104 VMware
- 1.9K Other Certifications
- 15 Business Analyst Certifications
- 391 CWNP Certifications
- 873 ITIL Certifications
- 220 Project Management Certifications
- 85 Apple Mac OS X Certifications
- 62 Novell Certification
- 81 Oracle Certifications
- 52 Sun Microsystems Java Certification
- 114 Storage Certifications
- 6.7K General Certification
- 18K Education & Development
- 64 Colleges & Schools
- 93 Educational Resources
- 17.7K IT Jobs / Degrees
- 76 Professional Development
- 393 Cybersecurity
- 19 Auditing & Compliance
- 16 Cloud Security & IoT
- 15 Cryptography & PKI
- 38 Cybersecurity Management
- 5 Data Science & Machine Learning
- 9 Forensics
- 8 ICS/SCADA Security
- 35 Incident Response
- 8 Linux Security
- 11 OWASP
- 33 Pentesting
- 44 Security Awareness & Training
- 53 Security News & Breaches
- 11 Windows Security
- 20.2K General
- 35 Conferences & Events
- 22 Computer Gaming
- 7 Data Center
- 87 Classifieds
- 53 For Sale
- 6 Wanted (ISO)
- 16 Help Wanted
- 17 Just for Fun
- 19 Networking
- 17.5K Off-Topic
- 21 Scripting
- Show Us Your Tech!
- 26 Troubleshooting
- 2.4K Virtualization

## Comments

13■□□□□□□□□□class c

identify subnet , first and last host of the following ip or what ever it may be

here is the example 1

192.168.12.68 / 25 ***************** 25 bits so ...

firstly count in multiples of 8 till we get 24 .... as one octet has 8 bits right ...

so 8 + 8 + 8 + (1)

left ..

rest is the childs play... really .. now go to the table 2 and borrow or tick 1 bit horizontally and vertically so in this case

see the table two and come back you will find number 128 under subnets and 128 under bits ..

so subnet is 128 and bits 128 indicate that difference should be 128 --->we will see this point later

so our subnet is

255.255.255.128

as we all know we need to start any subnet with 0 .. so start it

subnet

firsthost

lasthost

broadcast

192.168.12.0

192.168.12.1

192.168.12.126(broad-1)

192.168.12.127(simple next subnet -1)

(see the difference of 128

which we got in bits )

192.168.12.128

hence in this way it can be determined

the crucial one

bits

128

64

32

16

8

4

2

1

subnets ******** *(1 bit vertically)

128 **** *(1 bit horizontally)

192

224

240

248

252

254

255

powers of 2

subnets

hosts (-2)

2

4

8

16

32

64

128

256

512

1024

hence in this way it can be determined

more examples to follow .. let me know if this makes sense to anyone

regards

raaki

13■□□□□□□□□□192.200.200.167 / 28

now again count till 24 ...now are left with another 4 bits ... rest is childs play as usual... tick 4 horizontally and 4 vertically in the second table...

after seeing the table and seeing the number under subnets it is 240 and under bits it is 16 .. so simple subnet mask ends with 240 and it has a diff of 16 for every

so our subnet mask is ... 255.255.255.240

subnet we write

so we will start with 0 as usual

subnet

firsthost

lasthost

broadcast

192.200.200.0

192.200.200.1

192.200.200.16

192.200.200.32

192.200.200.48

etc

etc with increments of 16

192.200.200.160

192.200.200.161

192.200.200.174

192.200.200.175

our need fills here

192.200.200.176

hence in this way this can be determined

the crucial one

bits

128

64

32

16

8

4

2

1

subnets

*

*

*

*

128

*

192

*

224

*

240

*

248

252

254

255

powers of 2

subnets

hosts (-2)

2

4

8

16

32

64

128

256

512

1024

13■□□□□□□□□□150.200.155.23/18

18 bits .. so multiples of 8 ... now 24 will not work as 18 is less than 24 .. so next 8 multiple is 16 ... so ... we need two more bits from 16 to 18

so go to table two tick two horizontally and two vertically ... and you are done

so seeing the table ... under subnets it stopped at 192.. remember we had only 16 bits now not 24 .. so our mask would be

255.255.192.0

now see under the bits table ... we are stopped at 64 .. so for this we need to have increments of 64 ... as usual start with 0

subnet

firsthost

lasthost

broadcast

150.200.0.0

150.200.64.0

150.200.128.0

150.200.128.1

150.200.191.254

150.200.191.255(next subnet-1)

our ip statisfies here

150.200.192.0

hence in this way this can be determined

the crucial one

bits

128

64

32

16

8

4

2

1

subnets

*

*

128

*

192

*

224

240

248

252

254

255

powers of 2

subnets

hosts (-2)

2

4

8

16

32

64

128

256

512

1024

13■□□□□□□□□□191.20.56.65 / 25

as usual ...greater than 24 .. so we need to add one more bit to make it 25 .. so tick in the table two one start horizontally and vertically and rest is gone

so seeing it ... we got under subnets the value is 128 .. so the subnet mask is

255.255.255.128

now going on with next ..we got 128 under bits so the difference is 128..but now we need to have four octet subnets for every third octet one .. if this

confuses you see the below table

start with 0

since class b

x.x.0.0

subnet

firsthost

lasthost

broadcast

191.20.0.0

191.20.0.128

191.20.1.0

191.20.1.128

191.20.2.0

191.20.2.128

etc etc till our ip

191.20.56.0

191.20.56.1

191.20.56.126

191.20.56.127

this satisfies our ip

191.20.56.128

hence in this way this can be determined

the crucial one

bits

128

64

32

16

8

4

2

1

subnets

*

128

*

192

224

240

248

252

254

255

powers of 2

subnets

hosts (-2)

2

4

8

16

32

64

128

256

512

1024

13■□□□□□□□□□10.210.204.70/12

multiples of 8 .... 12 is not greater than 16 .. so multiple of 8 satisfying it is ...8...so to get 12 we need to add 4 more bits ...

there fore ..tick 4 bits horizontally and 4 bits vertically and game over

seeing the table under subnets it stops at 240..so remember we have only one multiple of 8 .. so only one 255 in subnet mask..

therefore subnet mask is 255.240.0.0

now seeing under bits section...it has stopped at 16 so...multiples of 16 or difference of 16 ..we need to start with zero ---- for class a x.0.0.0

subnet

firsthost

lasthost

broadcast

10.0.0.0

10.16.0.0

10.32.0.0

etc till our ip

10.208.0.0

10.208.0.1

10.223.255.254

10.223.255.255

this satisfies our ip

10.224.0.0

hence in this way this can be determined

the crucial one

bits

128

64

32

16

8

4

2

1

subnets

*

*

*

*

128

*

192

*

224

*

240

*

248

252

254

255

powers of 2

subnets

hosts (-2)

2

4

8

16

32

64

128

256

512

1024

13■□□□□□□□□□20.100.55.3 / 26

multiple of 8 again .. it ends at 24...to get to 26 we need to have two bits .. so tick two bits vertically and horizontally in the table two ..

under subnets it stopped at 192

so our subnet mask is

255.255.255.192

and under bits it stopped at 64 .. so the subnets increment at rate of 64

lets start with zero subnet

subnet

firsthost

lasthost

broadcast

20.0.0.0

20.0.0.64

20.0.0.128

20.0.0.192

etc

etc till our ip

20.100.55.0

20.100.55.1

20.100.55.62

20.100.55.63

our ip falls here ..

20.100.55.64

20.100.55.128

20.100.55.192

hence in this way this can be determined

the crucial one

bits

128

64

32

16

8

4

2

1

subnets

*

*

128

*

192

*

224

240

248

252

254

255

powers of 2

subnets

hosts (-2)

2

4

8

16

32

64

128

256

512

1024

13■□□□□□□□□□192.168.1.0

4 subnets required

each subnet needs at least 10 hosts

firstly for its a class c addr ..so for our subnet mask it should have three octets full ... as class c is 255.255.255.x

so

fill it out as 255.255.255.x

now we need 4 subnets ... so tick till we meet our subnet requirements in the table

now as marked two bits under subnets ...you also need to mark two bits under subnets in the upper colomn

hence in this way this can be determined

as it stopped at 192..our subnet mask is ends with 192..there fore our subnet mask is 255.255.255.192

now as you tick two bits under upper subnets coloum...there are 6 bits remaining unticked right ..(unticked 224 240 248 252 254 255 total 6)

tick them under hosts wink.gif

look the table and come back ... we are left at 64 ..as we need to subtract two for broadcast and subnets .. there would be 62

solve simply

the crucial one

bits

128

64

32

16

8

4

2

1

subnets

128

*

192

*

224

240

248

252

254

255

powers of 2

subnets

hosts (-2)

2

*

*

4

*

*

8

*

16

*

32

*

64

*

128

256

512

1024

13■□□□□□□□□□9 subnets

each host needs atleast 10 hosts

class c addr ..so subnet mask is 255.255.255.x

now we need 9 subnets .. tick in the subnets coloum till we meet the requirement of 9 subnets ...

so look at the table .. we have ticked 4 of them .. so tick 4 bits in the upper subnet table

it stopped at 240 so our subnet mask is 255.255.2555.240

now we are left with 4 empty bits (248 , 252, 254 , 255) tick them under hosts ... and subtract two we are done

the crucial one

bits

128

64

32

16

8

4

2

1

subnets

128

*

192

*

224

*

240

*

248

252

254

255

powers of 2

subnets

hosts (-2)

2

*

*

4

*

*

8

*

*

we have met the requirement of 9 subnets

16

*

*(16-2 = 14 hosts )

32

64

128

256

512

1024

2,859■□□□□□□□□□Bsc (hons) Network Computing - 1st Class

WIP: Msc advanced networking

13■□□□□□□□□□130.100.0.0

we need 30 subnets

each subnet with atleast 1000 hosts

class b ..

so subnet mask is 255.255.x.x

we need 30 right .. so tick in the subnet table until we meet the requirement

after looking at the table ..we ticked 5 of the subnet ones ..so even tick the 5 bits of upper subnets

it ends at 248 so our subnet mask is 255.255.248.0

now we have unticked three of them

(252 ,254 , 255 ***********important (3 of the unticked third octet and 8 of the remaining 4th octet so a total of 11..so tick 11 in the host bits portion and

subtract 2 to get the number of hosts)

the crucial one

bits

128

64

32

16

8

4

2

1

subnets

128

*

192

*

224

*

240

*

248

*

252

254

255

powers of 2

subnets

hosts (-2)

2

*

*

4

*

*

8

*

*

16

*

*

32

*(we met 30 here)

*

64

*

128

*

256

*

512

*

1024

*

2048

* (total of 11 bits ticked 2048 - 2 = 2046 hosts / subnet)

hope this helped anyone ... any comments / suggestions are warmly welcomed ...

regards

rakesh

5■□□□□□□□□□right pinky=1, 2, 4, 8 then my left hand 16, 32, 64, 128.

then to get the mask, add from left-to-right:

left pinky = 128, then 192, 224, 240 then right hand 248, 252, 254, 255

each finger is a bit; quick and dirty visual aid.

245LOL, I do the same thing!

154thanks for this good tutorial but could you explain the power of 2 as I just cant get my head round that?

thanks

25■□□□□□□□□□2^0

2^1

2^2

2^3

and so on ...

thats what is meant by the power of 2 thing

the rightmost bit is 2^0

the one left to this is 2^1

and so on ...

hope this helps

1■□□□□□□□□□1■□□□□□□□□□I'd like to add the note that I've memorized to allow me to subnet in under 10 seconds, as recommended per the Academic version of ICND1 for anyone who may come across this via google like I did. I put this together in Notepad++ in the Java language so it looked all nice and pretty, and attached an image for you guys.

128 64 32 16 8 4 2 1

128

192

224

240

248

252

254

255

8 16 24 32

^^^ Count multiples of 8 till you

reach one of these below your bit notation

--- Take left over amount and tick

horizontally and vertically on chart above

So 192.168.12.68 /25 = 8+8+8+(1);

1 = H 128 V 128

H = range

V = mask

where h = horizontal and v = vertical

->Subnet = 192.168.12.0 FirstHost = 192.168.12.1

->LastHost = 192.168.12.126 Broadcast = 192.168.12.127

-To determine which subnet an address belongs to:

Example 172.31.77.201/27

27 - 24(8+8+ = 3 = 32 & 224

201 divided by 32 = 6.2ish

32 * 6 = 192

->Subnet = 172.31.77.192 FirstHost = 172.31.77.193

->LastHost = 172.31.77.222 Broadcast = 172.31.77.223

2dubs