-
IP subnetting: The process of designing a subnet mask.
-
The calculation process is as follows: the IP address and subnet mask are converted into binary, and then the calculation is carried out, and the result is the network address. And the operation is as follows, aligned up and down, 1 bit 1 bit is counted, 1 and 1 = 1, and the rest of the combinations are 0.
1) Convert the IP address and subnet mask to binary respectively.
Converted to binary is 11001010·01100011·10100000·00110010
Converted to binary is 11111111·11111111·11111111·00000000
2) Perform the two calculations.
3) Convert the result of the operation to decimal, which is the network address. 11001010·01100011·101000000·0000000 is converted to decimal system.
-
Categories: Sports Sports >> Basketball.
Problem description: How is the subnet mask calculated? What are the rules?? Mentoring.
Thank you. Analysis:
Commonly used subnet masks.
There are hundreds of subnet masks, and here are only the two most commonly used ones, which are "and".
However, the actual number of available IP addresses is 256-2, or 254, because the host number cannot be all "0" or all "1".
2.The subnet mask is "network: the last two digits can be arbitrarily varied in the range of 0 255, and 2552 IP addresses can be provided. But the actual number of available IP addresses is 2552-2, which is 65023.
The subnet mask setting of the IP address is not arbitrary. If the subnet mask is set too large, that is, the subnet range is expanded, then, according to the subnet pathfinding rules, it is likely that the data sent to the destination machine that is not in the same subnet as the local machine will be considered to be in the same subnet due to wrong judgment, and the data packet will be circulated in the subnet until it times out and is discarded, so that the data cannot reach the destination machine correctly, resulting in network transmission errors. If the subnet mask is set too small, the communication between machines that originally belong to the same subnet will be regarded as cross-subnet transmission, and the data packets will be handed over to the default gateway for processing, which will inevitably increase the burden on the default gateway and cause the network efficiency to decrease. Therefore, the subnet mask should be set according to the size of the network.
If the size of a network does not exceed 254 computers, it is enough to use "as a subnet mask, most LANs will not exceed this number nowadays, therefore" is the most commonly used IP address subnet mask; The largest primary and secondary school campus network I have seen has more than 1,500 computers, and a LAN of this size can be used."
Default subnet mask.
In Windows 2000 Server, if you specify an IP address for a network card, the system will automatically fill in a default subnet mask. This is a subnet mask that is automatically generated by Windows 2000 Server to save user input time. For example, the most commonly used IP address for a LAN is the "default subnet mask".
In general, the default subnet mask for the IP address is sufficient.
-
The subnet mask can be found using the number of subnets and hosts.
Before you can find a subnet mask, you must first find out how many subnets you want to divide and how many hosts you need in each subnet.
1. Use subnets to find.
1. Convert the number of subnets into binary representation.
2. Obtain the number of binary digits, which is n.
3. Obtain the subnet mask of the IP address, and obtain the subnet mask of the IP address division subnet by 1 in the first n position of the host address part.
Second, the number of hosts is used to calculate.
1. Convert the number of hosts into binary representation.
2. If the number of hosts is less than or equal to 254 (note to remove the reserved two IP addresses), then obtain the binary number of bits of the host, which is n, here it must be n<8. If it is greater than 254, then n>8, which means that the host address will occupy more than 8 bits.
3. Use 255 255 255 255 to set all the host address bits of this type of IP address to 1, and then set all the n bits to 0 from back to front, which is the subnet mask value.
Use of subnet masks
Subnet mask, also known as network mask, address mask, and subnet mask, is a bit mask used to indicate which bits of an IP address identify the subnet where the host is located, and which bits identify the host. The subnet mask cannot exist on its own, it must be used in conjunction with an IP address.
The subnet mask has only one function, which is to divide an IP address into two parts: the network address and the host address. A subnet mask is a 32-bit address that is used to mask a portion of an IP address to distinguish between network and host identities and to indicate whether the IP address is on a local area network or a remote network.
-
The number of bits of the network of Class A network is 8 bits, and the subnet mask code is, which is converted to binary representation.
The number of bits in the network of a Class B network is 16 bits, and the subnet mask is, which is converted to a decimal representation.
The number of bits in the network of a Class C network is 24 bits, and the subnet mask is, which is converted to a decimal representation.
-
The network address of the IP address is obtained by using a 32-bit IP and a 32-bit mask and arithmetic stealth.
The first thing to do is to convert both the IP address and the subnet mask to 32-bit binary. The characteristic of the AND operation is that if there is 0, it is 0, and all 1 is 1.
The specific calculation is as follows:
11000000 192 (first segment of IP address)11111111 255 (first segment of subnet mask)11000000 192 (with the result of the operation)10101000 168 (second segment of the IP address)11111111 255 (second segment of the subnet mask)10101000 168 (with the result of the operation)00001010 10 (third segment of the IP address)11111111 255 (the third segment of the ruler subnet mask) 00001010 10 (with the result of the operation).
00000000 0 (fourth segment of IP address).
11000000 192 (fourth segment of the subnet mask) 00000000 0 (with the result of the operation).
List the AND result in the four segments as the network address of the first subnet.
Because the default mask for a Class C address is. But now the mask is.
There are two more bits than the 1 bit in the original mask, so 2 2 = 4 subnets are divided. The first subnet is in the question. The valid host number for the subnet is.
Example: Check whether the IP address is on the same network segment. Step 1 (Default Subnet Mask): These are converted to binary.
ip1:ip2:
Subnet mask: Step 2: AND the IP address and subnet mask.
ip1 and subnet mask = 00001100
IP2 and subnet mask = 00111000
Step 3: Convert the results into decimal system.
IP1 Network ID:
IP2 Network Identity:
Therefore, it can be seen that they are not in the same network segment.
…is a public IP address, not a Class C IP address.
40 machines, using a mask should be enough, it can set up up to 254 machines. >>>More
IP address and subnet mask division knowledge.
Solution: Ideas: According to the topic, one is 500, the remaining three are almost 500, the first two are 500, and the rest is subdivided; 500 requires nine host bits, and the child subnet mask is. >>>More
1. Enter the IP address and subnet mask just to set the LAN, if it is dial-up Internet access, you need to add a broadband connection, then click on the broadband connection, enter the Internet account and password to access the Internet. You can surf the Internet even if you don't have an IP address. >>>More
Can a mask be?
It seems that it can only be a few values. >>>More