Baidu Encyclopedia
Subnet mask (subnet mask) is also called network mask, address mask, and subnet mask. It is a type used to indicate which bits of an IP address identify the subnet where the host is located, and which bits identify the host's bit mask. The subnet mask cannot exist alone, it must be used in conjunction with the IP address. The subnet mask has only one function, which is to divide a certain IP address intoNetwork addressandHost addressTwo parts
24-bit subnet mask (255.255.255.0)
What we often see now is192.168.0.0/24
, that is, the subnet mask is255.255.255.0
, the computer that can be stored is256 - 1 - 1 - 1 = 253
,in0 is the network address
,255
It's the broadcast address,1
It is the gateway address.
23-bit subnet mask (255.255.254.0)
192.168.6.0/23
For this network, the number of computers we can store512 - 1 - 1 - 1 = 509
First we convert IP into binary192.168.6.0
—> 1100 0000. 1010 1000. 0000 0110. 0000 0000
Subnet mask23
Before explaining the IP address23
bit network address, so1100 0000. 1010 1000. 0000 011
is the network address,0. 0000 0000
As the host address
That is, the host has 9-bit binary, so corresponding to binary, that is,192.168.6.0
and192.168.7.0
It is in the same network segment.
25-bit subnet mask (255.255.255.128)
192.168.6.0/25
For this network, the number of computers we can store128 - 1 - 1 - 1 = 125
First we convert IP into binary192.168.6.0
—> 1100 0000. 1010 1000. 0000 0110. 0000 0000
Subnet mask25
Before explaining the IP address25
bit network address, so1100 0000. 1010 1000. 0000 0110. 0
is the network address,000 0000
As the host address
That is, the host has a 7-digit binary number.192.168.6.0
arrive192.168.6.127
The corresponding network segments are between them.
Store 10 computers
Filed10
lie in8
to16
between, the corresponding host address is at least 4 bits, that is192.168.6.0/28
The corresponding network IP number is192.168.6.1
arrive192.168.6.14
Store 100 units of calculation
Filed100
lie in64
to128
between, the corresponding host address is at least 7 bits, that is192.168.6.0/25
The corresponding network IP number is192.168.6.1
arrive192.168.6.126
Store 1,000 computers
Filed1000
We'll have the first reaction1024
,210Then the corresponding host address is at least 10 bits, that is,192.168.6.0/22
The corresponding network IP number is192.168.4.1
arrive192.168.7.254
Store 5,000 computers
Mentioned5000
A computer, then the corresponding one is4096
arrive8192
between. Then what we will use192.168.6.0/19
。
The corresponding network IP number is192.168.0.1
arrive192.168.31.254
Store 10,000 computers
The corresponding number is8192
arrive16384
,Right now192.168.6.0/18
The corresponding network IP number is192.168.0.1
arrive192.168.63.254