How To Calculate Subnet Mask From Ip Address With Example?
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Example:
1. Determine the total number of subnets you wish to create. For this example, we will say 32 subnets.
2. Calculate the binary equivalent of the number of subnets you wish to create. For this example, it would be ‘00000’ in binary.
3. Count the number of 1‘s in the binary representation of your number (this will tell you how many bits you need). In this case, there are 5 ‘1’s.
4. Subtract this number from 32 (the total number of bits in an IP address). In this case, 32 – 5 = 27.
5. The new number (27) is the subnet mask in CIDR notation. To convert this to a subnet mask, take the number of ‘1’s from step 3 and fill the remaining bits with 0’s. In this case, it would be 11111111.11111111.11111111.11100000 or 255.255.255.224 in decimal notation.