IP address first

Source: Internet
Author: User

The IP address is divided into IPv4 (32-bit) and IPv6 (128-bit ). IPv6 is proposed to cope with the problem of insufficient IP addresses in the future, but IPv4 is still the mainstream.

An IP address is divided into four segments, each of which has eight bits. The segments and segments are separated. For easy representation, IP addresses convert binary without segments to decimal.

The IP address is divided into two parts: the domain number (net_id) and the host number (host_id). IP addresses can be divided into five categories based on the number of occupied domain numbers and host numbers:

A: 0xxxxxxx. XXXXXXXX

B: 10xxxxxx. XXXXXXXX

C: 110xxxxx. XXXXXXXX

D: 1110xxxx. XXXXXXXX

E: 1111xxxx. XXXXXXXX

 

There is a private IP in A, B, and C respectively:

A: 10.0.0.0 ~~~~~~~~ 10.20.255.255

B: 172.16.0.0 ~~~~~~~~~ 172.31.255.255

C: 192.168.0.0 ~~~~~~~~ 192.168.255.255

 

Classes A, B, and C can be further divided into multiple subnets. Each subnet has a subnet mask.

The subnet mask has 32 bits. If the subnet has 24 bits and the host number has 8 bits, the subnet mask consists of 24 1 s and 8 0 s: 11111111.111111.11111111.00000000

Therefore, the number 1 in a subnet mask represents the number of domain numbers in the subnet, And the number 0 represents the number of host numbers in the subnet.

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.