What is a subnet mask?
What is a subnet mask?
The subnet mask is a 32-bit address used to distinguish between the network address and the host address in the IP address. The subnet mask determines which part of the IP address is the network address and the host address. They are not displayed inside data packets traveling over the Internet. They carry the destination IP address that the router will match to a subnet.
There are two types of subnet masks:
- The default subnet mask is the number of bits reserved by the address layer. Using this default mask will provide a unique network subnet in the relative layer.
- Custom subnet masks can be defined by the administrator to provide multiple networks
How to use subnet mask?
The subnet mask is used by the router to hide the network address. It indicates which bit is used to identify the subnet.
Each network has its own unique address, Like here, the Class B network has network address 172.20.0.0, which has all zeros in the host part of the address.
Example IP address: 11000001. Here the first and second bits are 1 and the third bit is 0; so it's Class C.
The example above shows how to interpret the IP address structure, which makes it easier for Internet routers to find the right network to route data in. However, in a Class A network there can be millions of devices connected, and it can take a while for the router to find the right device.
Methods of subnet mask
The subnet mask process can be divided into two methods: Direct or reduced.
1. Directly
You should use the binary notation method for both the address and the mask, and then apply the AND function to get the block address.
2. Shorten
- In case the byte in the mask is 255, you need to copy the byte in the destination address.
- When the byte in the mask is 0, then you need to replace the byte in the address with 0.
- When the byte in the mask is neither 255 nor 0, then you should write the mask and address in binary and use the AND function.
- Use in case if extracted network address matches local network ID and destination is on local network. However, if they do not match, the information must be routed outside the local network.
Class | Default Subnet Mask | Number of networks | Number of hosts per network |
---|---|---|---|
A | 255.0.0.0 | 256 | 16,777,214 |
REMOVE | 255.255.0.0 | 65,536 | 65,534 |
OLD | 255.255.255.0 | 16,77,216 | 126 |
Important formulas for determining subnet
Use the formula 2s – 2, do not use range 0 and broadcast if:
- You can use the full routing method.
- RIP version 1 is used
- The no IP subnet-zero command is configured on your router.
Use the 2s formula, range 0 and broadcast if:
- You can use the VLM approach or classless routing.
- RIP version 2. EIGRP. or OSPF is used
- The IP subnet-zero command is configured on your router.
What is Subnetting?
Subnetting is a way of dividing a network into two or more smaller networks. It increases routing efficiency, enhances network security, and reduces the size of broadcast domains.
IP Subnetting specifies high-order bits from the host as part of the network prefix. This method divides a network into smaller subnets.
It also helps you to reduce the size of the routing tables, which are stored in the routers. This method also helps you to expand your existing IP address base and restructure IP addresses.
Why Use Subnetting?
Here are important reasons to use Subnetting:
- It helps you maximize IP address efficiency.
- Extend the life of IPV4.
- Public IPV4 addresses are scarce.
- IPV4 Subnetting reduces network traffic by eliminating conflicting and broadcast traffic, thus improving overall performance.
- This method allows you to apply network security policies at the connection point between subnets.
- Optimize IP network performance.
- Facilitating large geographical distances.
- Subnetting helps to allocate IP addresses to prevent a large number of IP network addresses from being used.
- Subnets are often geographically set up for specific offices or groups within a business, allowing their network traffic to reside within that area.
You should read it
- How to Find the Subnet Mask
- How to Find Your Subnet Mask
- 10 things to know about Mask in Photoshop
- Advanced Subnet Calculator - Download Advanced Subnet Calculator here.
- How to Calculate Network and Broadcast Address
- Set up the LAN by dividing the subnet
- How to Make a Mask Using the Olsen Mask Pattern
- IP, Subnet mask, installation and configuration for 1 server
May be interested
- Configure a Mac VLANthe addition of software-based vlans allows segmenting workstations into completely separate lan local networks.
- Why is Localhost's IP address 127.0.0.1?127 is the last network number (network number) in network class a with subnet mask 255.0.0.0. address 127.0.0.1 is the first transfer address in the subnet. address 127.0.0.0 is not used because this is the address of the wired network.
- Amazfit Aeri self-sterilizing mask, supports unlocking the smartphone with the face even when wearing a maskworry about masks that limit facial unlocking on smartphones will no longer be available with a transparent mask model developed by huami.
- Warning: New research has identified the corona virus to remain on the mask for more than a weeknew research shows that the time the virus remains on the face of the mask is much longer than we thought. therefore, all need to make it a habit not to touch the front of the mask after use, and wash their hands often.
- How to wear a mask without blurry glassesif you want to wear a mask without blurring your glasses, follow the instructions in this article. the implementation is simple and very easy to do.
- Explore the process of researching and manufacturing masking salt, steaming of cajeput oil in Vietnamhow is a mask covered with salt, steamed cajeput oil? does it work well? find out now!
- How to create clipping mask in GIMPclipping mask is much simpler than we imagine. basically, they apply layer masks to a group of layers.
- how to sew the cloth maskmany of you think making a mask will be very difficult and complicated. but not at all, let's find out the article of self-made masks that tipsmake.com shared today, you will see how sewing masks are not as difficult as we thought at first.
- The right way to wear a medical mask is to prevent and prevent Corona viruswearing a medical mask is one of the preventive measures to prevent the spread of many respiratory diseases, including the corona virus. however, this only happens when we wear the mask properly and the right type of mask.
- Discover the LG PuriCare 2 air filter maskwith the advantages of effective prevention of harmful substances in the environment, convenience in use, the 2nd generation lg puricare air filter mask is a technology product that attracts users.