Analysis of IP Classification and Special IP addresses

Source: Internet
Author: User


IP classification and analysis of Special IP addresses basic IP addresses are 32-bit binary numbers divided into eight-bit units (referred to as eight-bit groups. You can understand both binary and decimal. To make it easier for people to use it, the machine-friendly binary address is changed to a more familiar decimal address. Each eight-bit group in the IP address uses 0 ~ A decimal number between 255. These numbers are separated by DOTS (.). This is called the dot-decimal format. Therefore, the minimum IPv4 address value is 0.0.0.0, and the maximum IP address value is 255.255.255.255. However, these two values are retained and are not allocated to private end systems. IPv4 addresses in dotted-decimal notation are divided into several types to adapt to large, medium, and small networks. The difference between these classes is that they are used to represent the number of digits in the network and the number of digits used to represent the host. The IP address is divided into five categories, represented by letters: www.2cto.com Class A Address class B Address class C Address class D address Class E address each IP address consists of two parts: network address and host address, the preceding five types of addresses have different combinations of supported networks and hosts.
1. Class A addresses A Class a ip address only uses the first eight-bit group to represent the network address. The remaining three 8-bit groups represent the host address. The first digit of A Class address is 0, which indicates that the range of Class A addresses is less than 127,127 and the sum of 64 + 32 + 16 + 8 + 4 + 2 + 1. The leftmost digit indicates 128, which is vacant here. Therefore, there are only 127 possible Class A networks. The 24-bit (three dots-in-decimal number) after the class A Address indicates A possible host address. The network address range of Class A ranges from 1.0.0.0 to 126.0.0.0. Note that only the first eight-bit group represents the network address, and the remaining three eight-bit groups represent the only host address in the network in the first eight-bit group, when used to describe the network, these locations are 0. Technically speaking, 127.0.0.0 is also A Class A address, but it has been retained for A closed-loop (look back) test and cannot be allocated to A network. Each class A address supports 16777214 different host addresses, which are obtained from the power of 24 of 2 minus 2. It is necessary to subtract 2 because the IP address keeps all 0 as the network and the IP address is the broadcast address in the network. 10.0.0.0 and 10.20.255.255 are retained.
2. Class B address design class B address is designed to support medium to large networks. The Class B network address ranges from 128.1.0.0 to 191.254.0.0. The mathematical logic of Class B addresses is quite simple. A Class B IP address uses two octal groups to represent the network number, and the other two octal groups to represent the host number. The first two digits of the 1st 8-bit group of Class B addresses are set to 10, and the remaining six digits can be either 0 or 1, so that the range is limited to less than or equal to 191, it is obtained from 128 + 32 + 16 + 8 + 4 + 2 + 1. The last 16-bit (two eight-bit groups) identifies the possible host address. Each B-type address supports 64534 unique host addresses, which are obtained by reducing the power of 2 to the power of 16. There are only 16382 Class B networks, among which 172.16.0.0 and 172.31.255.255 are retained.
3. Class C address www.2cto.com Class C address is used to support a large number of small networks. Such addresses are considered to be the opposite of Class A addresses. Class A addresses use the first eight-bit group to represent the network number, and the remaining three represent the host number, while Class C addresses use three eight-bit groups to represent the network address, only one eight-bit group is used to represent the host number. The first three digits of class C addresses are 110, and the first two digits are 192 (128 + 64), which forms the lower bound of class C address space. The third digit is equal to the decimal number 32. This digit is 0, which limits the upper bound of the address space. The third digit cannot be used to limit the maximum value of the eight-digit group to 25-32 or 223. Therefore, the class C network address ranges from 192.0.1.0 to 223.20.254.0. The last eight-bit group is used for host addressing. Theoretically, each class C address supports a maximum of 256 host addresses (0 ~ 255), but only 254 are available, because 0 and 255 are not valid host addresses. There may be 2097150 different class C network addresses, of which 192.168.0.0 and 192.168.255.255 are retained.
4. Class D address is used for multicast (multicasting) in an IP network ). The first 4 bits of class D address are 1110. If the first 3 bits of the preset are 1, the Class D address starts from 128 + 64 + 32 to 224. If the 4th-bit value is 0, the maximum value of class D address is 128 + 64 + 32 + 8 + 4 + 2 + 1. Therefore, the range of class D address space is from 224.0.0.0 to 239. 255. 255.254. 5. Class E address retention for research purposes. Therefore, no class E address is available on the Internet. The first four digits of Class E address are invariably 1, so the valid address range is from 240.0.0.0 to 255.255.255.255. In general, the IP address category is determined by the value of the first eight-bit group. Any network address between 0 and 127 is A Class A address. Any network address between 128 and 191 is a Class B address. Any network address between 192 and 223 is a class C address. The network address of any first eight-bit group between 224 and 239 is a multicast address, that is, Class D address. Class E is retained. The IP addresses on the Internet are managed by an IANA (Internet Assigned Numbers Authority) organization. IP addresses can be divided into public addresses and private addresses based on their purposes and security levels. Public addresses are used in the Internet and can be accessed freely on the Internet. Private addresses can only be used in internal networks and can communicate with the Internet only through proxy servers. Www.2cto.com a public IP address must be applied to connect to the Internet. However, in consideration of special situations such as network security and internal experiments, three private addresses are reserved in the IP address. The address range is as follows:
Network type IP address range network count a type Network <? Xml: namespace prefix = st1/> 10.0.0.0 ~ 10.20.255.255 1 class B network 172.16.0.0 ~ 172.31.255.255 16 class c network 192.168.0.0 ~ 192.168.255.255 255 a network with a reserved address can only communicate internally, but cannot communicate with other networks. Because the reserved addresses in the Network may also be used by other networks, if the network is connected, the problem may occur because the address is not unique when looking for a route. However, these networks that use reserved addresses can interconnect with external networks by translating the reserved addresses in the network into public addresses. This is also an important way to ensure network security. The reserved IP address segment is not used on the Internet. Therefore, when a router connected to the WAN processes the reserved IP address, it only discards the packet and does not route it to the WAN, in this way, the data generated by the reserved IP address is isolated within the LAN. If the number of computers in the LAN is less than 254, you can select the IP address range in the C-type IP address segment, for example, from "192.168.1.1" to "192.168.1. 254 ". Just as each of us has an ID card number, each computer on the Network (more specifically, the network interface of each device) has an IP address to identify itself. We may all know that these addresses are composed of four bytes, expressed in dotted decimal notation and Their A, B, and C classifications. However, in the total number of approximately more than 4 billion available IP addresses, do you know some common URLs with special meanings below? Let's take a look: www.2cto.com I. 0.0.0.0 strictly speaking, 0.0.0.0 is no longer a real IP address. It represents a set of unknown hosts and destination networks. The "unclear" here means that no specific entries in the local route table indicate how to arrive. For the local machine, it is a "Shelter", and all the "Three none" personnel that do not know will be sent in. If you set the default gateway in the network settings, the Windows system will automatically generate a default route with the destination address 0.0.0.0. Ii. Broadcast bandwidth limit 255 limits the broadcast address. For the local machine, this address refers to all hosts in the same broadcast domain in this segment. If translated into human language, it should be like this: "Everyone in this room has noticed it !" This address cannot be forwarded by the router. Iii. 127.0.0.1 local address, mainly used for testing. In Chinese, it is "Myself ". In Windows, this address has an alias "Localhost ". Addressing such an address cannot send it to network interfaces. Unless an error occurs, data packets with the target address 127.0.0.1 should never appear on the transmission media. 4. 224.0.0.1 multicast address. Pay attention to the difference between it and broadcast. From 224.0.0.0 to 239.255.255.255. 224.0.0.1 refers to all hosts and 224.0.0.2 refers to all routers. Such an address is mostly used for some specific programs and multimedia programs. If your host has enabled the IRDP (Internet route Discovery protocol, use the multicast function) function, your host routing table should have such a route. 5. 169.254.x.x if your host uses the DHCP function to automatically obtain an IP address, when your DHCP server fails or the response time is too long, it exceeds the time specified by the system, the Wingdows system will assign you such an address. If you find that your host IP address is such an address, unfortunately, your network cannot run normally. 6. 10. x, 172.16.x.x ~ 172.31.x.x, 192.168.x.x www.2cto.com private addresses, these addresses are widely used in enterprise internal networks. Some broadband routers often use 192.168.1.1 as the default address. The private network may use random IP addresses because it is not interconnected with external networks. This address is reserved for use to avoid address confusion when accessing the public network in the future. When a private network using a private address accesses the Internet, you must use address translation (NAT) to translate the private address into a public legal address. This type of address cannot appear on the Internet. A host on a network can receive three valid destination network addresses: The local IP address, broadcast address, and multicast address.
 

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.